LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Piotr Witoslawski <pwitos@gmail.com>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Jes Sorensen <Jes.Sorensen@redhat.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Yannis Damigos <giannis.damigos@gmail.com>,
	linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH] drivers: staging: rtl8723au: fix "warning: cast to restricted __le16"
Date: Thu, 2 Apr 2015 11:37:48 +0200	[thread overview]
Message-ID: <20150402093748.GA24455@pwitoslawski.warsaw.osa> (raw)

Signed-off-by: Piotr Witoslawski <pwitos@gmail.com>
---
 drivers/staging/rtl8723au/hal/rtl8723au_xmit.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c b/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
index 1759487..256958e 100644
--- a/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
+++ b/drivers/staging/rtl8723au/hal/rtl8723au_xmit.c
@@ -51,7 +51,8 @@ static void rtl8192cu_cal_txdesc_chksum(struct tx_desc	*ptxdesc)
 		ptxdesc->txdw7 &= cpu_to_le32(0xffff0000);
 
 		for (index = 0 ; index < count ; index++)
-			checksum = checksum ^ le16_to_cpu(*(usPtr + index));
+			checksum = checksum ^ le16_to_cpu(
+				*(__le16 *)(usPtr + index));
 
 		ptxdesc->txdw7 |= cpu_to_le32(0x0000ffff&checksum);
 }
-- 
2.0.5


             reply	other threads:[~2015-04-02  9:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-02  9:37 Piotr Witoslawski [this message]
2015-04-02 10:07 ` Dan Carpenter
2015-04-02 10:17   ` Jes Sorensen
2015-04-02 13:37 ` [PATCH v2] " Piotr Witoslawski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150402093748.GA24455@pwitoslawski.warsaw.osa \
    --to=pwitos@gmail.com \
    --cc=Jes.Sorensen@redhat.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=devel@driverdev.osuosl.org \
    --cc=giannis.damigos@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --subject='Re: [PATCH] drivers: staging: rtl8723au: fix "warning: cast to restricted __le16"' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).