Search Linux Wireless

Re: [PATCH] iwlwifi: Return correct failure code on error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2012-02-08 at 16:05 -0500, Simon Graham wrote:
> Callers of rtl_pci_init expect zero to be returned on error. Returning
> the error code leads to, amongst other things, divide by zero panics
> attempting to use the ring size that was never set.

You probably want to resent with the subject:

[PATCH] rtlwifi: return correct failure code on error

instead of 'iwlwifi' which is the Intel wifi driver.

Dan

> ---
>  drivers/net/wireless/rtlwifi/pci.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/net/wireless/rtlwifi/pci.c b/drivers/net/wireless/rtlwifi/pci.c
> index fb84707..f0ce366 100644
> --- a/drivers/net/wireless/rtlwifi/pci.c
> +++ b/drivers/net/wireless/rtlwifi/pci.c
> @@ -1492,7 +1492,7 @@ static int rtl_pci_init(struct ieee80211_hw *hw, struct pci_dev *pdev)
>  	if (err) {
>  		RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
>  			 "tx ring initialization failed\n");
> -		return err;
> +		return 0;
>  	}
>  
>  	return 1;


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


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux