From: Felix Fietkau Date: Sat, 14 Dec 2013 17:03:35 +0000 (+0100) Subject: ath9k_common: get rid of an unnecessary variable X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f40c46082717cea32ba1852c8217cbb9693fe80f;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git ath9k_common: get rid of an unnecessary variable There's no need to truncate curchan->hw_value to u8 Signed-off-by: Felix Fietkau Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/ath/ath9k/common.c b/drivers/net/wireless/ath/ath9k/common.c index a7e5a05b2eff..768c733cad31 100644 --- a/drivers/net/wireless/ath/ath9k/common.c +++ b/drivers/net/wireless/ath/ath9k/common.c @@ -98,10 +98,8 @@ struct ath9k_channel *ath9k_cmn_get_channel(struct ieee80211_hw *hw, { struct ieee80211_channel *curchan = chandef->chan; struct ath9k_channel *channel; - u8 chan_idx; - chan_idx = curchan->hw_value; - channel = &ah->channels[chan_idx]; + channel = &ah->channels[curchan->hw_value]; ath9k_cmn_update_ichannel(channel, chandef); return channel;