[PATCH net-next v2 1/2] net: phy: mscc: fix signedness bug in vsc85xx_downshift_get

2018-10-10 Thread Gustavo A. R. Silva
73970 ("Unsigned compared against 0") Fixes: 6a0bfbbe20b0 ("net: phy: mscc: migrate to phy_select/restore_page functions") Reviewed-by: Quentin Schulz Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Add Quentin's Reviewed-by to the commit log. drivers/net/phy/ms

[PATCH net-next v2 2/2] net: phy: mscc: fix memory leak in vsc8574_config_pre_init

2018-10-10 Thread Gustavo A. R. Silva
In case memory resources for *fw* were successfully allocated, release them before return. Addresses-Coverity-ID: 1473968 ("Resource leak") Fixes: 00d70d8e0e78 ("net: phy: mscc: add support for VSC8574 PHY") Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Jump

[PATCH] tpm: fix unused-value issues in tpm_try_transmit

2018-10-10 Thread Gustavo A. R. Silva
removing such assignments. Addresses-Coverity-ID: 1470245 ("Unused value") Addresses-Coverity-ID: 1470250 ("Unused value") Addresses-Coverity-ID: 1470251 ("Unused value") Fixes: 627448e85c76 ("tpm: separate cmd_ready/go_idle from runtime_pm") Signed-off-by: Gu

[PATCH] pinctrl: madera: Fix uninitialized variable issue in madera_mux_set_mux

2018-10-10 Thread Gustavo A. R. Silva
Fix this by initializing variable *ret* to -1. Addresses-Coverity-ID: 1471969 ("Uninitialized scalar variable") Fixes: 218d72a77b0b ("pinctrl: madera: Add driver for Cirrus Logic Madera codecs") Signed-off-by: Gustavo A. R. Silva --- drivers/pinctrl/cirrus/pinctrl-madera

Re: [PATCH] pinctrl: madera: Fix uninitialized variable issue in madera_mux_set_mux

2018-10-10 Thread Gustavo A. R. Silva
Hi Charles, > I don't believe this would fully address the issue since if you > initialise ret to -1 you will still drop into the if statement > and you will use the reg variable which should also be > uninitialised on that code path. > > Feels like initialising to 0 would probably be better anyw

[PATCH v2] pinctrl: madera: Fix uninitialized variable bug in madera_mux_set_mux

2018-10-10 Thread Gustavo A. R. Silva
Fix this by initializing variable *ret* to 0 in order to avoid unpredictable or unintended results. Addresses-Coverity-ID: 1471969 ("Uninitialized scalar variable") Fixes: 218d72a77b0b ("pinctrl: madera: Add driver for Cirrus Logic Madera codecs") Signed-off-by: Gusta

[PATCH] mtd: rawnand: fsmc: Fix unchecked return value in fsmc_read_page_hwecc

2018-10-10 Thread Gustavo A. R. Silva
the top of fsmc_read_page_hwecc(). Addresses-Coverity-ID: 1471968 ("Unchecked return value") Signed-off-by: Gustavo A. R. Silva --- drivers/mtd/nand/raw/fsmc_nand.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/mtd/nand/raw/fsmc_nand.c b/drivers/mt

Re: [PATCH] Input: atmel_mxt_ts - mark expected switch fall-through

2018-10-15 Thread Gustavo A. R. Silva
On 10/15/18 8:21 PM, Dmitry Torokhov wrote: > On Mon, Oct 08, 2018 at 07:03:55PM +0200, Gustavo A. R. Silva wrote: >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. >> >> Signed-off-by: Gustavo A. R. Sil

Re: [PATCH 1/2] dt-bindings: phy: Update SERDES_MAX to be SERDES_MAX + 1

2018-10-16 Thread Gustavo A. R. Silva
Hi, On 10/9/18 9:27 AM, Quentin Schulz wrote: > Hi Gustavo, > > On Tue, Oct 09, 2018 at 12:21:36AM +0200, Gustavo A. R. Silva wrote: >> SERDES_MAX is a valid value to index ctrl->phys in >> drivers/phy/mscc/phy-ocelot-serdes.c. But, currently, >> there is an out-

Re: [PATCH 2/2] phy: ocelot-serdes: fix out-of-bounds read

2018-10-16 Thread Gustavo A. R. Silva
Hi, On 10/9/18 9:28 AM, Quentin Schulz wrote: > Hi Gustavo, > > On Tue, Oct 09, 2018 at 12:22:33AM +0200, Gustavo A. R. Silva wrote: >> Currently, there is an out-of-bounds read on array ctrl->phys, >> once variable i reaches the maximum array size of SERDES_MAX >&

Re: [PATCH net-next v2 2/2] net: phy: mscc: fix memory leak in vsc8574_config_pre_init

2018-10-16 Thread Gustavo A. R. Silva
Hi, On 10/10/18 10:34 AM, Quentin Schulz wrote: > Hi Gustavo, > > On Wed, Oct 10, 2018 at 10:31:39AM +0200, Gustavo A. R. Silva wrote: >> In case memory resources for *fw* were successfully allocated, >> release them before return. >> >> Addresses-Coverity-ID: 1

Re: [PATCH net-next v2 1/2] net: phy: mscc: fix signedness bug in vsc85xx_downshift_get

2018-10-16 Thread Gustavo A. R. Silva
Hi, On 10/10/18 10:30 AM, Gustavo A. R. Silva wrote: > Currently, the error handling for the call to function > phy_read_paged() doesn't work because *reg_val* is of > type u16 (16 bits, unsigned), which makes it impossible > for it to hold a value less than 0. > > Fix th

[PATCH] drivers/misc/sgi-gru: fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
rc.info/?l=linux-kernel&m=152449131114778&w=2 Cc: sta...@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/misc/sgi-gru/grukdump.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/misc/sgi-gru/grukdump.c b/drivers/misc/sgi-gru/grukdump.c index 313da31..1540a77 10

Re: [PATCH] iio: dpot-dac: mark expected switch fall-through

2018-10-16 Thread Gustavo A. R. Silva
On 10/14/18 7:01 PM, Jonathan Cameron wrote: > > Done the first of the above... > Thank you, Jonathan. -- Gustavo

[PATCH] Input: uinput - fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
l=linux-kernel&m=152449131114778&w=2 Cc: sta...@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/input/misc/uinput.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/input/misc/uinput.c b/drivers/input/misc/uinput.c index 8ec483e..97b0809 100644 --- a/drivers/i

Re: [PATCH] signal: Mark expected switch fall-throughs

2018-10-16 Thread Gustavo A. R. Silva
On 10/15/18 11:29 PM, Kees Cook wrote: > On Sat, Oct 13, 2018 at 4:48 AM, Gustavo A. R. Silva > wrote: >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. >> >> Signed-off-by: Gustavo A. R. Silva >

[PATCH] IB/ucm: Fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
x-kernel&m=152449131114778&w=2 Cc: sta...@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/infiniband/core/ucm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/infiniband/core/ucm.c b/drivers/infiniband/core/ucm.c index faa9e61..73332b9 100644 --- a/drivers/infiniban

[PATCH] RDMA/ucma: Fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
x-kernel&m=152449131114778&w=2 Cc: sta...@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/infiniband/core/ucma.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/infiniband/core/ucma.c b/drivers/infiniband/core/ucma.c index 21863dd..01d68ed 100644 --- a/drivers/infi

Re: [PATCH net-next v2 2/2] net: phy: mscc: fix memory leak in vsc8574_config_pre_init

2018-10-16 Thread Gustavo A. R. Silva
On 10/16/18 6:54 PM, David Miller wrote: >> >> Friendly ping. Dave, can you take this? > > It needs to be posted properly to netdev, just like all networking > patches do. > mmh... I don't know how I missed it. :/ OK. I'll send the series to netdev. Thanks! -- Gustavo

Re: [PATCH] Input: uinput - fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
On 10/16/18 8:09 PM, Dmitry Torokhov wrote: > > /dev/uinput I've got it. This explains it all. :) > must be 0600, or accessible to equally privileged user, or you'll be opening > your system to much mischief. > Thanks, Dmitry. -- Gustavo

Re: [PATCH] Input: uinput - fix Spectre v1 vulnerability

2018-10-16 Thread Gustavo A. R. Silva
Hi Dmitry, On 10/16/18 7:21 PM, Dmitry Torokhov wrote: > Hi Gustavo, > > On Tue, Oct 16, 2018 at 01:13:13PM +0200, Gustavo A. R. Silva wrote: >> setup.code can be indirectly controlled by user-space, hence leading to >> a potential exploitation of the Spectre variant 1 vuln

[PATCH v2] scsi: mark expected switch fall-throughs

2018-10-16 Thread Gustavo A. R. Silva
ses-Coverity-ID: 114985 ("Missing break in switch") Addresses-Coverity-ID: 114988 ("Missing break in switch") Addresses-Coverity-ID: 114994 ("Missing break in switch") Addresses-Coverity-ID: 114995 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silv

Re: [PATCH 3/5] Drivers: hv: kvp: Fix the recent regression caused by incorrect clean-up

2018-10-16 Thread Gustavo A. R. Silva
On 10/17/18 7:07 AM, Greg KH wrote: > On Wed, Oct 17, 2018 at 03:14:04AM +, k...@linuxonhyperv.com wrote: >> From: Dexuan Cui >> >> In kvp_send_key(), we do need call process_ib_ipinfo() if >> message->kvp_hdr.operation is KVP_OP_GET_IP_INFO, because it turns out >> the userland hv_kvp_daem

Re: [PATCH] skbuff: Mark expected switch fall-throughs

2018-10-17 Thread Gustavo A. R. Silva
On 10/17/18 12:41 AM, Kees Cook wrote: > > Actually, since this is skbuff, can you resend this to netdev instead? > Andrew took the other two, but this one seems like it should go via > David Miller. > Sure thing. Will do. Thanks -- Gustavo

[PATCH] afs: Mark expected switch fall-throughs

2018-10-17 Thread Gustavo A. R. Silva
break in switch") Addresses-Coverity-ID: 1467807 ("Missing break in switch") Addresses-Coverity-ID: 1467811 ("Missing break in switch") Addresses-Coverity-ID: 115041 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- fs/afs/cmservice.c | 6 ++ f

Re: [PATCH 1/2] dt-bindings: phy: Update SERDES_MAX to be SERDES_MAX + 1

2018-10-17 Thread Gustavo A. R. Silva
On 10/17/18 5:09 PM, Rob Herring wrote: >> >> Friendly ping. Who can you take this? > > Applied. No need (nor benefit) to ping me. You can check the status of > DT patches on patchwork[1]. If it is there and in the "New" state, it is > in my queue. > OK. I've got it. I just didn't know who

Re: [PATCH 1/2] dt-bindings: phy: Update SERDES_MAX to be SERDES_MAX + 1

2018-10-17 Thread Gustavo A. R. Silva
On 10/17/18 5:23 PM, Rob Herring wrote: >>> Friendly ping. Who can you take this? >> >> Applied. No need (nor benefit) to ping me. You can check the status of >> DT patches on patchwork[1]. If it is there and in the "New" state, it is >> in my queue. > > Actually, this doesn't apply to my tr

Re: [PATCH 2/2] phy: ocelot-serdes: fix out-of-bounds read

2018-10-17 Thread Gustavo A. R. Silva
Hi Kishon, On 10/16/18 10:48 AM, Kishon Vijay Abraham I wrote: > Hi, > > On Tuesday 16 October 2018 02:16 PM, Gustavo A. R. Silva wrote: >> Hi, >> >> On 10/9/18 9:28 AM, Quentin Schulz wrote: >>> Hi Gustavo, >>> >>> On Tue, Oct 0

[PATCH] staging: comedi: tio: fix multiple missing break in switch bugs

2018-10-11 Thread Gustavo A. R. Silva
;Structurally dead code") Fixes: 347e244884c3 ("staging: comedi: tio: implement global tio/ctr routing") Signed-off-by: Gustavo A. R. Silva --- drivers/staging/comedi/drivers/ni_tio.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/staging/comedi/drivers/ni_tio.c b/d

[PATCH] pinctrl: rzn1: remove unnecessary unsigned integer comparison

2018-10-11 Thread Gustavo A. R. Silva
There is no need to compare ipctl->mdio_func[mdio] with => 0, because such comparison is always true. Notice that *mdio_func* is of type u32 (32 bits, unsigned). Fix this by removing such comparison. Addresses-Coverity-ID: 1474166 ("Unsigned compared against 0") Signed-off-

Re: [PATCH v2] pinctrl: madera: Fix uninitialized variable bug in madera_mux_set_mux

2018-10-12 Thread Gustavo A. R. Silva
On 10/11/18 10:40 AM, Linus Walleij wrote: >> Changes in v2: >> - Initialize variable ret to 0 instead of -1. Thanks to Charles Keepax >>for pointing this out. >> - Update subject and commit log. > > Patch applied with Charles' ACK. > Thanks, Linus. -- Gustavo

Re: [PATCH] staging: comedi: tio: fix multiple missing break in switch bugs

2018-10-12 Thread Gustavo A. R. Silva
On 10/12/18 11:04 AM, Ian Abbott wrote: > On 11/10/2018 20:05, Gustavo A. R. Silva wrote: >> Currently, there are multiple missing break statements in two switch code >> blocks. This makes the execution path to fall all the way down through >> to the default cases, whi

Re: [PATCH] pinctrl: rzn1: remove unnecessary unsigned integer comparison

2018-10-12 Thread Gustavo A. R. Silva
rzn1.c Linus Walleij (maintainer:PIN CONTROL SUBSYSTEM) linux-g...@vger.kernel.org (open list:PIN CONTROL SUBSYSTEM) linux-kernel@vger.kernel.org (open list) Thanks -- Gustavo > Yours, > Linus Walleij > > On Thu, Oct 11, 2018 at 10:40 PM Gustavo A. R. Silva > wrote: >> >

[PATCH] firewire: core-topology: mark expected switch fall-through

2018-10-12 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 741234 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/firewire/core-topology.c | 1 + 1 file changed, 1 insertion(+) di

[PATCH] signal: Mark expected switch fall-throughs

2018-10-13 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- include/linux/signal.h | 6 ++ 1 file changed, 6 insertions(+) diff --git a/include/linux/signal.h b/include/linux/signal.h index 200ed96

[PATCH] compat: Mark expected switch fall-throughs

2018-10-13 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- include/linux/compat.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/compat.h b/include/linux/compat.h index d30e4db

[PATCH] skbuff: Mark expected switch fall-throughs

2018-10-13 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- include/linux/skbuff.h | 6 ++ 1 file changed, 6 insertions(+) diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 119d092

Re: [PATCH] iio: dpot-dac: mark expected switch fall-through

2018-10-13 Thread Gustavo A. R. Silva
On 10/13/18 2:38 PM, Jonathan Cameron wrote: > On Mon, 8 Oct 2018 20:42:41 + > Peter Rosin wrote: > >> On 2018-10-08 19:35, Gustavo A. R. Silva wrote: >>> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >>> where we are expecting to fa

[PATCH] rtc: m41t80: fix fall-through annotation

2018-10-04 Thread Gustavo A. R. Silva
Replace "Fall" with a proper "Fall through" annotation. This fix is part of the ongoing efforts to enabling -Wimplicit-fallthrough Addresses-Coverity-ID: 1373875 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/rtc/rtc-m41t80.c | 2 +

[PATCH] regulator: axp20x: Mark expected switch fall-throughs

2018-10-04 Thread Gustavo A. R. Silva
e, which is what GCC is expecting to find. Addresses-Coverity-ID: 1436594 ("Missing break in switch") Addresses-Coverity-ID: 1364475 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/regulator/axp20x-regulator.c | 3 ++- 1 file changed, 2 insertions

[PATCH v2] rtc: m41t80: mark expected switch fall-through

2018-10-04 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Notice that in this particular case, I replaced "Fall" with a proper "Fall through" comment. Addresses-Coverity-ID: 1373875 ("Missing break in switch") Sign

Re: [PATCH] rtc: m41t80: fix fall-through annotation

2018-10-04 Thread Gustavo A. R. Silva
On 10/4/18 2:53 PM, Alexandre Belloni wrote: > Hi, > > On 04/10/2018 14:35:28+0200, Gustavo A. R. Silva wrote: >> Replace "Fall" with a proper "Fall through" annotation. >> >> This fix is part of the ongoing efforts to enabling >> -Wi

[PATCH] power: max8925: mark expected switch fall-through

2018-10-04 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 201510 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/power/supply/max8925_power.c | 1 + 1 file changed, 1 insertion(+) di

[PATCH] PCI / ACPI: Mark expected switch fall-through

2018-10-04 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1472052 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/pci/pci-acpi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/d

[PATCH] parport: parport_pc: Mark expected switch fall-through

2018-10-04 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 114730 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/parport/parport_pc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletio

[PATCH] nvmem: lpc18xx_eeprom: fix compile warning

2018-10-05 Thread Gustavo A. R. Silva
Fix the following warning by removing unused variable ret: drivers/nvmem/lpc18xx_eeprom.c: In function ‘lpc18xx_eeprom_remove’: drivers/nvmem/lpc18xx_eeprom.c:258:6: warning: unused variable ‘ret’ [-Wunused-variable] int ret; ^~~ Signed-off-by: Gustavo A. R. Silva --- drivers/nvmem

[PATCH] ntb: ntb_transport: Mark expected switch fall-throughs

2018-10-05 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1373888 ("Missing break in switch") Addresses-Coverity-ID: 1373889 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers

Re: [PATCH] nvmem: lpc18xx_eeprom: fix compile warning

2018-10-05 Thread Gustavo A. R. Silva
On 10/5/18 10:06 AM, Srinivas Kandagatla wrote: > > > On 05/10/18 08:03, Gustavo A. R. Silva wrote: >> Fix the following warning by removing unused variable ret: >> >> drivers/nvmem/lpc18xx_eeprom.c: In function ‘lpc18xx_eeprom_remove’: >> drivers/nvmem/lpc18x

[PATCH] UBI: mark expected switch fall-throughs

2018-10-05 Thread Gustavo A. R. Silva
in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/mtd/ubi/attach.c | 1 + drivers/mtd/ubi/build.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/drivers/mtd/ubi/attach.c b/drivers/mtd/ubi/attach.c index 93ceea4..e294d39 100644 --- a/drivers/mtd/ubi/attach.c +++ b/drive

[PATCH] mmc: tifm_sd: Mark expected switch fall-through

2018-10-05 Thread Gustavo A. R. Silva
is expecting to find. Addresses-Coverity-ID: 1373887 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/mmc/host/tifm_sd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/host/tifm_sd.c b/drivers/mmc/host/tifm_sd.c index a3d8380..b6644ce

[PATCH] mmc: meson-mx-sdio: mark expected switch fall-through

2018-10-05 Thread Gustavo A. R. Silva
D: 1373880 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/mmc/host/meson-mx-sdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/meson-mx-sdio.c b/drivers/mmc/host/meson-mx-sdio.c index 2cfec33..abe253c 100644 --- a/dr

[PATCH] memstick: tifm_ms: mark expected switch fall-through

2018-10-05 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1357317 ("Missing break in switch") Addresses-Coverity-ID: 1460342 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- d

Re: [PATCH] staging/rtlwifi: Fixing formatting warnings.

2018-10-05 Thread Gustavo A. R. Silva
On 10/5/18 10:58 PM, Scott Tracy wrote: > Signed-off-by: Scott Tracy > --- > drivers/staging/rtlwifi/core.c | 5 +++-- > drivers/staging/rtlwifi/efuse.c | 5 +++-- > 2 files changed, 6 insertions(+), 4 deletions(-) > > diff --git a/drivers/staging/rtlwifi/core.c b/drivers/staging/rtlwifi/cor

Re: [PATCH] mmc: meson-mx-sdio: mark expected switch fall-through

2018-10-05 Thread Gustavo A. R. Silva
Hi Martin, On 10/5/18 11:10 PM, Martin Blumenstingl wrote: > On Fri, Oct 5, 2018 at 12:15 PM Gustavo A. R. Silva > wrote: >> >> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >> where we are expecting to fall through. >> >> Notice that

Re: [PATCH] Staging: rts5208: rtsx_card: Fixed multiple coding style issues

2018-10-06 Thread Gustavo A. R. Silva
Hi, On 9/29/18 4:03 AM, Maxime Desroches wrote: > Fixed multiple coding style issues > What kind of style issues are you trying to fix? Please, always be specific about what you are trying to fix. This makes it easier for the maintainers to review your patch and give you feedback. Thanks -- Gu

Re: [PATCH] STAGING/EMXX_UDC: emxx_udc.c: Fixed all meaningful sparse errors: 1. Added static to udc_controller 2. Added mising __iomem modifier to handle p_regs 3. Added missing le16_to_cpu

2018-10-06 Thread Gustavo A. R. Silva
Hi, Please, separate the commit log from the subject. And mention exactly what are all those errors that sparse reported and that you are trying to fix. Notice that you didn't send this patch to all the relevant people. Use the get_maintainer.pl script for that. On 10/5/18 8:27 PM, Carmeli Tam

Re: [PATCH] staging: emxx_udc: remove unused code

2018-10-08 Thread Gustavo A. R. Silva
Hi, On 10/8/18 9:33 AM, Loic Tourlonias wrote: > Remove useless code inside if_0 endif > > Signed-off-by: Loic Tourlonias > --- > drivers/staging/emxx_udc/emxx_udc.h | 4 > 1 file changed, 4 deletions(-) > > diff --git a/drivers/staging/emxx_udc/emxx_udc.h > b/drivers/staging/emxx_udc/em

[PATCH] isdn/gigaset/isocdata: mark expected switch fall-through

2018-10-08 Thread Gustavo A. R. Silva
Notice that in this particular case, I replaced the "--v-- fall through --v--" comment with a proper "fall through", which is what GCC is expecting to find. This fix is part of the ongoing efforts to enabling -Wimplicit-fallthrough Signed-off-by: Gustavo A. R. Silva ---

[PATCH] Input: xen-kbdfront - mark expected switch fall-through

2018-10-08 Thread Gustavo A. R. Silva
("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/input/misc/xen-kbdfront.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/misc/xen-kbdfront.c b/drivers/input/misc/xen-kbdfront.c index 594f72e..24bc5c5 100644 --- a/dr

[PATCH] Input: cyapa - mark expected switch fall-throughs

2018-10-08 Thread Gustavo A. R. Silva
-Coverity-ID: 114758 ("Missing break in switch") Addresses-Coverity-ID: 114759 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/input/mouse/cyapa_gen3.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/input/mouse/cyapa_gen3.c

[PATCH] Input: atmel_mxt_ts - mark expected switch fall-through

2018-10-08 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- drivers/input/touchscreen/atmel_mxt_ts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/touchscreen

[PATCH] iio: cros_ec_accel_legacy: Mark expected switch fall-throughs

2018-10-08 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1397962 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/iio/accel/cros_ec_accel_legacy.c | 2 ++ 1 file changed, 2 insertion

[PATCH] iio: dpot-dac: mark expected switch fall-through

2018-10-08 Thread Gustavo A. R. Silva
2408 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/iio/dac/dpot-dac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/dac/dpot-dac.c b/drivers/iio/dac/dpot-dac.c index a791d0a..e353946 100644 --- a/drivers/iio/dac/dpot-dac.c ++

[PATCH] phy: ocelot-serdes: fix out-of-bounds read

2018-10-08 Thread Gustavo A. R. Silva
ad") Addresses-Coverity-ID: 1473959 ("Out-of-bounds read") Fixes: 51f6b410fc22 ("phy: add driver for Microsemi Ocelot SerDes muxing") Signed-off-by: Gustavo A. R. Silva --- drivers/phy/mscc/phy-ocelot-serdes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) d

Re: [PATCH v2] wireless: mark expected switch fall-throughs

2018-10-23 Thread Gustavo A. R. Silva
On 10/23/18 10:59 AM, Gustavo A. R. Silva wrote: > > On 10/23/18 9:01 AM, Johannes Berg wrote: >> On Tue, 2018-10-23 at 02:13 +0200, Gustavo A. R. Silva wrote: >>> In preparation to enabling -Wimplicit-fallthrough, mark switch cases >>> where we are expecting to

[PATCH] RDMA/hns: Use 64-bit arithmetic instead of 32-bit

2018-10-18 Thread Gustavo A. R. Silva
arithmetic: length = max_num_sg * page_size; Addresses-Coverity-ID: 1474517 ("Unintentional integer overflow") Signed-off-by: Gustavo A. R. Silva --- drivers/infiniband/hw/hns/hns_roce_mr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/infiniband/hw/hns/hns_ro

Re: [PATCH] RDMA/ucma: Fix Spectre v1 vulnerability

2018-10-18 Thread Gustavo A. R. Silva
On 10/16/18 6:49 PM, Doug Ledford wrote: >> >> Cc: sta...@vger.kernel.org >> Signed-off-by: Gustavo A. R. Silva > > Thanks, applied to for-rc. > Thanks, Doug. -- Gustavo

[PATCH v2 1/2] dt-bindings: phy: Update SERDES_MAX to be SERDES_MAX + 1

2018-10-18 Thread Gustavo A. R. Silva
MAX to be SERDES6G_MAX + 1. Notice that this is the first part of the solution to the out-of-bounds bug mentioned above. Although this change is not dependent on any other one. Suggested-by: Quentin Schulz Reviewed-by: Quentin Schulz Acked-by: Rob Herring Signed-off-by: Gustavo A. R. Silva --- Chan

[PATCH v2 0/2] phy: ocelot-serdes: fix out-of-bounds read

2018-10-18 Thread Gustavo A. R. Silva
to commit log in both patches. Thanks! Gustavo A. R. Silva (2): dt-bindings: phy: Update SERDES_MAX to be SERDES_MAX + 1 phy: ocelot-serdes: fix out-of-bounds read drivers/phy/mscc/phy-ocelot-serdes.c| 4 ++-- include/dt-bindings/phy/phy-ocelot-serdes.h | 2 +- 2 files changed, 3 inse

[PATCH v2 2/2] phy: ocelot-serdes: fix out-of-bounds read

2018-10-18 Thread Gustavo A. R. Silva
ad") Addresses-Coverity-ID: 1473959 ("Out-of-bounds read") Fixes: 51f6b410fc22 ("phy: add driver for Microsemi Ocelot SerDes muxing") Reviewed-by: Quentin Schulz Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Rebase and add Quentin's Reviewed-by to commit log

[PATCH] scsi: hisi_sas: Fix NULL pointer dereference

2018-10-18 Thread Gustavo A. R. Silva
timeout for SMP/internal IO") Signed-off-by: Gustavo A. R. Silva --- drivers/scsi/hisi_sas/hisi_sas_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c b/drivers/scsi/hisi_sas/hisi_sas_main.c index 2e5eaf1..e3f7c7b 100644 --- a/driv

[PATCH 1/2] rtl8xxxu: Mark expected switch fall-throughs

2018-10-22 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1357355 ("Missing break in switch") Addresses-Coverity-ID: 1357378 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/

[PATCH 2/2] rtl8xxxu: Fix missing break in switch

2018-10-22 Thread Gustavo A. R. Silva
Add missing break statement in order to prevent the code from falling through to the default case. Fixes: 26f1fad29ad9 ("New driver: rtl8xxxu (mac80211)") Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 1 + 1 file changed, 1 insertio

Re: [PATCH] RDMA/hns: Use 64-bit arithmetic instead of 32-bit

2018-10-22 Thread Gustavo A. R. Silva
On 10/22/18 8:15 PM, Jason Gunthorpe wrote: > On Thu, Oct 18, 2018 at 10:02:58AM +0200, Gustavo A. R. Silva wrote: >> Cast *max_num_sg* to u64 in order to give the compiler complete >> information about the proper arithmetic to use. >> >> Notice that such variabl

[PATCH 05/20] carl9170: rx: mark expected switch fall-through

2018-10-22 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1056534 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/ath/carl9170/rx.c | 1 + 1 file changed, 1 insertion(+)

[PATCH 19/20] rtlwifi: rtl8821ae: phy: Mark expected switch fall-through

2018-10-22 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/realtek/rtlwifi/rtl8821ae/phy.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wireless/realtek/rtlwifi

[PATCH 20/20] zd1201: mark expected switch fall-through

2018-10-22 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/zydas/zd1201.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wireless/zydas/zd1201.c b/drivers/net/wireless

[PATCH] iio: adc: Fix potential integer overflow

2018-09-18 Thread Gustavo A. R. Silva
("Unintentional integer overflow") Fixes: e13d757279bb ("iio: adc: Add QCOM SPMI PMIC5 ADC driver") Signed-off-by: Gustavo A. R. Silva --- drivers/iio/adc/qcom-vadc-common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/qcom-vadc-common.c b/drive

[PATCH] mtd: rawnand: atmel: Fix potential NULL pointer dereference

2018-09-18 Thread Gustavo A. R. Silva
fc_np* before calling of_clk_get(). Addresses-Coverity-ID: 1473052 ("Dereference null return value") Signed-off-by: Gustavo A. R. Silva --- drivers/mtd/nand/raw/atmel/nand-controller.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/mtd/nand/raw/atmel/nand-controller.c

Re: [PATCH] mtd: rawnand: atmel: Fix potential NULL pointer dereference

2018-09-18 Thread Gustavo A. R. Silva
Hi Boris, On 9/18/18 8:40 AM, Boris Brezillon wrote: > Hi Gustavo, > > On Tue, 18 Sep 2018 08:33:17 -0500 > "Gustavo A. R. Silva" wrote: > >> There is a potential execution path in which function >> of_find_compatible_node() returns NULL. In such a cas

[PATCH v2] mtd: rawnand: atmel: Fix potential NULL pointer dereference

2018-09-18 Thread Gustavo A. R. Silva
fc_np* before calling of_clk_get(). Addresses-Coverity-ID: 1473052 ("Dereference null return value") Fixes: f88fc122cc34 ("mtd: nand: Cleanup/rework the atmel_nand driver") Signed-off-by: Gustavo A. R. Silva --- Changes in v2: - Add Fixes tag to the commit log. - Remove blank

[PATCH] drm/i915/selftests: Remove redundant code

2018-07-16 Thread Gustavo A. R. Silva
err is assigned to -EIO, but this value is never actually used and *err* is updated later on. Remove such reduntant code. Addresses-Coverity-ID: 1471816 ("Unused value") Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/i915/selftests/intel_guc.c | 1 - 1 file changed, 1 deletio

Re: [PATCH] fsinfo: Fix off-by-one bug

2018-07-16 Thread Gustavo A. R. Silva
Hi, Please, drop this patch. Sorry, I confused fsinfo_attr_statfs with fsinfo_attr__nr. Thanks -- Gustavo On 07/16/2018 05:03 PM, Gustavo A. R. Silva wrote: > The current code reads one element beyond the end of the > fsinfo_buffer_sizes array. > > Fixes: 4e635f61dd55 ("fsi

[PATCH] fsinfo: Fix off-by-one bug

2018-07-16 Thread Gustavo A. R. Silva
The current code reads one element beyond the end of the fsinfo_buffer_sizes array. Fixes: 4e635f61dd55 ("fsinfo: Add a system call to allow querying of filesystem information") Signed-off-by: Gustavo A. R. Silva --- fs/statfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH] rtnetlink: fix uninitialized variable

2018-07-17 Thread Gustavo A. R. Silva
support simultaneous driver and hw XDP attachment") Signed-off-by: Gustavo A. R. Silva --- net/core/rtnetlink.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c index e03258e..648c984 100644 --- a/net/core/rtnetlink.c +++ b/net/core/rt

[PATCH] ALSA: emu10k1_patch: Use swap macro in snd_emu10k1_sample_new

2018-07-17 Thread Gustavo A. R. Silva
Make use of the swap macro and remove unnecessary variable *tmp*. This makes the code easier to read and maintain. This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- sound/pci/emu10k1/emu10k1_patch.c | 7 ++- 1 file changed, 2 insertions(+), 5

[PATCH] ALSA: emu8000: Use swap macro in snd_emu8000_sample_new

2018-07-17 Thread Gustavo A. R. Silva
Make use of the swap macro and remove unnecessary variable *tmp*. This makes the code easier to read and maintain. This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- sound/isa/sb/emu8000_patch.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions

Re: [PATCH] ALSA: emu8000: Use swap macro in snd_emu8000_sample_new

2018-07-17 Thread Gustavo A. R. Silva
On 07/17/2018 10:19 AM, Takashi Iwai wrote: > On Tue, 17 Jul 2018 17:06:10 +0200, > Gustavo A. R. Silva wrote: >> >> Make use of the swap macro and remove unnecessary variable *tmp*. This >> makes the code easier to read and maintain. >> >> This code was

[PATCH] xfs: use swap macro in xfs_dir2_leafn_rebalance

2018-07-17 Thread Gustavo A. R. Silva
Make use of the swap macro and remove unnecessary variable *tmp*. This makes the code easier to read and maintain. Also, slightly refactor some code. This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- fs/xfs/libxfs/xfs_dir2_node.c | 17

[PATCH] UBIFS: use swap macro in swap_dirty_idx

2018-07-17 Thread Gustavo A. R. Silva
Make use of the swap macro and remove unnecessary variable *t*. This makes the code easier to read and maintain. This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- fs/ubifs/find.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/fs

[PATCH] vfio/pci: Fix potential Spectre v1

2018-07-17 Thread Gustavo A. R. Silva
l=linux-kernel&m=152449131114778&w=2 Cc: sta...@vger.kernel.org Signed-off-by: Gustavo A. R. Silva --- drivers/vfio/pci/vfio_pci.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c index b423a30..125b58e 100644 --- a/drivers/vfio/pci/

[PATCH] power: supply: mark expected switch fall-throughs

2018-07-17 Thread Gustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1394724 ("Missing break in switch") Addresses-Coverity-ID: 114958 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silva ---

[PATCH] power: supply: max77693_charger: fix unintentional fall-through

2018-07-17 Thread Gustavo A. R. Silva
It seems that a *break* is missing in order to avoid a fall-through. Otherwise, the calculation of *data* makes no sense. Addresses-Coverity-ID: 1271172 ("Missing break in switch") Fixes: 87c2d9067893 ("power: max77693: Add charger driver for Maxim 77693") Signed-off-by:

Re: [PATCH RESEND][next] ipv4: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:02, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix multiple > warnings by explicitly adding multiple break statements instead of just > letting the code fall t

Re: [PATCH RESEND][next] xfrm: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:23, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning > by explicitly adding a break statement instead of letting the code fall > through to the

Re: [PATCH RESEND][next] tipc: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:25, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning > by explicitly adding a break statement instead of letting the code fall > through to the

Re: [PATCH RESEND][next] sctp: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:07, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a couple > of warnings by explicitly adding a break statement and replacing a > comment with a goto statemen

Re: [PATCH RESEND][next] rxrpc: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:19, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning > by explicitly adding a break statement instead of letting the code fall > through to the

Re: [PATCH RESEND][next] net/packet: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:44, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning > by explicitly adding a break statement instead of letting the code fall > through to the

Re: [PATCH RESEND][next] net: netrom: Fix fall-through warnings for Clang

2021-04-20 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this, please? Thanks -- Gustavo On 3/5/21 03:22, Gustavo A. R. Silva wrote: > In preparation to enable -Wimplicit-fallthrough for Clang, fix multiple > warnings by explicitly adding multiple break statements instead of > letting the code fall throu

<    3   4   5   6   7   8   9   10   11   12   >