Search Linux Wireless

Re: [PATCH 1/2] ath5k: fix error handling in ath5k_hw_dma_stop

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

 



2011/1/25 Bob Copeland <me@xxxxxxxxxxxxxxx>:
> Review spotted a problem with the error handling in ath5k_hw_dma_stop:
> a successful return from ath5k_hw_stop_tx_dma will be treated as
> an error, so we always bail out of the loop after processing a single
> active queue. ÂAs a result, we may not actually stop some queues during
> reset.
>
> Signed-off-by: Bob Copeland <me@xxxxxxxxxxxxxxx>
> ---
> These two patches fix some buglets I found when reviewing some old code.
>
> Âdrivers/net/wireless/ath/ath5k/dma.c | Â Â2 +-
> Â1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath5k/dma.c b/drivers/net/wireless/ath/ath5k/dma.c
> index 0064be7..e828b98 100644
> --- a/drivers/net/wireless/ath/ath5k/dma.c
> +++ b/drivers/net/wireless/ath/ath5k/dma.c
> @@ -838,7 +838,7 @@ int ath5k_hw_dma_stop(struct ath5k_hw *ah)
> Â Â Â Âfor (i = 0; i < qmax; i++) {
> Â Â Â Â Â Â Â Âerr = ath5k_hw_stop_tx_dma(ah, i);
> Â Â Â Â Â Â Â Â/* -EINVAL -> queue inactive */
> - Â Â Â Â Â Â Â if (err != -EINVAL)
> + Â Â Â Â Â Â Â if (err && err != -EINVAL)
> Â Â Â Â Â Â Â Â Â Â Â Âreturn err;
> Â Â Â Â}
>
> --
> 1.7.1.1

Acked-by: Nick Kossifidis <mickflemm@xxxxxxxxx>



-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick
--
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