Re: [PATCH] ACPI: APEI: Fix num_ghes to unsigned int

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 5, 2022 at 5:41 PM Ashish Kalra <Ashish.Kalra@xxxxxxx> wrote:
>
> Yes, on one of our AMD EPYC processors, num_ghes is 32776 and we get the following call trace due to vmalloc() failure beacuse of the overflow:

But int should be more than sufficient to accommodate that number.

I think that the overflow takes place during the execution of this statement:

len += (num_ghes * GHES_ESOURCE_PREALLOC_MAX_SIZE);

because the right-hand side of it is of type int, because both
multiplication operands are int.

You should say that in the changelog.



[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux