* [PATCH] ieee80211: Fix sparse warning
@ 2007-02-01 0:50 Larry Finger
2007-02-02 20:32 ` John W. Linville
0 siblings, 1 reply; 3+ messages in thread
From: Larry Finger @ 2007-02-01 0:50 UTC (permalink / raw)
To: John Linville
Cc: netdev-u79uwXL29TY76Z2rM5mHXA, Bcm43xx-dev-0fE9KPoRgkgATYTw5x5z8w,
Michael Buesch
Sparse issues the warning "warning: symbol 'crypt' shadows an earlier one"
in net/ieee80211/ieee80211_tx.c.
Signed-off-by: Larry Finger <Larry.Finger-tQ5ms3gMjBLk1uMJSBkQmQ@public.gmane.org>
---
Index: wireless-2.6/net/ieee80211/ieee80211_tx.c
===================================================================
--- wireless-2.6.orig/net/ieee80211/ieee80211_tx.c
+++ wireless-2.6/net/ieee80211/ieee80211_tx.c
@@ -502,8 +502,6 @@ int ieee80211_xmit(struct sk_buff *skb,
if (host_encrypt)
ieee80211_encrypt_fragment(ieee, skb_frag, hdr_len);
else if (host_build_iv) {
- struct ieee80211_crypt_data *crypt;
-
crypt = ieee->crypt[ieee->tx_keyidx];
atomic_inc(&crypt->refcnt);
if (crypt->ops->build_iv)
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] ieee80211: Fix sparse warning
2007-02-01 0:50 [PATCH] ieee80211: Fix sparse warning Larry Finger
@ 2007-02-02 20:32 ` John W. Linville
2007-02-02 21:38 ` Larry Finger
0 siblings, 1 reply; 3+ messages in thread
From: John W. Linville @ 2007-02-02 20:32 UTC (permalink / raw)
To: Larry Finger; +Cc: Michael Buesch, netdev, Bcm43xx-dev
On Wed, Jan 31, 2007 at 06:50:19PM -0600, Larry Finger wrote:
> Sparse issues the warning "warning: symbol 'crypt' shadows an earlier one"
> in net/ieee80211/ieee80211_tx.c.
>
> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
> ---
>
> Index: wireless-2.6/net/ieee80211/ieee80211_tx.c
> ===================================================================
> --- wireless-2.6.orig/net/ieee80211/ieee80211_tx.c
> +++ wireless-2.6/net/ieee80211/ieee80211_tx.c
> @@ -502,8 +502,6 @@ int ieee80211_xmit(struct sk_buff *skb,
> if (host_encrypt)
> ieee80211_encrypt_fragment(ieee, skb_frag, hdr_len);
> else if (host_build_iv) {
> - struct ieee80211_crypt_data *crypt;
> -
> crypt = ieee->crypt[ieee->tx_keyidx];
> atomic_inc(&crypt->refcnt);
> if (crypt->ops->build_iv)
Couldn't you remove the "crypt = ieee->crypt[ieee->tx_keyidx];"
as well?
John
--
John W. Linville
linville@tuxdriver.com
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] ieee80211: Fix sparse warning
2007-02-02 20:32 ` John W. Linville
@ 2007-02-02 21:38 ` Larry Finger
0 siblings, 0 replies; 3+ messages in thread
From: Larry Finger @ 2007-02-02 21:38 UTC (permalink / raw)
To: John W. Linville; +Cc: Michael Buesch, netdev, Bcm43xx-dev
John W. Linville wrote:
> On Wed, Jan 31, 2007 at 06:50:19PM -0600, Larry Finger wrote:
>> Sparse issues the warning "warning: symbol 'crypt' shadows an earlier one"
>> in net/ieee80211/ieee80211_tx.c.
>>
>> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
>> ---
>>
>> Index: wireless-2.6/net/ieee80211/ieee80211_tx.c
>> ===================================================================
>> --- wireless-2.6.orig/net/ieee80211/ieee80211_tx.c
>> +++ wireless-2.6/net/ieee80211/ieee80211_tx.c
>> @@ -502,8 +502,6 @@ int ieee80211_xmit(struct sk_buff *skb,
>> if (host_encrypt)
>> ieee80211_encrypt_fragment(ieee, skb_frag, hdr_len);
>> else if (host_build_iv) {
>> - struct ieee80211_crypt_data *crypt;
>> -
>> crypt = ieee->crypt[ieee->tx_keyidx];
>> atomic_inc(&crypt->refcnt);
>> if (crypt->ops->build_iv)
>
> Couldn't you remove the "crypt = ieee->crypt[ieee->tx_keyidx];"
> as well?
Yes it can. I'll send a revised patch along shortly.
Larry
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-02-02 21:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-02-01 0:50 [PATCH] ieee80211: Fix sparse warning Larry Finger
2007-02-02 20:32 ` John W. Linville
2007-02-02 21:38 ` Larry Finger
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).