Error queues use a non-zero first word to detect if the queues are full.
Using pages that have not been zeroed may result in false positive
overflow events. These queues are set up once during boot so zeroing
all mondo and error queue pages is safe.
Note that this does not always occur because the page allocation for
these queues is so early in the boot cycle that higher number CPUs get
fresh pages. It is only when traps are serviced with lower number CPUs
who were given already used pages that this issue is exposed.
orabug:
23054018
Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
Signed-off-by: Allen Pais <allen.pais@oracle.com>
unsigned long order = get_order(size);
unsigned long p;
- p = __get_free_pages(GFP_KERNEL | __GFP_COMP, order);
+ p = __get_free_pages(GFP_KERNEL | __GFP_COMP | __GFP_ZERO, order);
if (!p) {
pr_err("SUN4V: Error, cannot allocate queue.\n");
return -ENOMEM;