gsi: Init rp_update_vaddr at event ring init
Leaving this field 0 may lead to a crash during the first gsi_poll_n_channel() call. Change-Id: I6c8e9e1e5bacdddd41023618881d761d730a1931 Signed-off-by: Ilia Lin <ilial@codeaurora.org>
This commit is contained in:
@@ -1543,6 +1543,9 @@ static void gsi_init_evt_ring(struct gsi_evt_ring_props *props,
|
|||||||
ctx->elem_sz = props->re_size;
|
ctx->elem_sz = props->re_size;
|
||||||
ctx->max_num_elem = ctx->len / ctx->elem_sz - 1;
|
ctx->max_num_elem = ctx->len / ctx->elem_sz - 1;
|
||||||
ctx->end = ctx->base + (ctx->max_num_elem + 1) * ctx->elem_sz;
|
ctx->end = ctx->base + (ctx->max_num_elem + 1) * ctx->elem_sz;
|
||||||
|
|
||||||
|
if (props->rp_update_vaddr)
|
||||||
|
*(uint64_t *)(props->rp_update_vaddr) = ctx->rp_local;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void gsi_prime_evt_ring(struct gsi_evt_ctx *ctx)
|
static void gsi_prime_evt_ring(struct gsi_evt_ctx *ctx)
|
||||||
|
Reference in New Issue
Block a user