@@ -1989,17 +1989,23 @@ static int its_alloc_collections(struct its_node *its)
return 0;
}
+static void gic_reset_pending_table(void *va)
+{
+ memset(va, 0, LPI_PENDBASE_SZ);
+
+ /* Make sure the GIC will observe the zero-ed page */
+ gic_flush_dcache_to_poc(va, LPI_PENDBASE_SZ);
+}
+
static struct page *its_allocate_pending_table(gfp_t gfp_flags)
{
struct page *pend_page;
- pend_page = alloc_pages(gfp_flags | __GFP_ZERO,
- get_order(LPI_PENDBASE_SZ));
+ pend_page = alloc_pages(gfp_flags, get_order(LPI_PENDBASE_SZ));
if (!pend_page)
return NULL;
- /* Make sure the GIC will observe the zero-ed page */
- gic_flush_dcache_to_poc(page_address(pend_page), LPI_PENDBASE_SZ);
+ gic_reset_pending_table(page_address(pend_page));
return pend_page;
}
Add function that is similar to gic_reset_prop_table but for pending table. Signed-off-by: Pavel Tatashin <pasha.tatashin@soleen.com> --- drivers/irqchip/irq-gic-v3-its.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-)