[PATCH v2] ACPICA: Replace one-element array with flexible-array

2020-06-02 Thread Gustavo A. R. Silva
https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Don't use struct_size() for now. - Update subject line and changelog text. drivers/acpi/acpica/utids.c | 2 +- include/acpi/act

Re: [PATCH] pinctrl-single: fix pcs_parse_pinconf() return val

2020-06-01 Thread Gustavo A. R. Silva
On 5/31/20 15:41, Drew Fustini wrote: > This patch causes pcs_parse_pinconf() to return an error when no > pinctrl_map is added. The current behavior is to return 0 when > !PCS_HAS_PINCONF or !nconfs. Thus pcs_parse_one_pinctrl_entry() > incorrectly assumes that a map was added and sets num_ma

Re: [PATCH] audit: Use struct_size() helper in alloc_chunk

2020-06-01 Thread Gustavo A. R. Silva
On Mon, Jun 01, 2020 at 11:36:09AM -0400, Paul Moore wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > --- > > kernel/audit_tree.c | 4 +--- > > 1 file changed, 1 insertion(+), 3 deletions(-) > > Thanks, this looks reasonable to me, but it came in too

Re: [PATCH] efi: Replace zero-length array and use struct_size() helper

2020-05-29 Thread Gustavo A. R. Silva
On Fri, May 29, 2020 at 01:31:54AM -0700, Kees Cook wrote: > On Wed, May 27, 2020 at 12:14:25PM -0500, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to declare > >

[PATCH] efi: Replace zero-length array and use struct_size() helper

2020-05-27 Thread Gustavo A. R. Silva
ux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- drivers/firmware/efi/efi.c | 3 ++- include/linux/efi.h| 7 ++- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/firmware/efi/efi.c b/d

Re: [PATCH] IB/core: Use sizeof_field() helper

2020-05-27 Thread Gustavo A. R. Silva
On Wed, May 27, 2020 at 01:44:52PM -0300, Jason Gunthorpe wrote: > On Wed, May 27, 2020 at 09:41:52AM -0500, Gustavo A. R. Silva wrote: > > Make use of the sizeof_field() helper instead of an open-coded version. > > > > Signed-off-by: Gustavo A. R. Silva > > --- &

[PATCH] IB/core: Use sizeof_field() helper

2020-05-27 Thread Gustavo A. R. Silva
Make use of the sizeof_field() helper instead of an open-coded version. Signed-off-by: Gustavo A. R. Silva --- drivers/infiniband/core/sa_query.c | 8 drivers/infiniband/core/uverbs_cmd.c | 2 +- drivers/infiniband/core/uverbs_ioctl.c | 2 +- 3 files changed, 6 insertions(+), 6

[PATCH net-next v3] ice: Replace one-element arrays with flexible-arrays

2020-05-27 Thread Gustavo A. R. Silva
x undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- Changes in v3: - We still can simply the code even more by using offsetof() just once. :) Changes in v2: - Use offsetof(struct ice_aqc_sw_rules_elem, pdata) instead of sizeof(struct ice_aqc_sw_rules_elem) -

[PATCH] m68k: Use sizeof_field() helper

2020-05-27 Thread Gustavo A. R. Silva
Make use of the sizeof_field() helper instead of an open-coded version. Signed-off-by: Gustavo A. R. Silva --- arch/m68k/kernel/signal.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/arch/m68k/kernel/signal.c b/arch/m68k/kernel/signal.c

[PATCH v2][net-next] ice: Replace one-element arrays with flexible-arrays

2020-05-27 Thread Gustavo A. R. Silva
x undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Use offsetof(struct ice_aqc_sw_rules_elem, pdata) instead of sizeof(struct ice_aqc_sw_rules_elem) - sizeof(((struct ice_aqc_sw_rules_elem *)0)->pdata) - Update changelog text. .../net/ethernet/intel/ice/ice_

[PATCH][next] ice: Replace one-element arrays with flexible-arrays

2020-05-26 Thread Gustavo A. R. Silva
32932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- .../net/ethernet/intel/ice/ice_adminq_cmd.h | 6 ++--- drivers/net/ethernet/intel/ice/ice_switch.c | 22 +-- 2 files changed, 13 insertions(+), 15 deletions(-) diff --git a/drivers/ne

Re: [PATCH] m68k: tools: Replace zero-length array with flexible-array member

2020-05-25 Thread Gustavo A. R. Silva
On Mon, May 25, 2020 at 10:49:02AM +0200, Geert Uytterhoeven wrote: > > > > [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html > > [2] https://github.com/KSPP/linux/issues/21 > > [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") > >

[PATCH] PCI: hv: Use struct_size() helper

2020-05-25 Thread Gustavo A. R. Silva
, bus_rel->device_count) respectively. Signed-off-by: Gustavo A. R. Silva --- drivers/pci/controller/pci-hyperv.c | 22 -- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/drivers/pci/controller/pci-hyperv.c b/drivers/pci/controller/pci-hyperv.c index 8

[PATCH] audit: Use struct_size() helper in alloc_chunk

2020-05-24 Thread Gustavo A. R. Silva
eplace the following form: offsetof(struct audit_chunk, owners) + count * sizeof(struct node); with: struct_size(chunk, owners, count) This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- kernel/audit_tree.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletion

Re: [PATCH] drm/amdgpu/smu10: Replace one-element array and use struct_size() helper

2020-05-22 Thread Gustavo A. R. Silva
On Wed, May 20, 2020 at 09:42:27AM +0200, Christian König wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Acked-by: Christian König > > May I suggest that we add a section how to correctly do this to > Documentation/process/coding-style.rst or similar documen

[PATCH] drm/[radeon|amdgpu]: Replace one-element array and use struct_size() helper

2020-05-22 Thread Gustavo A. R. Silva
ize of struct SISLANDS_SMC_SWSTATE. This issue was found with the help of Coccinelle and, audited and fixed _manually_. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-o

[PATCH v2] drm/radeon/dpm: Replace one-element array and use struct_size() helper

2020-05-22 Thread Gustavo A. R. Silva
ed-by: Christian König Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Use type size_t instead of u16 for state_size variable. drivers/gpu/drm/amd/amdgpu/si_dpm.h | 2 +- drivers/gpu/drm/radeon/ni_dpm.c | 7 --- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/dri

Re: [PATCH] drm/radeon/dpm: Replace one-element array and use struct_size() helper

2020-05-22 Thread Gustavo A. R. Silva
On Fri, May 22, 2020 at 09:00:09AM +0200, Christian König wrote: > > +++ b/drivers/gpu/drm/radeon/ni_dpm.c > > @@ -2685,11 +2685,12 @@ static int ni_upload_sw_state(struct radeon_device > > *rdev, > > struct rv7xx_power_info *pi = rv770_get_pi(rdev); > > u16 address = pi->state_table_start

[PATCH] drm/radeon/dpm: Replace one-element array and use struct_size() helper

2020-05-21 Thread Gustavo A. R. Silva
ize of struct NISLANDS_SMC_SWSTATE. This issue was found with the help of Coccinelle and, audited and fixed _manually_. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-o

Re: [PATCH] x86/uv/time: Replace one-element array and save heap space

2020-05-21 Thread Gustavo A. R. Silva
[+CC John Stultz and +Kees' Reviewed-by tag] Reviewed-by: Kees Cook On Mon, May 18, 2020 at 02:01:14PM -0500, Gustavo A. R. Silva wrote: > The current codebase makes use of one-element arrays in the following > form: > > struct something { > int length; > u8 da

[PATCH] security: integrity: Replace zero-length array with flexible-array member

2020-05-21 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

Re: [PATCH] ethernet: i825xx: sun3_82586: Replace zero-length array with flexible-array

2020-05-21 Thread Gustavo A. R. Silva
Hi Andrew, I wonder if you could take this in your tree. Apparently, Sam hasn't been active since 2007. Thanks -- Gustavo On Thu, May 07, 2020 at 02:24:56PM -0500, Gustavo A. R. Silva wrote: > The current codebase makes use of the zero-length array language > extension to the C90 st

[PATCH] m68k: tools: Replace zero-length array with flexible-array member

2020-05-21 Thread Gustavo A. R. Silva
lle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- arch/m68k/tools/amiga/dmesg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-

Re: [PATCH] iwlwifi: Replace zero-length array with flexible-array

2020-05-21 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this? Thanks -- Gustavo On Thu, May 07, 2020 at 01:55:38PM -0500, Gustavo A. R. Silva wrote: > The current codebase makes use of the zero-length array language > extension to the C90 standard, but the preferred mechanism to declare > variable-len

Re: [PATCH] ibft: Replace zero-length array with flexible-array

2020-05-21 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this? Thanks -- Gustavo On Thu, May 07, 2020 at 01:55:44PM -0500, Gustavo A. R. Silva wrote: > The current codebase makes use of the zero-length array language > extension to the C90 standard, but the preferred mechanism to declare > variable-len

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

2020-05-20 Thread Gustavo A. R. Silva
On Wed, May 20, 2020 at 06:52:21PM -0500, Li Yang wrote: > On Mon, May 18, 2020 at 5:57 PM Kees Cook wrote: > > > > On Mon, May 18, 2020 at 05:19:04PM -0500, Gustavo A. R. Silva wrote: > > > The current codebase makes use of one-element arrays in the following > &

[PATCH perf/core] perf branch: Replace zero-length array with flexible-array

2020-05-20 Thread Gustavo A. R. Silva
our") Signed-off-by: Gustavo A. R. Silva --- tools/perf/util/branch.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/util/branch.h b/tools/perf/util/branch.h index 4d3f02fa223df..17b2ccc61094b 100644 --- a/tools/perf/util/branch.h +++ b/tools/perf/util/branch.h

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

2020-05-19 Thread Gustavo A. R. Silva
On Tue, May 19, 2020 at 08:52:31PM -0300, Jason Gunthorpe wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > --- > > drivers/infiniband/sw/siw/siw.h | 2 +- > > drivers/infiniband/sw/siw/siw_mem.c | 5 + > > 2 files changed, 2 insertions(+), 5 d

[PATCH] RDMA/siw: Replace one-element array and use struct_size() helper

2020-05-19 Thread Gustavo A. R. Silva
ize of struct siw_pbl. This issue was found with the help of Coccinelle and, audited and fixed _manually_. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gus

[PATCH] drm/amdgpu/smu10: Replace one-element array and use struct_size() helper

2020-05-19 Thread Gustavo A. R. Silva
) Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c | 6 ++ drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.h | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c b/drivers/gpu/drm/amd

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 { &

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-19 Thread Gustavo A. R. Silva
at, 16 May 2020 15:12:28 +0300 > Subject: [PATCH] perf intel-pt: Use allocated branch stack for PEBS sample > > To avoid having struct branch_stack as a non-last structure member, > use allocated branch stack for PEBS sample. > > Signed-off-by: Adrian Hunter Acked-by: G

Re: [tip: locking/core] locking/lockdep: Replace zero-length array with flexible-array

2020-05-19 Thread Gustavo A. R. Silva
On Tue, May 19, 2020 at 06:44:24PM -, tip-bot2 for Gustavo A. R. Silva wrote: > The following commit has been merged into the locking/core branch of tip: > > Commit-ID: db78538c75e49c09b002a2cd96a19ae0c39be771 > Gitweb: > https://git

[tip: perf/core] perf/core: Replace zero-length array with flexible-array

2020-05-19 Thread tip-bot2 for Gustavo A. R. Silva
The following commit has been merged into the perf/core branch of tip: Commit-ID: c50c75e9b87946499a62bffc021e95c87a1d57cd Gitweb: https://git.kernel.org/tip/c50c75e9b87946499a62bffc021e95c87a1d57cd Author:Gustavo A. R. Silva AuthorDate:Mon, 11 May 2020 15:12:27 -05:00

[tip: locking/core] locking/lockdep: Replace zero-length array with flexible-array

2020-05-19 Thread tip-bot2 for Gustavo A. R. Silva
The following commit has been merged into the locking/core branch of tip: Commit-ID: db78538c75e49c09b002a2cd96a19ae0c39be771 Gitweb: https://git.kernel.org/tip/db78538c75e49c09b002a2cd96a19ae0c39be771 Author:Gustavo A. R. Silva AuthorDate:Thu, 07 May 2020 13:58:04 -05:00

[tip: sched/core] sched/fair: Replace zero-length array with flexible-array

2020-05-19 Thread tip-bot2 for Gustavo A. R. Silva
The following commit has been merged into the sched/core branch of tip: Commit-ID: 04f5c362ec6d3ff0e14f1c05230b550da7f528a4 Gitweb: https://git.kernel.org/tip/04f5c362ec6d3ff0e14f1c05230b550da7f528a4 Author:Gustavo A. R. Silva AuthorDate:Thu, 07 May 2020 14:21:41 -05:00

[tip: perf/core] perf/x86: Replace zero-length array with flexible-array

2020-05-19 Thread tip-bot2 for Gustavo A. R. Silva
The following commit has been merged into the perf/core branch of tip: Commit-ID: 8ac7571a8cd3c11da24c3c3555f6e40e33049609 Gitweb: https://git.kernel.org/tip/8ac7571a8cd3c11da24c3c3555f6e40e33049609 Author:Gustavo A. R. Silva AuthorDate:Mon, 11 May 2020 15:09:11 -05:00

[PATCH v2] RDMA/rtrs: client: Fix function return on success

2020-05-19 Thread Gustavo A. R. Silva
Remove the if-statement and return the value contained in _err_, unconditionally. Addresses-Coverity-ID: 1493753 ("Identical code for different branches") Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Signed-off-by: Gustavo A. R. Silva --- Changes

Re: [PATCH v2 1/3] mtd: lpddr: Fix bad logic in print_drs_error

2020-05-19 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this? Thanks -- Gustavo On 4/27/20 15:08, Miquel Raynal wrote: > Hi Gustavo, > > "Gustavo A. R. Silva" wrote on Mon, 27 Apr > 2020 14:50:37 -0500: > >> Update logic for broken test. Use a more common logging style. >

[PATCH] RDMA/rtrs: client: Fix function return on success

2020-05-19 Thread Gustavo A. R. Silva
The function should return 0 on success, instead of err. Addresses-Coverity-ID: 1493753 ("Identical code for different branches") Fixes: 6a98d71daea1 ("RDMA/rtrs: client: main functionality") Signed-off-by: Gustavo A. R. Silva --- drivers/infiniband/ulp/rtrs/rtrs-clt.c | 3

Re: [PATCH] x86/uv/time: Replace one-element array and save heap space

2020-05-18 Thread Gustavo A. R. Silva
On Mon, May 18, 2020 at 12:09:16PM -0700, Joe Perches wrote: > On Mon, 2020-05-18 at 14:01 -0500, Gustavo A. R. Silva wrote: > > The current codebase makes use of one-element arrays in the following > > form: > > > > struct something { > > int length; > &g

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

2020-05-18 Thread Gustavo A. R. Silva
e help of Coccinellea and, audited and fixed _manually_. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- drivers/acpi/acpica/utids.c |

[PATCH] soc: fsl: qe: Replace one-element array and use struct_size() helper

2020-05-18 Thread Gustavo A. R. Silva
ize of struct qe_firmware. This issue was found with the help of Coccinelle and, audited and fixed _manually_. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gus

[PATCH] x86/uv/time: Replace one-element array and save heap space

2020-05-18 Thread Gustavo A. R. Silva
mit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva --- arch/x86/platform/uv/uv_time.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/arch/x86/platform/uv/uv_time.c b/arch/x86/platform/uv/uv_time.c index 7af31b245636..993

Re: [PATCH] KEYS: Replace zero-length array with flexible-array

2020-05-18 Thread Gustavo A. R. Silva
On Mon, May 18, 2020 at 04:14:24PM +0100, David Howells wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Applied to keys-next. > Thanks, David. -- Gustavo

Re: [PATCH] pcmcia: Replace zero-length array with flexible-array

2020-05-18 Thread Gustavo A. R. Silva
On Mon, May 18, 2020 at 11:16:13AM +0200, Dominik Brodowski wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Applied to pcmcia-next. > Thanks, Dominik. -- Gustavo

Re: [PATCH] Bluetooth: L2CAP: Replace zero-length array with flexible-array

2020-05-18 Thread Gustavo A. R. Silva
On Mon, May 18, 2020 at 09:58:22AM +0200, Marcel Holtmann wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > --- > > include/net/bluetooth/l2cap.h | 6 +++--- > > 1 file changed, 3 insertions(+), 3 deletions(-) > > patch has been applied to bluetooth-next tree. > Thanks, Marcel. -- Gustavo

Re: [PATCH] apparmor: Replace zero-length array with flexible-array

2020-05-15 Thread Gustavo A. R. Silva
On Fri, May 15, 2020 at 01:03:47PM -0700, John Johansen wrote: > > > > Signed-off-by: Gustavo A. R. Silva > Acked-by: John Johansen > > I have pulled this into my tree Great. :) Thanks, John. -- Gustavo

[PATCH v2 perf/core] perf tools: Replace zero-length array with flexible-array

2020-05-15 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-15 Thread Gustavo A. R. Silva
On Fri, May 15, 2020 at 01:43:31PM -0300, Arnaldo Carvalho de Melo wrote: > Em Fri, May 15, 2020 at 01:41:53PM -0300, Arnaldo Carvalho de Melo escreveu: > > Em Thu, May 14, 2020 at 07:10:25PM -0500, Gustavo A. R. Silva escreveu: > > > On Thu, May 14, 2020 at 03:46:05PM -0700

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-14 Thread Gustavo A. R. Silva
On Thu, May 14, 2020 at 05:09:23PM -0700, Ian Rogers wrote: > On Thu, May 14, 2020 at 5:05 PM Gustavo A. R. Silva > wrote: > > > > On Thu, May 14, 2020 at 03:46:05PM -0700, Ian Rogers wrote: > > > On Thu, May 14, 2020 at 3:04 PM Gustavo A. R. Silva > > > w

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-14 Thread Gustavo A. R. Silva
On Thu, May 14, 2020 at 03:46:05PM -0700, Ian Rogers wrote: > On Thu, May 14, 2020 at 3:04 PM Gustavo A. R. Silva > wrote: > > > > On Thu, May 14, 2020 at 12:06:48PM -0700, Ian Rogers wrote: > > > On Thu, May 14, 2020 at 8:01 AM Gustavo A. R. Silva > > > w

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-14 Thread Gustavo A. R. Silva
On Thu, May 14, 2020 at 12:06:48PM -0700, Ian Rogers wrote: > On Thu, May 14, 2020 at 8:01 AM Gustavo A. R. Silva > wrote: > > > > On Thu, May 14, 2020 at 10:10:30AM -0300, Arnaldo Carvalho de Melo wrote: > > > Em Wed, May 13, 2020 at 06:47:38PM -0500, Gustavo A. R.

Re: [PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-14 Thread Gustavo A. R. Silva
On Thu, May 14, 2020 at 10:10:30AM -0300, Arnaldo Carvalho de Melo wrote: > Em Wed, May 13, 2020 at 06:47:38PM -0500, Gustavo A. R. Silva escreveu: > > Fix the following build failure generated with command > > $ make CC=clang HOSTCC=clang -C tools/ perf: > > > > uti

Re: [PATCH v2] tpm: eventlog: Replace zero-length array with flexible-array member

2020-05-13 Thread Gustavo A. R. Silva
On Thu, May 14, 2020 at 03:08:58AM +0300, Jarkko Sakkinen wrote: > > > > > > Signed-off-by: Gustavo A. R. Silva > > > > Reviewed-by: Kees Cook > > Thank you. > > I applied this patch, will include it to the next PR. > Awesome. :) Thanks, Jarkko. -- Gustavo

[PATCH perf/core] perf intel-pt: Fix clang build failure in intel_pt_synth_pebs_sample

2020-05-13 Thread Gustavo A. R. Silva
xible-array") Reported-by: Ian Rogers Signed-off-by: Gustavo A. R. Silva --- Here to fix what I break. :) tools/perf/util/intel-pt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/util/intel-pt.c b/tools/perf/util/intel-pt.c index f17b1e769ae4..b34179e3926

Re: [PATCH RESEND] tpm: eventlog: Replace zero-length array with flexible-array member

2020-05-13 Thread Gustavo A. R. Silva
https://github.com/KSPP/linux/issues/43 > > > > Signed-off-by: Gustavo A. R. Silva > > Reviewed-by: Jarkko Sakkinen > Hi Jarkko, Thanks for your RB. There is a v2 of this patch: https://lore.kernel.org/lkml/20200508163826.GA768@embeddedor/ Thanks -- Gustavo

Re: [PATCH] perf tools: Replace zero-length array with flexible-array

2020-05-13 Thread Gustavo A. R. Silva
On Wed, May 13, 2020 at 02:03:56PM -0700, Ian Rogers wrote: > On Tue, May 12, 2020 at 10:59 AM Gustavo A. R. Silva > wrote: > > > > On Tue, May 12, 2020 at 10:06:07AM +0200, Peter Zijlstra wrote: > > > On Mon, May 11, 2020 at 07:04:04PM -0500, Gustavo A. R. Silva wr

[PATCH] Bluetooth: L2CAP: Replace zero-length array with flexible-array

2020-05-13 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

Re: [PATCH] Bluetooth: Replace zero-length array with flexible-array

2020-05-13 Thread Gustavo A. R. Silva
Hi Marcel, On Wed, May 13, 2020 at 09:30:03AM +0200, Marcel Holtmann wrote: > > --- > > include/net/bluetooth/l2cap.h |6 +++--- > > include/net/bluetooth/mgmt.h | 40 > > > > 2 files changed, 23 insertions(+), 23 deletions(-) > > the mgmt.h portion

Re: [PATCH] i2c: mux: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Tue, May 12, 2020 at 12:43:19PM +0200, Wolfram Sang wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Applied to for-next, thanks! Gustavo, let me know if you think it should > be in for-current. > Hi Wolfram, If that's not much work for you, then it

Re: [PATCH] MIPS: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Fri, May 08, 2020 at 03:02:49PM +0200, Thomas Bogendoerfer wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > --- > > arch/mips/kernel/signal.c |2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > applied to mips-next. > Thanks, Thomas. -- Gustavo

Re: [PATCH] rbd: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Fri, May 08, 2020 at 09:54:12AM +0200, Ilya Dryomov wrote: > > Applied (folded into libceph patch). > Thanks, Ilya. -- Gustavo

Re: [PATCH] thunderbolt: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Mon, May 11, 2020 at 01:34:15PM +0300, Mika Westerberg wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Applied, thanks! Thanks, Mika. -- Gustavo

Re: [PATCH] scsi: ufs: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Tue, May 12, 2020 at 03:28:31AM +, Martin K. Petersen wrote: > On Thu, 7 May 2020 14:25:50 -0500, Gustavo A. R. Silva wrote: > > Applied to 5.8/scsi-queue, thanks! > > [1/1] scsi: ufs: Replace zero-length array with flexible-array > https://git.kernel.org/mkp/s

Re: [PATCH v2] tpm: eventlog: Replace zero-length array with flexible-array member

2020-05-12 Thread Gustavo A. R. Silva
On Mon, May 11, 2020 at 10:24:10PM -0700, Kees Cook wrote: > On Fri, May 08, 2020 at 11:38:26AM -0500, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to declare > >

Re: [PATCH RESEND] ASoC: Intel: Skylake: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Tue, May 12, 2020 at 05:44:50PM +0100, Mark Brown wrote: > > Applied to > >https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.8 > Thanks, Mark. -- Gustavo

Re: [PATCH] ALSA: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 10:31:26PM +0200, Takashi Iwai wrote: > On Thu, 07 May 2020 21:22:23 +0200, > Gustavo A. R. Silva wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Thanks, applied now to for-next branch. > Thanks, Takashi. -- Gustavo

Re: [PATCH] memstick: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Fri, May 08, 2020 at 10:12:11AM +0200, Ulf Hansson wrote: > On Thu, 7 May 2020 at 21:17, Gustavo A. R. Silva > wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > Applied for next, thanks! > Thanks, Uffe. -- Gustavo

Re: [PATCH] sparc64: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 06:49:16PM -0700, David Miller wrote: > From: "Gustavo A. R. Silva" > Date: Thu, 7 May 2020 14:23:02 -0500 > > > Signed-off-by: Gustavo A. R. Silva > > Applied, thank you. Thanks, Dave. -- Gustavo

Re: [PATCH] perf tools: Replace zero-length array with flexible-array

2020-05-12 Thread Gustavo A. R. Silva
On Tue, May 12, 2020 at 10:06:07AM +0200, Peter Zijlstra wrote: > On Mon, May 11, 2020 at 07:04:04PM -0500, Gustavo A. R. Silva wrote: > > On Mon, May 11, 2020 at 05:20:08PM -0300, Arnaldo Melo wrote: > > > > > > Thanks, applied > > > > > > > T

Re: [PATCH] perf tools: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
On Mon, May 11, 2020 at 05:20:08PM -0300, Arnaldo Melo wrote: > > Thanks, applied > Thanks, Arnaldo. I wonder if could also take the other two: https://lore.kernel.org/lkml/20200511200911.GA13149@embeddedor/ https://lore.kernel.org/lkml/20200511201227.GA14041@embeddedor/ -- Gustavo

[PATCH] perf/core: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] perf/x86: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] perf tools: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

Re: [PATCH] perf script: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
On Mon, May 11, 2020 at 03:48:55PM -0300, Arnaldo Melo wrote: > >> > >> Can you split this into a kernel part and tools/ one? Also this is > >not > >> really just for "perf script", so please adjust the subject line too > >:-) > >> > > > >Sure thing. :) > > > >Is that OK if I use "perf: " for the

[PATCH RESEND] ASoC: Intel: Skylake: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

Re: [PATCH] perf script: Replace zero-length array with flexible-array

2020-05-11 Thread Gustavo A. R. Silva
On Mon, May 11, 2020 at 12:48:12PM -0300, Arnaldo Carvalho de Melo wrote: > Em Thu, May 07, 2020 at 02:06:15PM -0500, Gustavo A. R. Silva escreveu: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mecha

Re: [PATCH net-next 1/2] ath10k: fix gcc-10 zero-length-bounds warnings

2020-05-09 Thread Gustavo A. R. Silva
Arnd, On Sat, May 09, 2020 at 02:06:32PM +0200, Arnd Bergmann wrote: > gcc-10 started warning about out-of-bounds access for zero-length > arrays: > > In file included from drivers/net/wireless/ath/ath10k/core.h:18, > from drivers/net/wireless/ath/ath10k/htt_rx.c:8: > drivers/net

Re: [PATCH] audit: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 10:52:09PM -0400, Paul Moore wrote: > > > > Signed-off-by: Gustavo A. R. Silva > > --- > > include/linux/audit.h |2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > Merged into audit/next, thanks! > Thanks, Paul. -- Gustavo

Re: [PATCH] efi: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
On Fri, May 08, 2020 at 10:26:40AM -0700, Linus Torvalds wrote: > On Thu, May 7, 2020 at 12:22 PM Gustavo A. R. Silva > wrote: > > > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to dec

Re: [PATCH] audit: mark expected switch fall-through

2020-05-08 Thread Gustavo A. R. Silva
On Tue, Feb 12, 2019 at 08:19:44PM -0500, Paul Moore wrote: > On Tue, Feb 12, 2019 at 3:46 PM Gustavo A. R. Silva > wrote: > > In preparation to enabling -Wimplicit-fallthrough, mark switch > > cases where we are expecting to fall through. > > > > This pat

[PATCH] firmware: qcom_scm-legacy: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
ffrey Hugo Signed-off-by: Gustavo A. R. Silva --- drivers/firmware/qcom_scm-legacy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/firmware/qcom_scm-legacy.c b/drivers/firmware/qcom_scm-legacy.c index 8532e7c78ef7..eba6b60bfb61 100644 --- a/drivers/firmware/qcom_s

[PATCH] dmaengine: qcom: bam_dma: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
ffrey Hugo Signed-off-by: Gustavo A. R. Silva --- drivers/dma/qcom/bam_dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma/qcom/bam_dma.c b/drivers/dma/qcom/bam_dma.c index ef73f65224b1..5a08dd0d3388 100644 --- a/drivers/dma/qcom/bam_dma.c +++ b/drivers/dma/qcom

Re: [PATCH] PCI: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 03:15:44PM -0500, Bjorn Helgaas wrote: > On Thu, May 07, 2020 at 02:05:44PM -0500, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to declare >

Re: [PATCH] dmaengine: qcom: bam_dma: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
On Fri, May 08, 2020 at 11:20:16AM -0600, Jeffrey Hugo wrote: > On 5/8/2020 11:02 AM, Gustavo A. R. Silva wrote: > > On Thu, May 07, 2020 at 01:24:57PM -0600, Jeffrey Hugo wrote: > > > >drivers/dma/qcom/bam_dma.c |2 +- > > > >drivers/

Re: [PATCH] dmaengine: qcom: bam_dma: Replace zero-length array with flexible-array

2020-05-08 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 01:24:57PM -0600, Jeffrey Hugo wrote: > > drivers/dma/qcom/bam_dma.c |2 +- > > drivers/firmware/qcom_scm-legacy.c |2 +- > > 2 files changed, 2 insertions(+), 2 deletions(-) > > > > Shouldn't these two files be two different patches? > I believe so..

[PATCH v2] tpm: eventlog: Replace zero-length array with flexible-array member

2020-05-08 Thread Gustavo A. R. Silva
https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") [4] https://github.com/KSPP/linux/issues/43 Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Update changelog text. - Make use of the struct_size() helper. drivers/char/tpm

Re: [PATCH RESEND] tpm: eventlog: Replace zero-length array with flexible-array member

2020-05-08 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 11:02:18AM -0700, Kees Cook wrote: > On Wed, May 06, 2020 at 11:09:12PM -0500, Gustavo A. R. Silva wrote: > > As mentioned above: "Flexible array members have incomplete type, and > > so the sizeof operator may not be applied. As a quirk of the origina

Re: [PATCH] tools/testing: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 01:04:14PM -0600, Shuah Khan wrote: > > > > diff --git a/tools/testing/selftests/nsfs/pidns.c > > b/tools/testing/selftests/nsfs/pidns.c > > index e0d86e1668c0..e3c772c6a7c7 100644 > > --- a/tools/testing/selftests/nsfs/pidns.c > > +++ b/tools/testing/selftests/nsfs/pidns.

Re: [PATCH] audit: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
On Thu, May 07, 2020 at 05:58:13PM -0400, Richard Guy Briggs wrote: > On 2020-05-07 13:50, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to declare > > variable

Re: [PATCH] media: venus: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
-length array with flexible-array member > > 380f3bbd9562dc93be2e3cadc329b15284fbedae media: venus: hfi_cmds.h: > Replace zero-length array with flexible-array member > > > On 5/7/20 10:07 PM, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-leng

[PATCH] xfs: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gus

[PATCH] w1: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] um: virtio: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] rndis_wlan: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] efi: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] tty: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] tracing/probe: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

[PATCH] scsi: ufs: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
lso help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-of

<    5   6   7   8   9   10   11   12   13   14   >