diff mbox

[v2] drivers: staging: rtl8723au: fix "warning: cast to restricted __le16"

Message ID 20150402133730.GA28331@pwitoslawski.warsaw.osa (mailing list archive)
State Not Applicable
Delegated to: Kalle Valo
Headers show

Commit Message

Piotr Witoslawski April 2, 2015, 1:37 p.m. UTC
This patch fixes the sparse warning: "cast to restricted __le16" reported
for rtl8723au/hal/rtl8723au_xmit.c

Signed-off-by: Piotr Witoslawski <pwitos@gmail.com>
---
v2: Changing pointer type instead of casting, as suggested by Jes Sorensen <jes.sorensen@redhat.com>

 drivers/staging/rtl8723au/hal/rtl8723au_xmit.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c b/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
index 1759487..967e7de 100644
--- a/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
+++ b/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
@@ -42,7 +42,7 @@  static int urb_zero_packet_chk(struct rtw_adapter *padapter, int sz)
 
 static void rtl8192cu_cal_txdesc_chksum(struct tx_desc	*ptxdesc)
 {
-		u16	*usPtr = (u16 *)ptxdesc;
+		__le16	*usPtr = (__le16 *)ptxdesc;
 		u32 count = 16;		/*  (32 bytes / 2 bytes per XOR) => 16 times */
 		u32 index;
 		u16 checksum = 0;