[PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-04-19 Thread Gaston Gonzalez
Silence the following sparse warning: drivers/staging/rtl8192u/ieee80211/ieee80211_crypt_tkip.c:184:16: warning: cast to restricted __le16 Signed-off-by: Gaston Gonzalez --- .../rtl8192u/ieee80211/ieee80211_crypt_tkip.c | 22 +++--- 1 file changed, 11 insertions(+), 11

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-04-25 Thread Gaston Gonzalez
On 20/04/15 05:24, Dan Carpenter wrote: > Mk16_le() is a bad function name and as we can see from tkip.c it just > duplicates get_unaligned_le16(). Better to make TK void pointer instead > of a u8 pointer (because it doesn't point to u8s so we have to cast it > every time we use it). This is anot

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-05-06 Thread Gaston Gonzalez
On 27/04/15 07:12, Dan Carpenter wrote: > Can't we just export the tkip.c function? > > regards, > dan carpenter > Hi Dan, (sorry for the delayed response) The inputs of the two implementations of tkip_mixing_phase2() differ in one parameter: - ieee80211_crypt_tkip.c expects 'const u16 *TTAK'

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-05-12 Thread Gaston Gonzalez
On 08/05/15 08:03, Dan Carpenter wrote: > To be honest, I'm a little bit a newbie myself when it comes to > linux-wireless so keep that in mind. ;) Changing the parameters seems > simple enough. But it needs to an EXPORT_SYMBOL() and to be declared in > a header file and I'm not sure what else.

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-05-13 Thread Gaston Gonzalez
On 13/05/15 05:36, Dan Carpenter wrote: > How come you didn't use my patch as a base to work from, you shouldn't > be passing tkip_ctx at all. Hi Dan, my mistake. To be honest I assumed that the idea was not to touch tkip.c at all, that's why I had to pass tkip_ctx... sorry about that :-( Coming b

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-05-14 Thread Gaston Gonzalez
On 14/05/15 16:35, Johannes Berg wrote: > On Wed, 2015-05-13 at 22:04 -0300, Gaston Gonzalez wrote: > >> .../rtl8192u/ieee80211/ieee80211_crypt_tkip.c | 53 >> ++ >> include/net/mac80211.h | 3 ++

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse warning

2015-05-15 Thread Gaston Gonzalez
On 15/05/15 04:26, Johannes Berg wrote: > On Thu, 2015-05-14 at 19:03 -0300, Gaston Gonzalez wrote: > >> If Dan is a newbie to this, I would be a pre-under-newbie or something >> below that. That being said, understood your explication, I'll look for >> another way t

[PATCH] staging: rtl8192u: ieee80211: Silence sparse endianness warning

2015-05-25 Thread Gaston Gonzalez
/rtl8192u/ieee80211/ieee80211_softmac.c:663:32:got int Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c b/drivers/staging/rtl8192u

Re: [PATCH] staging: rtl8192u: ieee80211: Silence sparse endianness warning

2015-05-25 Thread Gaston Gonzalez
On 25/05/15 13:35, Dan Carpenter wrote: > This is also wrong then. > > regards, > dan carpenter Hi Dan, Yes, you are right. It is the next sparse warning in line for that file. Including the fix for that, the patch would be as showed below. There are similar endianness warnings for other variable

[PATCH] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-26 Thread Gaston Gonzalez
/ieee80211_softmac.c:664:50:right side has type int Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c b/drivers/staging/rtl8192u

[PATCH RESEND] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-31 Thread Gaston Gonzalez
/ieee80211_softmac.c:664:50:right side has type int Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c b/drivers/staging/rtl8192u

Re: [PATCH] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-31 Thread Gaston Gonzalez
On Sun, May 31, 2015 at 10:45:27AM +0900, Greg KH wrote: > On Tue, May 26, 2015 at 06:47:14PM -0300, Gaston Gonzalez wrote: > > Fix the following sparse warnings: > > > > drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:663:32: warning: > > incorrect type in

Re: [PATCH RESEND] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-31 Thread Gaston Gonzalez
On Mon, Jun 01, 2015 at 07:17:39AM +0900, Greg KH wrote: > On Sun, May 31, 2015 at 12:17:48PM -0300, Gaston Gonzalez wrote: > > Fix the following sparse warnings: > > > > drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:663:32: warning: > > incorrect type in

Re: [PATCH RESEND] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-31 Thread Gaston Gonzalez
On Mon, Jun 01, 2015 at 08:24:17AM +0900, Greg KH wrote: > On Sun, May 31, 2015 at 08:07:21PM -0300, Gaston Gonzalez wrote: > > On Mon, Jun 01, 2015 at 07:17:39AM +0900, Greg KH wrote: > > > On Sun, May 31, 2015 at 12:17:48PM -0300, Gaston Gonzalez wrote: > > > > Fix

Re: [PATCH RESEND] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-05-31 Thread Gaston Gonzalez
On Mon, Jun 01, 2015 at 10:53:20AM +0900, Greg KH wrote: > On Sun, May 31, 2015 at 10:41:52PM -0300, Gaston Gonzalez wrote: > > On Mon, Jun 01, 2015 at 08:24:17AM +0900, Greg KH wrote: > > > On Sun, May 31, 2015 at 08:07:21PM -0300, Gaston Gonzalez wrote: > > > > On M

Re: [PATCH RESEND] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-01 Thread Gaston Gonzalez
On Mon, Jun 01, 2015 at 01:03:16PM +0900, Greg KH wrote: > On Sun, May 31, 2015 at 11:24:42PM -0300, Gaston Gonzalez wrote: > > On Mon, Jun 01, 2015 at 10:53:20AM +0900, Greg KH wrote: > > > On Sun, May 31, 2015 at 10:41:52PM -0300, Gaston Gonzalez wrote: > > > > On M

[PATCH RESEND 2] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-01 Thread Gaston Gonzalez
/ieee80211_softmac.c:664:50:right side has type int Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c b/drivers/staging/rtl8192u

Re: [PATCH RESEND 2] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-01 Thread Gaston Gonzalez
On Mon, Jun 01, 2015 at 02:43:28PM -0700, Joe Perches wrote: > On Mon, 2015-06-01 at 18:30 -0300, Gaston Gonzalez wrote: > > Fix the following sparse warnings: > [] > > diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c > > b/drivers/staging/rtl8192u/ieee8

[PATCH v2] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-01 Thread Gaston Gonzalez
/ieee80211_softmac.c:664:50:right side has type int Signed-off-by: Gaston Gonzalez --- Changes since V1: rearrange the code to set auth->header.frame_ctl only once. drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/driv

Re: [PATCH v2] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-02 Thread Gaston Gonzalez
On Tue, Jun 02, 2015 at 11:09:41AM +0530, Sudip Mukherjee wrote: > On Mon, Jun 01, 2015 at 09:43:31PM -0300, Gaston Gonzalez wrote: > > Fix the following sparse warnings: > > > > drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 6 -- > > 1 file changed, 4

[PATCH v3] staging: rtl8192u: ieee80211: Fix sparse endianness warnings

2015-06-02 Thread Gaston Gonzalez
/ieee80211_softmac.c:664:50:right side has type int Signed-off-by: Gaston Gonzalez --- Changes since V2: fix line over 80 chararcters. drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/staging/rtl8192u/ieee80211

[PATCH] staging: rtl8192u: ieee80211: Fix sparse endianness warnings ieee80211_softmac.c

2015-06-10 Thread Gaston Gonzalez
/ieee80211_softmac.c:3130:24:expected restricted __le16 [usertype] reason drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:3130:24:got unsigned char [unsigned] [usertype] asRsn Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 10 +- 1

[PATCH] staging: rtl8192u: ieee80211: Fix incorrect type in assignment

2015-06-14 Thread Gaston Gonzalez
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c:2157:30:right side has type restricted __le16 Signed-off-by: Gaston Gonzalez --- I wonder if this is the best approach, making payload_size u16 in ieee80211.h would fix this plus other three sparse warnings. Could we make payload_size u16

[PATCH] staging: rtl8192u: ieee80211_rx: Fix incorrect type in assignments

2015-06-21 Thread Gaston Gonzalez
restricted __le16 drivers/staging/rtl8192u/ieee80211/ieee80211_rx.c:1501:45:got unsigned short [unsigned] [usertype] Signed-off-by: Gaston Gonzalez --- drivers/staging/rtl8192u/ieee80211/ieee80211_rx.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/staging

Re: [PATCH] staging: rtl8192u: ieee80211_rx: Fix incorrect type in assignments

2015-06-24 Thread Gaston Gonzalez
On Tue, Jun 23, 2015 at 12:13:47PM +0200, Arnd Bergmann wrote: > On Sunday 21 June 2015 19:12:09 Gaston Gonzalez wrote: > > /* WMM spec P.11: The minimum value for AIFSN shall be 2 */ > > qos_param->aifs[aci] = (qos_param->aifs[aci] < 2) ? &

Re: [PATCH] staging: rtl8192u: ieee80211_rx: Fix incorrect type in assignments

2015-06-26 Thread Gaston Gonzalez
On Thu, Jun 25, 2015 at 02:06:44PM +0200, Arnd Bergmann wrote: > On Wednesday 24 June 2015 13:34:58 Gaston Gonzalez wrote: > > On Tue, Jun 23, 2015 at 12:13:47PM +0200, Arnd Bergmann wrote: > > > On Sunday 21 June 2015 19:12:09 Gaston Gonzalez wrote: > > > >

[PATCH] drivers: staging: imx-drm Fix checkpatch warning

2014-10-15 Thread Gaston Gonzalez
Fix line over 80 characters in imx-tve.c Signed-off-by: Gaston Gonzalez --- drivers/staging/imx-drm/imx-tve.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/imx-drm/imx-tve.c b/drivers/staging/imx-drm/imx-tve.c index 3e8b0a1..a46905f 100644 --- a

Re: [PATCH] staging: rtl8192u: ieee80211_rx: Fix incorrect type in assignments

2015-09-23 Thread Gaston Gonzalez
On Fri, Jun 26, 2015 at 01:36:14PM -0300, Gaston Gonzalez wrote: > On Thu, Jun 25, 2015 at 02:06:44PM +0200, Arnd Bergmann wrote: > > On Wednesday 24 June 2015 13:34:58 Gaston Gonzalez wrote: > > > On Tue, Jun 23, 2015 at 12:13:47PM +0200, Arnd Bergmann wrote: > > > >