Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: rtl8192u: ieee80211: Fix incorrect type in assignment

Added le16_to_cpu() conversion fixing the following warning in assignment detected by sparse:

drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:2157:30: warning: invalid assignment: +=
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:2157:30: left side has type unsigned long
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:2157:30: right side has type restricted __le16

Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Gaston Gonzalez and committed by
Greg Kroah-Hartman
80cf407f da2a7272

+1 -1
+1 -1
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
··· 2154 2154 ieee80211_sta_wakeup(ieee, 0); 2155 2155 2156 2156 /* update the tx status */ 2157 - ieee->stats.tx_bytes += txb->payload_size; 2157 + ieee->stats.tx_bytes += le16_to_cpu(txb->payload_size); 2158 2158 ieee->stats.tx_packets++; 2159 2159 tcb_desc = (cb_desc *)(txb->fragments[0]->cb + MAX_DEV_ADDR_SIZE); 2160 2160 if (tcb_desc->bMulticast) {