RE: [PATCH] ACPICA: Replace one-element array and use struct_size() helper

2020-05-21 Thread Kaneda, Erik
Len Brown ; ACPI > Devel Maling List ; open list:ACPI COMPONENT > ARCHITECTURE (ACPICA) ; Linux Kernel Mailing List > ; Gustavo A. R. Silva > > Subject: Re: [PATCH] ACPICA: Replace one-element array and use > struct_size() helper > > On Wed, May 20, 2020 at 11:15:18AM +0200, R

Re: [PATCH] ACPICA: Replace one-element array and use struct_size() helper

2020-05-20 Thread Kees Cook
On Wed, May 20, 2020 at 11:15:18AM +0200, Rafael J. Wysocki wrote: > On Wed, May 20, 2020 at 12:46 AM Gustavo A. R. Silva > wrote: > > > > On Tue, May 19, 2020 at 12:25:13PM +0200, Rafael J. Wysocki wrote: > > > On Tue, May 19, 2020 at 12:22 AM Gustavo A. R. Silva > > > wrote: > > > > > > > >

Re: [PATCH] ACPICA: Replace one-element array and use struct_size() helper

2020-05-20 Thread Rafael J. Wysocki
On Wed, May 20, 2020 at 12:46 AM Gustavo A. R. Silva wrote: > > On Tue, May 19, 2020 at 12:25:13PM +0200, Rafael J. Wysocki wrote: > > On Tue, May 19, 2020 at 12:22 AM Gustavo A. R. Silva > > wrote: > > > > > > The current codebase makes use of one-element arrays in the following > > > form: > >

Re: [PATCH] ACPICA: Replace one-element array and use struct_size() helper

2020-05-19 Thread Gustavo A. R. Silva
On Tue, May 19, 2020 at 12:25:13PM +0200, Rafael J. Wysocki wrote: > On Tue, May 19, 2020 at 12:22 AM Gustavo A. R. Silva > wrote: > > > > The current codebase makes use of one-element arrays in the following > > form: > > > > struct something { > > int length; > > u8 data[1]; > > }; > >

Re: [PATCH] ACPICA: Replace one-element array and use struct_size() helper

2020-05-19 Thread Rafael J. Wysocki
On Tue, May 19, 2020 at 12:22 AM Gustavo A. R. Silva wrote: > > The current codebase makes use of one-element arrays in the following > form: > > struct something { > int length; > u8 data[1]; > }; > > struct something *instance; > > instance = kmalloc(sizeof(*instance) + size,