lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <5614EABC.9040404@broadcom.com>
Date:	Wed, 7 Oct 2015 11:49:48 +0200
From:	Arend van Spriel <arend@...adcom.com>
To:	Nicholas Krause <xerofoify@...il.com>, <brudley@...adcom.com>
CC:	<frankyl@...adcom.com>, <meuleman@...adcom.com>,
	<kvalo@...eaurora.org>, <pieterpg@...adcom.com>,
	<linux-wireless@...r.kernel.org>,
	<brcm80211-dev-list@...adcom.com>, <netdev@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] brcm80211:Fix error handling in the function brcmf_sdio_htclk

Hi Nick,

On 10/06/2015 04:36 AM, Nicholas Krause wrote:
> This fixes error handling in the function brcmf_sdio_htclk to
> properly check if the call to the function brcmf_sdio_regrb
> fails in the else if condition where the clkstate is in the
> CLK_PENDING state in order to avoid incorrect execution of
> the function brcmf_sdio_htclk when the call to brcmf_sdio_htclk
> fails by returning a error code here.

This commit message seems a bit overstating the change or I am missing 
what you mean by incorrect execution here. These functions are pretty 
low-level and failures are likely SDIO bus errors that are likely 
persistent. For that reason not every individual call is checked for 
errors as net result is that device will become inoperable.

Regards,
Arend

> Signed-off-by: Nicholas Krause <xerofoify@...il.com>
> ---
>   drivers/net/wireless/brcm80211/brcmfmac/sdio.c | 5 +++++
>   1 file changed, 5 insertions(+)
>
> diff --git a/drivers/net/wireless/brcm80211/brcmfmac/sdio.c b/drivers/net/wireless/brcm80211/brcmfmac/sdio.c
> index f990e3d..030b50a 100644
> --- a/drivers/net/wireless/brcm80211/brcmfmac/sdio.c
> +++ b/drivers/net/wireless/brcm80211/brcmfmac/sdio.c
> @@ -886,6 +886,11 @@ static int brcmf_sdio_htclk(struct brcmf_sdio *bus, bool on, bool pendok)
>   			/* Cancel CA-only interrupt filter */
>   			devctl = brcmf_sdiod_regrb(bus->sdiodev,
>   						   SBSDIO_DEVICE_CTL, &err);
> +			if (err) {
> +				brcmf_err("Devctl error canceling CA: %d\n",
> +					  err);
> +				return -EBADE;
> +			}
>   			devctl &= ~SBSDIO_DEVCTL_CA_INT_ONLY;
>   			brcmf_sdiod_regwb(bus->sdiodev, SBSDIO_DEVICE_CTL,
>   					  devctl, &err);
>

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ