Re: [PATCH v2 0/3] PPC: Fix -Wimplicit-fallthrough for clang

2020-11-18 Thread Gustavo A. R. Silva
Nick, On Tue, Nov 17, 2020 at 04:07:48PM -0800, Nick Desaulniers wrote: > While cleaning up the last few -Wimplicit-fallthrough warnings in tree > for Clang, I noticed > commit 6a9dc5fd6170d ("lib: Revert use of fallthrough pseudo-keyword in lib/") > which seemed to undo a bunch of fixes in lib/

Re: [PATCH 2/3] Revert "lib: Revert use of fallthrough pseudo-keyword in lib/"

2020-11-17 Thread Gustavo A. R. Silva
On Tue, Nov 17, 2020 at 02:28:43PM -0800, Nick Desaulniers wrote: > On Tue, Nov 17, 2020 at 2:16 PM Gustavo A. R. Silva > wrote: > > > > I'm happy to take this series in my tree. I'm planing to send a > > pull-request for -rc5 with more related changes. So, I can include

Re: [PATCH 2/3] Revert "lib: Revert use of fallthrough pseudo-keyword in lib/"

2020-11-17 Thread Gustavo A. R. Silva
On Tue, Nov 17, 2020 at 11:10:26AM -0800, Nick Desaulniers wrote: > On Mon, Nov 16, 2020 at 7:02 PM Nathan Chancellor > wrote: > > > > On Sun, Nov 15, 2020 at 08:35:31PM -0800, Nick Desaulniers wrote: > > > This reverts commit 6a9dc5fd6170 ("lib: Revert use of fallthrough > > > pseudo-keyword in

Re: [PATCH 3/3] powerpc: fix -Wimplicit-fallthrough

2020-11-15 Thread Gustavo A. R. Silva
se cases. > > Link: https://github.com/ClangBuiltLinux/linux/issues/236 > Signed-off-by: Nick Desaulniers Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo > --- > arch/powerpc/kernel/prom_init.c | 1 + > arch/powerpc/kernel/uprobes.c | 1 + > arch/powerpc/perf/i

Re: [PATCH 2/3] Revert "lib: Revert use of fallthrough pseudo-keyword in lib/"

2020-11-15 Thread Gustavo A. R. Silva
or lib/. > > Link: https://github.com/ClangBuiltLinux/linux/issues/236 > Signed-off-by: Nick Desaulniers Reviewed-by: Gustavo A. R. Silva Thanks -- Gustavo > --- > lib/asn1_decoder.c | 4 ++-- > lib/assoc_array.c | 2 +- > lib/bootconfig.c| 4 ++-- > l

Re: [PATCH 1/3] powerpc: boot: include compiler_attributes.h

2020-11-15 Thread Gustavo A. R. Silva
com/ClangBuiltLinux/linux/issues/236 > Signed-off-by: Nick Desaulniers Acked-by: Gustavo A. R. Silva Thanks, Nick. -- Gustavo > --- > We could just `#include "include/linux/compiler_types.h"` in the few .c > sources used from lib/ (there are proper header guards in > comp

Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;

2020-09-09 Thread Gustavo A. R. Silva
eak; > > Found using: > > $ grep-2.5.4 -rP --include=*.[ch] -n > "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" * > > Miscellanea: > > o Move or coalesce a couple label blocks above a default: block. > > Signed-off-by: Joe P

Re: [GIT PULL] fallthrough pseudo-keyword macro conversions for 5.9-rc3

2020-08-24 Thread Gustavo A. R. Silva
Hi Nathan, On 8/24/20 14:43, Nathan Chancellor wrote: >> Gustavo A. R. Silva (1): >> treewide: Use fallthrough pseudo-keyword > > $ scripts/config --file arch/powerpc/configs/powernv_defconfig -e KERNEL_XZ > > $ make -skj"$(nproc)" ARCH=powerpc CROSS_CO

[PATCH][next] powerpc: Use fallthrough pseudo-keyword

2020-07-27 Thread Gustavo A. R. Silva
-through Signed-off-by: Gustavo A. R. Silva --- arch/powerpc/kernel/align.c | 8 arch/powerpc/platforms/powermac/feature.c | 2 +- arch/powerpc/platforms/powernv/opal-async.c | 2 +- arch/powerpc/platforms/pseries/hvcserver.c | 2 +- arch/powerpc/xmon/xmon.c

[PATCH][next] dmaengine: Use fallthrough pseudo-keyword

2020-07-27 Thread Gustavo A. R. Silva
-through Signed-off-by: Gustavo A. R. Silva --- drivers/dma/amba-pl08x.c| 10 +- drivers/dma/fsldma.c| 2 +- drivers/dma/imx-dma.c | 2 +- drivers/dma/iop-adma.h | 12 ++-- drivers/dma/nbpfaxi.c | 2 +- drivers/dma/pl330.c | 10

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] soc: fsl: qe: Replace one-element array and use struct_size() helper

2020-05-18 Thread Gustavo A. R. Silva
e size 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] powerpc/mm: Replace zero-length array with flexible-array

2020-05-07 Thread Gustavo A. R. Silva
elp 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:

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

2020-05-07 Thread Gustavo A. R. Silva
elp 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:

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

2020-05-07 Thread Gustavo A. R. Silva
elp 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:

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

2020-02-25 Thread Gustavo A. R. Silva
On 2/25/20 07:44, Horia Geanta wrote: > On 2/24/2020 6:18 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 declare >> variable-length types such as these one

[PATCH][next] toshiba: Replace zero-length array with flexible-array member

2020-02-24 Thread Gustavo A. R. Silva
[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/net/ethernet/toshiba/ps3_gelic_net.h | 2 +- drivers/net/ethernet/toshiba/ps3_

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

2020-02-24 Thread Gustavo A. R. Silva
[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/crypto/caam/caamalg.c | 2 +- drivers/crypto/caam/caamalg_qi.c

Re: [PATCH] powerpc: sysdev: xive: Fix use true/false for bool type

2019-10-28 Thread Gustavo A. R. Silva
This is not actually a 'fix' I suggest you to rephrase the subject in a different way and remove the word 'fix' from it. On 10/28/19 22:40, Saurav Girepunje wrote: > Use true/false for bool return type in xive_spapr_cleanup_queue > function. > How do you find this? If you used a tool to

[PATCH] dmaengine: fsldma: Mark expected switch fall-through

2019-08-11 Thread Gustavo A. R. Silva
->toggle_ext_pause = fsl_chan_toggle_ext_pause; ~~~^~~ drivers/dma/fsldma.c:1166:2: note: here case FSL_DMA_IP_83XX: ^~~~ Reported-by: kbuild test robot Signed-off-by: Gustavo A. R. Silva --- drivers/dma/fsldma.c | 1 + 1 file changed, 1 insert

Re: [PATCH] powerpc/kvm: Fall through switch case explicitly

2019-07-29 Thread Gustavo A. R. Silva
On 7/29/19 10:50 PM, Stephen Rothwell wrote: > Hi Gustavo, > > On Mon, 29 Jul 2019 22:30:34 -0500 "Gustavo A. R. Silva" > wrote: >> >> If no one takes it by tomorrow, I'll take it in my tree. > > I am assuming that Michael Ellerman will take it in

Re: [PATCH] powerpc/kvm: Fall through switch case explicitly

2019-07-29 Thread Gustavo A. R. Silva
Hi Stephen, On 7/29/19 10:18 PM, Stephen Rothwell wrote: > Hi all, > > On Mon, 29 Jul 2019 18:45:40 -0500 "Gustavo A. R. Silva" > wrote: >> >> On 7/29/19 3:16 AM, Stephen Rothwell wrote: >>> >>> On Mon, 29 Jul 2019 11:25:36 +0530 Santosh S

Re: [PATCH] powerpc/kvm: Fall through switch case explicitly

2019-07-29 Thread Gustavo A. R. Silva
>> Signed-off-by: Santosh Sivaraj Reviewed-by: Gustavo A. R. Silva Thanks! -- Gustavo >> --- >> arch/powerpc/kvm/book3s_32_mmu.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/arch/powerpc/kvm/book3s_32_mmu.c >> b/arch/powerpc/kvm/book3s_32

[PATCH] scsi: ibmvfc: Mark expected switch fall-throughs

2019-07-28 Thread Gustavo A. R. Silva
bmvscsi/ibmvfc.c:1841:2: note: here case FC_BSG_RPT_CT: ^~~~ Reported-by: Stephen Rothwell Signed-off-by: Gustavo A. R. Silva --- drivers/scsi/ibmvscsi/ibmvfc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c index 8cdbac076a

Re: [PATCH V5] ASoC: fsl_esai: Fix missing break in switch statement

2019-05-01 Thread Gustavo A. R. Silva
Mark, I wonder if you are going to take this patch. Thanks -- Gustavo On 4/11/19 3:43 AM, S.j. Wang wrote: > case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be > independent of each other, so replace fall-through with break. > > Fixes: 43d24e76b698 ("ASoC: fsl_esai: Add ESAI CPU DAI

Re: [PATCH V4] ASoC: fsl_esai: Fix missing break in switch statement

2019-04-10 Thread Gustavo A. R. Silva
On 4/10/19 10:24 PM, Gustavo A. R. Silva wrote: > [+cc lkml] > > On 4/10/19 10:05 PM, S.j. Wang wrote: >> case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be >> independent of each other, so replace fall-through with break. >> >> Fixes: 43d24e76b698 (

Re: [PATCH V4] ASoC: fsl_esai: Fix missing break in switch statement

2019-04-10 Thread Gustavo A. R. Silva
[+cc lkml] On 4/10/19 10:05 PM, S.j. Wang wrote: > case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be > independent of each other, so replace fall-through with break. > > Fixes: 43d24e76b698 ("ASoC: fsl_esai: Add ESAI CPU DAI driver") > > Signed-off-by: Shengjiu Wang > Acked-by: Nicolin

Re: [PATCH V2] ASoC: fsl_esai: replace fall-through with break

2019-04-10 Thread Gustavo A. R. Silva
On 4/9/19 9:42 PM, S.j. Wang wrote: > case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be independent of > each other, so replace fall-through with break. > I think you should change the subject line to: fix missing break in switch statement ...because you are fixing a bug, and it's

Re: [EXT] Re: [PATCH V1] ASoC: fsl_esai: replace fall-through with break

2019-04-08 Thread Gustavo A. R. Silva
Hi Shengjiu, On 4/8/19 9:54 PM, S.j. Wang wrote: > Hi Gustavo > >> >> >> On 4/8/19 4:28 AM, S.j. Wang wrote: >>> case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be >> independent of >>> each other, so replace fall-through with break. >>> >> If this is correct, then you should use the

Re: [PATCH V1] ASoC: fsl_esai: replace fall-through with break

2019-04-08 Thread Gustavo A. R. Silva
On 4/8/19 4:28 AM, S.j. Wang wrote: > case ESAI_HCKT_EXTAL and case ESAI_HCKR_EXTAL should be independent of > each other, so replace fall-through with break. > If this is correct, then you should use the following "Fixes" tag instead, which is the one that introduced the bug: Fixes:

[PATCH] tty: hvc_xen: Mark expected switch fall-through

2019-02-25 Thread Gustavo A. R. Silva
GCC is expecting to find. This patch is part of the ongoing efforts to enable -Wimplicit-fallthrough Signed-off-by: Gustavo A. R. Silva --- drivers/tty/hvc/hvc_xen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/hvc/hvc_xen.c b/drivers/tty/hvc/hvc_xen.c index dc43fa96c

Re: [PATCH V2] powerpc/ptrace: Mitigate potential Spectre v1

2019-01-30 Thread Gustavo A. R. Silva
irst load and not worry if it can be > completed with a dependent load/store [1]. > > [1] https://marc.info/?l=linux-kernel=152449131114778=2 > > Signed-off-by: Breno Leitao Acked-by: Gustavo A. R. Silva > --- > arch/powerpc/kernel/ptrace.c | 8 +++- > 1 file changed, 7 insertions

Re: [PATCH] powerpc/ptrace: Mitigate potential Spectre v1

2019-01-29 Thread Gustavo A. R. Silva
Hi Breno, On 1/29/19 10:38 AM, Breno Leitao wrote: > Hi Gustavo, > > On 1/24/19 3:25 PM, Gustavo A. R. Silva wrote: >> >> >> On 1/24/19 8:01 AM, Breno Leitao wrote: >>> 'regno' is directly controlled by user space, hence leading to a potential >&

Re: powerpc/ps3: Use struct_size() in kzalloc()

2019-01-24 Thread Gustavo A. R. Silva
On 1/23/19 9:40 PM, Michael Ellerman wrote: > On Tue, 2019-01-08 at 21:00:10 UTC, "Gustavo A. R. Silva" wrote: >> One of the more common cases of allocation size calculations is finding the >> size of a structure that has a zero-sized array at the end, along with

Re: [PATCH] powerpc/ptrace: Mitigate potential Spectre v1

2019-01-24 Thread Gustavo A. R. Silva
On 1/24/19 8:01 AM, Breno Leitao wrote: > 'regno' is directly controlled by user space, hence leading to a potential > exploitation of the Spectre variant 1 vulnerability. > > On PTRACE_SETREGS and PTRACE_GETREGS requests, user space passes the > register number that would be read or written.

Re: [PATCH] powerpc/ps3: Use struct_size() in kzalloc()

2019-01-16 Thread Gustavo A. R. Silva
Hi Geoff, On 1/16/19 11:21 AM, Geoff Levand wrote: Hi Gustavo, On 1/8/19 1:00 PM, Gustavo A. R. Silva wrote: One of the more common cases of allocation size calculations is finding the size of a structure that has a zero-sized array at the end, along with memory for some number of elements

[PATCH] powerpc/ps3: Use struct_size() in kzalloc()

2019-01-08 Thread Gustavo A. R. Silva
A. R. Silva --- arch/powerpc/platforms/ps3/device-init.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/arch/powerpc/platforms/ps3/device-init.c b/arch/powerpc/platforms/ps3/device-init.c index e7075aaff1bb..59587b75493d 100644 --- a/arch/powerpc/platforms/ps3/device-init.c

[PATCH] powerpc/spufs: use struct_size() in kmalloc()

2019-01-08 Thread Gustavo A. R. Silva
A. R. Silva --- arch/powerpc/platforms/cell/spufs/file.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/platforms/cell/spufs/file.c b/arch/powerpc/platforms/cell/spufs/file.c index ae8123edddc6..48c2477e7e2a 100644 --- a/arch/powerpc/platforms/cell/spufs

Re: New linux-next KCFLAGS

2018-11-26 Thread Gustavo A. R. Silva
On 11/26/18 8:00 AM, Stephen Rothwell wrote: Hi all, On Mon, 26 Nov 2018 17:49:26 +1100 Stephen Rothwell wrote: On Sun, 25 Nov 2018 21:46:20 -0800 Kees Cook wrote: Excellent! (Though, wait, does this mean everyone _else_ will see this too? I'm worried that will be way too noisy...)

Re: [PATCH 4/4] powerpc: Add -Wimplicit-fallthrough to arch CFLAGS

2018-10-13 Thread Gustavo A. R. Silva
On 10/13/18 3:23 AM, Kees Cook wrote: >> >> $ scripts/get_maintainer.pl --nokeywords --nogit --nogit-fallback >> include/linux/compat.h >> linux-ker...@vger.kernel.org (open list) > > Normally things like that go through akpm, but I'm happy to carry them > if needed. > Oh okay. Let me try

Re: [PATCH 4/4] powerpc: Add -Wimplicit-fallthrough to arch CFLAGS

2018-10-12 Thread Gustavo A. R. Silva
On 10/12/18 11:32 AM, Michael Ellerman wrote: > > Sure. The kbuild report up thread has some or most of them. > > But here's a full list: > > Failed 279/290 > http://kisskb.ellerman.id.au/kisskb/head/1d59e2c78793d8aea9949ca71323c4583c78f488/ > Failed:

Re: [PATCH 4/4] powerpc: Add -Wimplicit-fallthrough to arch CFLAGS

2018-10-11 Thread Gustavo A. R. Silva
Hi Michael, On 10/11/18 2:32 AM, Michael Ellerman wrote: > It still pops a few errors, including in linux/signal.h & compat.h, so > it's somewhat aspirational until we can get those fixed up :) > I wonder if you have a log containing those warnings that you can share with me. I'd like to fix

Re: [PATCH 4/4] powerpc: Add -Wimplicit-fallthrough to arch CFLAGS

2018-10-11 Thread Gustavo A. R. Silva
On 10/11/18 3:35 AM, Kees Cook wrote: > On Wed, Oct 10, 2018 at 5:32 PM, Michael Ellerman wrote: >> Kees Cook writes: >>> On Tue, Oct 9, 2018 at 10:13 PM, Michael Ellerman >>> wrote: Warn whenever a switch statement has a fallthrough without a comment annotating it.

[PATCH] powerpc/xmon/ppc-opc: Use ARRAY_SIZE macro

2018-10-04 Thread Gustavo A. R. Silva
Use ARRAY_SIZE instead of dividing sizeof array with sizeof an element. This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- arch/powerpc/xmon/ppc-opc.c | 12 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/xmon/ppc

[PATCH 2/7] ASoC: fsl_esai: Mark expected switch fall-through

2018-08-03 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1222121 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- sound/soc/fsl/fsl_esai.c | 1 + 1 file changed, 1 insertion(+) diff --git a

[PATCH 0/7] ASoC: Mark expected switch fall-throughs

2018-08-03 Thread Gustavo A. R. Silva
Hi all, In preparation to enabling -Wimplicit-fallthrough, this patchset aims to add some annotations in order to mark switch cases where we are expecting to fall through. Thanks Gustavo A. R. Silva (7): ASoC: davinci-i2s: mark expected switch fall-through ASoC: fsl_esai: Mark expected

[PATCH] ASoC: fsl_spdif: Use 64-bit arithmetic instead of 32-bit

2018-07-04 Thread Gustavo A. R. Silva
arithmetic: rate[index] * txclk_df * 64 Addresses-Coverity-ID: 1222129 ("Unintentional integer overflow") Signed-off-by: Gustavo A. R. Silva --- sound/soc/fsl/fsl_spdif.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl_spdif.c b/sound/soc/fsl/fsl_spd

Re: macintosh: change some data types from int to bool

2018-02-03 Thread Gustavo A. R. Silva
Hi Michael, Quoting Michael Ellerman <m...@ellerman.id.au>: "Gustavo A. R. Silva" <garsi...@embeddedor.com> writes: Hi Michael, Quoting Michael Ellerman <patch-notificati...@ellerman.id.au>: On Wed, 2018-01-24 at 01:42:28 UTC, "Gustavo A. R. Si

Re: macintosh: change some data types from int to bool

2018-01-29 Thread Gustavo A. R. Silva
Hi Michael, Quoting Michael Ellerman <patch-notificati...@ellerman.id.au>: On Wed, 2018-01-24 at 01:42:28 UTC, "Gustavo A. R. Silva" wrote: Change the data type of the following variables from int to bool across all macintosh drivers: started slots_started pm121_started wf_s

[PATCH] macintosh/ams-input: Use true and false for boolean values

2018-01-23 Thread Gustavo A. R. Silva
Assign true or false to boolean variables instead of an integer value. This issue was detected with the help of Coccinelle Signed-off-by: Gustavo A. R. Silva <gust...@embeddedor.com> --- drivers/macintosh/ams/ams-input.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

[PATCH] macintosh: change some data types from int to bool

2018-01-23 Thread Gustavo A. R. Silva
Change the data type of the following variables from int to bool across all macintosh drivers: started slots_started pm121_started wf_smu_started Some of these issues were detected with the help of Coccinelle. Suggested-by: Michael Ellerman <m...@ellerman.id.au> Signed-off-by: Gustav

Re: [PATCH] drivers/macintosh: Use true for boolean value

2018-01-23 Thread Gustavo A. R. Silva
Quoting "Gustavo A. R. Silva" <garsi...@embeddedor.com>: Quoting Michael Ellerman <m...@ellerman.id.au>: "Gustavo A. R. Silva" <gust...@embeddedor.com> writes: Assign true or false to boolean variables instead of an integer value. This issue wa

Re: [PATCH] drivers/macintosh: Use true for boolean value

2018-01-23 Thread Gustavo A. R. Silva
Quoting Michael Ellerman <m...@ellerman.id.au>: "Gustavo A. R. Silva" <gust...@embeddedor.com> writes: Assign true or false to boolean variables instead of an integer value. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva &

[PATCH] drivers/macintosh: Use true for boolean value

2018-01-23 Thread Gustavo A. R. Silva
Assign true or false to boolean variables instead of an integer value. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva <gust...@embeddedor.com> --- drivers/macintosh/windfarm_pm72.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [alsa-devel] [PATCH] ASoC: fsl_asrc: constify snd_soc_dai_ops structure

2017-07-16 Thread Gustavo A. R. Silva
to get all the supporters, maintainers and lists: $ scripts/get_maintainer.pl --nokeywords --nogit --nogit-fallback Thank you -- Gustavo A. R. Silva

Re: [alsa-devel] [PATCH] ASoC: fsl_asrc: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
Hi Joe, Quoting Joe Perches <j...@perches.com>: On Thu, 2017-07-13 at 10:18 -0500, Gustavo A. R. Silva wrote: Hi Mark, Quoting Mark Brown <broo...@kernel.org>: > On Thu, Jul 13, 2017 at 09:32:41AM +0200, Takashi Iwai wrote: > > > please stop posting in this styl

Re: [alsa-devel] [PATCH] ASoC: fsl_asrc: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
eryone affected by a single patch in the set on everything, that's harder to avoid when sending a series via git, but it can be confusing to get one item in a large patch series without context). I like this idea better. I will do so next time. :) Thank you -- Gustavo A. R. Silva

[PATCH] ASoC: fsl_esai: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
This structure is only stored in the ops field of a snd_soc_dai_driver structure. That field is declared const, so snd_soc_dai_ops structures that have this property can be declared as const also. Signed-off-by: Gustavo A. R. Silva <garsi...@embeddedor.com> --- sound/soc/fsl/fsl_esai.c | 2

Re: [alsa-devel] [PATCH] ASoC: fsl_asrc: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
thread. git-send-email does it right. I will do that. Thanks for the suggestion. -- Gustavo A. R. Silva I don't mind a couple of patches posted separately, but this is over the limit. thanks, Takashi On Thu, 13 Jul 2017 09:23:51 +0200, Gustavo A. R. Silva wrote: This structure is only

[PATCH] ASoC: fsl_asrc: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
This structure is only stored in the ops field of a snd_soc_dai_driver structure. That field is declared const, so snd_soc_dai_ops structures that have this property can be declared as const also. Signed-off-by: Gustavo A. R. Silva <garsi...@embeddedor.com> --- sound/soc/fsl/fsl_asrc.c | 2

[PATCH] ASoC: fsl_spdif: constify snd_soc_dai_ops structure

2017-07-13 Thread Gustavo A. R. Silva
This structure is only stored in the ops field of a snd_soc_dai_driver structure. That field is declared const, so snd_soc_dai_ops structures that have this property can be declared as const also. Signed-off-by: Gustavo A. R. Silva <garsi...@embeddedor.com> --- sound/soc/fsl/fsl_spdif

[PATCH] usb: gadget: fsl_udc_core: compress return logic into one line

2017-07-09 Thread Gustavo A. R. Silva
Simplify return logic to avoid unnecessary variable assignment. This issue was detected using Coccinelle and the following semantic patch: @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Gustavo A. R. Silva <garsi...@embeddedor.com> --- d

[PATCH] ASoC: imx-ssi: add check on platform_get_irq return value

2017-06-30 Thread Gustavo A. R. Silva
Check return value from call to platform_get_irq(), so in case of failure print error message and propagate the return value. Signed-off-by: Gustavo A. R. Silva <garsi...@embeddedor.com> --- sound/soc/fsl/imx-ssi.c | 4 1 file changed, 4 insertions(+) diff --git a/sound/soc/fsl/imx-s