linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] b43: N-PHY: fix copy&paste typo
@ 2010-04-01 21:11 Rafał Miłecki
  2010-04-01 23:05 ` richardvoigt
  0 siblings, 1 reply; 4+ messages in thread
From: Rafał Miłecki @ 2010-04-01 21:11 UTC (permalink / raw)
  To: linux-wireless, John W. Linville
  Cc: b43-dev, Myhailo Danylenko, Rafał Miłecki

Reported-by: Myhailo Danylenko <isbear@ukrpost.net>
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
 drivers/net/wireless/b43/phy_n.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/wireless/b43/phy_n.c b/drivers/net/wireless/b43/phy_n.c
index 6fd140a..2ae2445 100644
--- a/drivers/net/wireless/b43/phy_n.c
+++ b/drivers/net/wireless/b43/phy_n.c
@@ -2790,7 +2790,7 @@ static int b43_nphy_cal_tx_iq_lo(struct b43_wldev *dev,
 			}
 			b43_ntab_write_bulk(dev, B43_NTAB16(15, 88), 4,
 						buffer);
-			b43_ntab_write_bulk(dev, B43_NTAB16(15, 101), 2,
+			b43_ntab_read_bulk(dev, B43_NTAB16(15, 101), 2,
 						buffer);
 			b43_ntab_write_bulk(dev, B43_NTAB16(15, 85), 2,
 						buffer);
-- 
1.6.4.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] b43: N-PHY: fix copy&paste typo
  2010-04-01 21:11 [PATCH] b43: N-PHY: fix copy&paste typo Rafał Miłecki
@ 2010-04-01 23:05 ` richardvoigt
  2010-04-01 23:12   ` Larry Finger
  2010-04-02  7:28   ` Michael Buesch
  0 siblings, 2 replies; 4+ messages in thread
From: richardvoigt @ 2010-04-01 23:05 UTC (permalink / raw)
  To: Rafał Miłecki
  Cc: linux-wireless, John W. Linville, b43-dev, Myhailo Danylenko

RG9lcyBhbnlib2R5IGVsc2UgdGhpbmsgYWxsIHRoZSBtYWdpYyBudW1iZXJzIG1ha2UgdGhpcy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LSDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDC
oCDCoCDCoCBiNDNfbnRhYl93cml0ZV9idWxrKGRldiwgQjQzX05UQUIxNigxNSwgMTAxKSwgMiwK
PiArIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIGI0M19udGFiX3JlYWRfYnVsayhk
ZXYsIEI0M19OVEFCMTYoMTUsIDEwMSksIDIsCj4gwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAg
wqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqAgwqBidWZmZXIpOwo+IMKg
IMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgIMKgYjQzX250YWJfd3JpdGVfYnVsayhkZXYs
IEI0M19OVEFCMTYoMTUsIDg1KSwgMiwKPiDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDC
oCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoCDCoGJ1ZmZlcik7Cj4gLS0KPiAx
LjYuNC4yCj4KPgo+IF9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f
X19fCj4gYjQzLWRldiBtYWlsaW5nIGxpc3QKPiBiNDMtZGV2QGxpc3RzLmluZnJhZGVhZC5vcmcK
PiBodHRwOi8vbGlzdHMuaW5mcmFkZWFkLm9yZy9tYWlsbWFuL2xpc3RpbmZvL2I0My1kZXYKPgo=

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] b43: N-PHY: fix copy&paste typo
  2010-04-01 23:05 ` richardvoigt
@ 2010-04-01 23:12   ` Larry Finger
  2010-04-02  7:28   ` Michael Buesch
  1 sibling, 0 replies; 4+ messages in thread
From: Larry Finger @ 2010-04-01 23:12 UTC (permalink / raw)
  To: richardvoigt@gmail.com
  Cc: Rafał Miłecki, linux-wireless, John W. Linville,
	b43-dev, Myhailo Danylenko

On 04/01/2010 06:05 PM, richardvoigt@gmail.com wrote:
> Does anybody else think all the magic numbers make this code hard to understand?
> 
> 2010/4/1 Rafał Miłecki <zajec5@gmail.com>:
>> Reported-by: Myhailo Danylenko <isbear@ukrpost.net>
>> Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
>> ---
>>  drivers/net/wireless/b43/phy_n.c |    2 +-
>>  1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/drivers/net/wireless/b43/phy_n.c b/drivers/net/wireless/b43/phy_n.c
>> index 6fd140a..2ae2445 100644
>> --- a/drivers/net/wireless/b43/phy_n.c
>> +++ b/drivers/net/wireless/b43/phy_n.c
>> @@ -2790,7 +2790,7 @@ static int b43_nphy_cal_tx_iq_lo(struct b43_wldev *dev,
>>                        }
>>                        b43_ntab_write_bulk(dev, B43_NTAB16(15, 88), 4,

If you have any idea what the 16-bit N PHY table 15 with offset 88 and
length 4 means to the firmware, please be our guest. All those us that
do the RE can only decompile the Broadcom driver, and write the specs.
Rafal writes the b43 code from that.

Larry


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] b43: N-PHY: fix copy&paste typo
  2010-04-01 23:05 ` richardvoigt
  2010-04-01 23:12   ` Larry Finger
@ 2010-04-02  7:28   ` Michael Buesch
  1 sibling, 0 replies; 4+ messages in thread
From: Michael Buesch @ 2010-04-02  7:28 UTC (permalink / raw)
  To: richardvoigt@gmail.com
  Cc: Rafał Miłecki, linux-wireless, John W. Linville,
	b43-dev, Myhailo Danylenko

On Friday 02 April 2010 01:05:22 richardvoigt@gmail.com wrote:
> Does anybody else think all the magic numbers make this code hard to understand?

Not at all. These are perfectly valid decimal numbers.
In my country you learn them in first class at school.

Seriously. What should we do?
#define NTAB_OFFSET_THAT_IS_FIFTEEN	15
No!

And btw, I'm pretty sure that broadcom also opencodes lots of these offsets
and values in their code. And that often is a sane thing to do. Creating
hundred thousands of defines that nobody understands is not a sane solution, either.

> 2010/4/1 Rafał Miłecki <zajec5@gmail.com>:
> > Reported-by: Myhailo Danylenko <isbear@ukrpost.net>
> > Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
> > ---
> >  drivers/net/wireless/b43/phy_n.c |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/drivers/net/wireless/b43/phy_n.c b/drivers/net/wireless/b43/phy_n.c
> > index 6fd140a..2ae2445 100644
> > --- a/drivers/net/wireless/b43/phy_n.c
> > +++ b/drivers/net/wireless/b43/phy_n.c
> > @@ -2790,7 +2790,7 @@ static int b43_nphy_cal_tx_iq_lo(struct b43_wldev *dev,
> >                        }
> >                        b43_ntab_write_bulk(dev, B43_NTAB16(15, 88), 4,
> >                                                buffer);
> > -                       b43_ntab_write_bulk(dev, B43_NTAB16(15, 101), 2,
> > +                       b43_ntab_read_bulk(dev, B43_NTAB16(15, 101), 2,
> >                                                buffer);
> >                        b43_ntab_write_bulk(dev, B43_NTAB16(15, 85), 2,
> >                                                buffer);
> > --
> > 1.6.4.2
> >
> >
> > _______________________________________________
> > b43-dev mailing list
> > b43-dev@lists.infradead.org
> > http://lists.infradead.org/mailman/listinfo/b43-dev
> >
> 

-- 
Greetings, Michael.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-04-02  7:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-01 21:11 [PATCH] b43: N-PHY: fix copy&paste typo Rafał Miłecki
2010-04-01 23:05 ` richardvoigt
2010-04-01 23:12   ` Larry Finger
2010-04-02  7:28   ` Michael Buesch

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).