2009-01-19 09:03:27

by Helmut Schaa

[permalink] [raw]
Subject: [PATCH 2/2] iwl3945: Remove unused variables

=46ix the following warnings in iwl-3945-rs.c by removing unused variab=
les.

drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_rate_scale_flush_windows=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused variabl=
e =E2=80=98priv=E2=80=99
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_bg_rate_scale_flush=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused variabl=
e =E2=80=98priv=E2=80=99
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_collect_tx_data=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused variabl=
e =E2=80=98priv=E2=80=99
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98rs_fre=
e_sta=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused variabl=
e =E2=80=98priv=E2=80=99
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_get_adjacent_rate=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused variabl=
e =E2=80=98priv=E2=80=99

Signed-off-by: Helmut Schaa <[email protected]>
---
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c b/drivers/net/w=
ireless/iwlwifi/iwl-3945-rs.c
index ba64034..2af45f4 100644
--- a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c
+++ b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c
@@ -183,7 +183,6 @@ static int iwl3945_rate_scale_flush_windows(struct =
iwl3945_rs_sta *rs_sta)
int unflushed =3D 0;
int i;
unsigned long flags;
- struct iwl_priv *priv =3D rs_sta->priv;
=20
/*
* For each rate, if we have collected data on that rate
@@ -216,7 +215,6 @@ static int iwl3945_rate_scale_flush_windows(struct =
iwl3945_rs_sta *rs_sta)
static void iwl3945_bg_rate_scale_flush(unsigned long data)
{
struct iwl3945_rs_sta *rs_sta =3D (void *)data;
- struct iwl_priv *priv =3D rs_sta->priv;
int unflushed =3D 0;
unsigned long flags;
u32 packet_count, duration, pps;
@@ -290,7 +288,6 @@ static void iwl3945_collect_tx_data(struct iwl3945_=
rs_sta *rs_sta,
{
unsigned long flags;
s32 fail_count;
- struct iwl_priv *priv =3D rs_sta->priv;
=20
if (!retries) {
IWL_DEBUG_RATE("leave: retries =3D=3D 0 -- should be at least 1\n");
@@ -438,7 +435,6 @@ static void rs_free_sta(void *iwl_priv, struct ieee=
80211_sta *sta,
{
struct iwl3945_sta_priv *psta =3D (void *) sta->drv_priv;
struct iwl3945_rs_sta *rs_sta =3D priv_sta;
- struct iwl_priv *priv =3D rs_sta->priv;
=20
psta->rs_sta =3D NULL;
=20
@@ -556,7 +552,6 @@ static u16 iwl3945_get_adjacent_rate(struct iwl3945=
_rs_sta *rs_sta,
{
u8 high =3D IWL_RATE_INVALID;
u8 low =3D IWL_RATE_INVALID;
- struct iwl_priv *priv =3D rs_sta->priv;
=20
/* 802.11A walks to the next literal adjacent rate in
* the rate table */


2009-01-19 13:08:56

by Samuel Ortiz

[permalink] [raw]
Subject: Re: [PATCH 2/2] iwl3945: Remove unused variables


On Mon, 19 Jan 2009 09:55:32 +0100, Helmut Schaa=0D
<[email protected]> wrote:=0D
> Fix the following warnings in iwl-3945-rs.c by removing unused variab=
les.=0D
> =0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function=0D
> =E2=80=98iwl3945_rate_scale_flush_windows=E2=80=99:=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused varia=
ble=0D
> =E2=80=98priv=E2=80=99=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function=0D
> =E2=80=98iwl3945_bg_rate_scale_flush=E2=80=99:=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused varia=
ble=0D
> =E2=80=98priv=E2=80=99=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function=0D
> =E2=80=98iwl3945_collect_tx_data=E2=80=99:=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused varia=
ble=0D
> =E2=80=98priv=E2=80=99=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function=0D
=E2=80=98rs_free_sta=E2=80=99:=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused varia=
ble=0D
> =E2=80=98priv=E2=80=99=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function=0D
> =E2=80=98iwl3945_get_adjacent_rate=E2=80=99:=0D
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused varia=
ble=0D
> =E2=80=98priv=E2=80=99=0D
> =0D
> Signed-off-by: Helmut Schaa <[email protected]>=0D
Acked-by: Samuel Ortiz <[email protected]>=0D
=0D
Thanks Helmut.=0D
=0D
> ---=0D
> diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c=0D
> b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c=0D
> index ba64034..2af45f4 100644=0D
> --- a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c=0D
> +++ b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c=0D
> @@ -183,7 +183,6 @@ static int iwl3945_rate_scale_flush_windows(struc=
t=0D
> iwl3945_rs_sta *rs_sta)=0D
> int unflushed =3D 0;=0D
> int i;=0D
> unsigned long flags;=0D
> - struct iwl_priv *priv =3D rs_sta->priv;=0D
> =0D
> /*=0D
> * For each rate, if we have collected data on that rate=0D
> @@ -216,7 +215,6 @@ static int iwl3945_rate_scale_flush_windows(struc=
t=0D
> iwl3945_rs_sta *rs_sta)=0D
> static void iwl3945_bg_rate_scale_flush(unsigned long data)=0D
> {=0D
> struct iwl3945_rs_sta *rs_sta =3D (void *)data;=0D
> - struct iwl_priv *priv =3D rs_sta->priv;=0D
> int unflushed =3D 0;=0D
> unsigned long flags;=0D
> u32 packet_count, duration, pps;=0D
> @@ -290,7 +288,6 @@ static void iwl3945_collect_tx_data(struct=0D
> iwl3945_rs_sta *rs_sta,=0D
> {=0D
> unsigned long flags;=0D
> s32 fail_count;=0D
> - struct iwl_priv *priv =3D rs_sta->priv;=0D
> =0D
> if (!retries) {=0D
> IWL_DEBUG_RATE("leave: retries =3D=3D 0 -- should be at least 1\n"=
);=0D
> @@ -438,7 +435,6 @@ static void rs_free_sta(void *iwl_priv, struct=0D
> ieee80211_sta *sta,=0D
> {=0D
> struct iwl3945_sta_priv *psta =3D (void *) sta->drv_priv;=0D
> struct iwl3945_rs_sta *rs_sta =3D priv_sta;=0D
> - struct iwl_priv *priv =3D rs_sta->priv;=0D
> =0D
> psta->rs_sta =3D NULL;=0D
> =0D
> @@ -556,7 +552,6 @@ static u16 iwl3945_get_adjacent_rate(struct=0D
> iwl3945_rs_sta *rs_sta,=0D
> {=0D
> u8 high =3D IWL_RATE_INVALID;=0D
> u8 low =3D IWL_RATE_INVALID;=0D
> - struct iwl_priv *priv =3D rs_sta->priv;=0D
> =0D
> /* 802.11A walks to the next literal adjacent rate in=0D
> * the rate table */=0D
> --=0D
> To unsubscribe from this list: send the line "unsubscribe linux-wirel=
ess"=0D
> in=0D
> the body of a message to [email protected]=0D
> More majordomo info at http://vger.kernel.org/majordomo-info.html

2009-01-21 19:30:46

by John W. Linville

[permalink] [raw]
Subject: Re: [PATCH 2/2] iwl3945: Remove unused variables

On Mon, Jan 19, 2009 at 09:55:32AM +0100, Helmut Schaa wrote:
> Fix the following warnings in iwl-3945-rs.c by removing unused variab=
les.
>=20
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_rate_scale_flush_windows=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused varia=
ble =E2=80=98priv=E2=80=99
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_bg_rate_scale_flush=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused varia=
ble =E2=80=98priv=E2=80=99
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_collect_tx_data=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused varia=
ble =E2=80=98priv=E2=80=99
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98rs_f=
ree_sta=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused varia=
ble =E2=80=98priv=E2=80=99
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_get_adjacent_rate=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused varia=
ble =E2=80=98priv=E2=80=99
>=20
> Signed-off-by: Helmut Schaa <[email protected]>

With this applied, I get these:

CC [M] drivers/net/wireless/iwlwifi/iwl-3945-rs.o
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_rate_scale_flush_windows=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: (Each undeclared=
identifier is reported only once
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: for each functio=
n it appears in.)
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_bg_rate_scale_flush=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:222: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_collect_tx_data=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98rs_fre=
e_sta=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl394=
5_get_adjacent_rate=E2=80=99:
drivers/net/wireless/iwlwifi/iwl-3945-rs.c:594: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
make[2]: *** [drivers/net/wireless/iwlwifi/iwl-3945-rs.o] Error 1
make[1]: *** [drivers/net/wireless/iwlwifi] Error 2
make: *** [drivers/net/wireless/] Error 2

Dropping...

John
--=20
John W. Linville Someday the world will need a hero, and you
[email protected] might be all we have. Be ready.

2009-01-22 10:44:52

by Helmut Schaa

[permalink] [raw]
Subject: Re: [PATCH 2/2] iwl3945: Remove unused variables

Am Mittwoch, 21. Januar 2009 schrieb John W. Linville:
> On Mon, Jan 19, 2009 at 09:55:32AM +0100, Helmut Schaa wrote:
> > Fix the following warnings in iwl-3945-rs.c by removing unused vari=
ables.
> >=20
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iw=
l3945_rate_scale_flush_windows=E2=80=99:
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused var=
iable =E2=80=98priv=E2=80=99
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iw=
l3945_bg_rate_scale_flush=E2=80=99:
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused var=
iable =E2=80=98priv=E2=80=99
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iw=
l3945_collect_tx_data=E2=80=99:
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused var=
iable =E2=80=98priv=E2=80=99
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98rs=
_free_sta=E2=80=99:
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused var=
iable =E2=80=98priv=E2=80=99
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iw=
l3945_get_adjacent_rate=E2=80=99:
> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused var=
iable =E2=80=98priv=E2=80=99
> >=20
> > Signed-off-by: Helmut Schaa <[email protected]>
>=20
> With this applied, I get these:
>=20
> CC [M] drivers/net/wireless/iwlwifi/iwl-3945-rs.o
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_rate_scale_flush_windows=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: (Each undeclar=
ed identifier is reported only once
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: for each funct=
ion it appears in.)
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_bg_rate_scale_flush=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:222: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_collect_tx_data=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98rs_f=
ree_sta=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function =E2=80=98iwl3=
945_get_adjacent_rate=E2=80=99:
> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:594: error: =E2=80=98priv=E2=
=80=99 undeclared (first use in this function)
> make[2]: *** [drivers/net/wireless/iwlwifi/iwl-3945-rs.o] Error 1
> make[1]: *** [drivers/net/wireless/iwlwifi] Error 2
> make: *** [drivers/net/wireless/] Error 2
>=20
> Dropping...

Ah, sorry for that. I compiled without CONFIG_IWL_DEBUG. Instead of rem=
oving
these lines they should be surrounded by an CONFIG_IWL_DEBUG check. I'l=
l send
that soon.

Helmut

2009-01-22 19:08:42

by Helmut Schaa

[permalink] [raw]
Subject: Re: [PATCH 2/2] iwl3945: Remove unused variables

Am Donnerstag, 22. Januar 2009 schrieb Tomas Winkler:
> On Thu, Jan 22, 2009 at 12:44 PM, Helmut Schaa
> <[email protected]> wrote:
> > Am Mittwoch, 21. Januar 2009 schrieb John W. Linville:
> >> On Mon, Jan 19, 2009 at 09:55:32AM +0100, Helmut Schaa wrote:
> >> > Fix the following warnings in iwl-3945-rs.c by removing unused variables.
> >> >
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_rate_scale_flush_windows':
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused variable 'priv'
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_bg_rate_scale_flush':
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused variable 'priv'
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_collect_tx_data':
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused variable 'priv'
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'rs_free_sta':
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused variable 'priv'
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_get_adjacent_rate':
> >> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused variable 'priv'
> >> >
> >> > Signed-off-by: Helmut Schaa <[email protected]>
> >>
> >> With this applied, I get these:
> >>
> >> CC [M] drivers/net/wireless/iwlwifi/iwl-3945-rs.o
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_rate_scale_flush_windows':
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: 'priv' undeclared (first use in this function)
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: (Each undeclared identifier is reported only once
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: for each function it appears in.)
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_bg_rate_scale_flush':
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:222: error: 'priv' undeclared (first use in this function)
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_collect_tx_data':
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: error: 'priv' undeclared (first use in this function)
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'rs_free_sta':
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: error: 'priv' undeclared (first use in this function)
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_get_adjacent_rate':
> >> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:594: error: 'priv' undeclared (first use in this function)
> >> make[2]: *** [drivers/net/wireless/iwlwifi/iwl-3945-rs.o] Error 1
> >> make[1]: *** [drivers/net/wireless/iwlwifi] Error 2
> >> make: *** [drivers/net/wireless/] Error 2
> >>
> >> Dropping...
> >
> > Ah, sorry for that. I compiled without CONFIG_IWL_DEBUG. Instead of removing
> > these lines they should be surrounded by an CONFIG_IWL_DEBUG check. I'll send
> > that soon.
>
> Please use
> struct iwl_priv *priv __maybe_unused priv;
> look at in iwl-agn-rs.c

Will do. Thanks for the hint.

Helmut

2009-01-22 11:28:44

by Tomas Winkler

[permalink] [raw]
Subject: Re: [PATCH 2/2] iwl3945: Remove unused variables

On Thu, Jan 22, 2009 at 12:44 PM, Helmut Schaa
<[email protected]> wrote:
> Am Mittwoch, 21. Januar 2009 schrieb John W. Linville:
>> On Mon, Jan 19, 2009 at 09:55:32AM +0100, Helmut Schaa wrote:
>> > Fix the following warnings in iwl-3945-rs.c by removing unused variables.
>> >
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_rate_scale_flush_windows':
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:186: warning: unused variable 'priv'
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_bg_rate_scale_flush':
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:219: warning: unused variable 'priv'
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_collect_tx_data':
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: warning: unused variable 'priv'
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'rs_free_sta':
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: warning: unused variable 'priv'
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_get_adjacent_rate':
>> > drivers/net/wireless/iwlwifi/iwl-3945-rs.c:559: warning: unused variable 'priv'
>> >
>> > Signed-off-by: Helmut Schaa <[email protected]>
>>
>> With this applied, I get these:
>>
>> CC [M] drivers/net/wireless/iwlwifi/iwl-3945-rs.o
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_rate_scale_flush_windows':
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: 'priv' undeclared (first use in this function)
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: (Each undeclared identifier is reported only once
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:199: error: for each function it appears in.)
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_bg_rate_scale_flush':
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:222: error: 'priv' undeclared (first use in this function)
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_collect_tx_data':
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:293: error: 'priv' undeclared (first use in this function)
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'rs_free_sta':
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:441: error: 'priv' undeclared (first use in this function)
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c: In function 'iwl3945_get_adjacent_rate':
>> drivers/net/wireless/iwlwifi/iwl-3945-rs.c:594: error: 'priv' undeclared (first use in this function)
>> make[2]: *** [drivers/net/wireless/iwlwifi/iwl-3945-rs.o] Error 1
>> make[1]: *** [drivers/net/wireless/iwlwifi] Error 2
>> make: *** [drivers/net/wireless/] Error 2
>>
>> Dropping...
>
> Ah, sorry for that. I compiled without CONFIG_IWL_DEBUG. Instead of removing
> these lines they should be surrounded by an CONFIG_IWL_DEBUG check. I'll send
> that soon.

Please use
struct iwl_priv *priv __maybe_unused priv;
look at in iwl-agn-rs.c

Thanks
Tomas