2009-05-29 19:19:34

by matthieu castet

[permalink] [raw]
Subject: b43 vs b43legacy

Hi,

what's the difference between b43 and b43legacy ?

>From a first point a view, it seems b43 is for core >= 5 and b43legacy for the
other.
There is also firmware difference : b43 need v4 and b43legacy need v3.

But v4 firmware seems to support core 4 (pcm4 & ucode4) and b43 code got some
support for old chips (<5).

Is the split was made because nobody know how to use firmware v4 with core 4 or
because core 4 it so different from newer core.
In the latter case why code for older chip (<5) is not removed from the driver ?


Thanks

Matthieu

PS : sorry if the answer is already available on internet, I try to search it
without finding anything.



2009-05-29 21:15:10

by Larry Finger

[permalink] [raw]
Subject: Re: b43 vs b43legacy

Matthieu CASTET wrote:
>
> what's the difference between b43 and b43legacy ?
>
>>From a first point a view, it seems b43 is for core >= 5 and b43legacy for the
> other.
> There is also firmware difference : b43 need v4 and b43legacy need v3.

The firmware difference is the primary one.

> But v4 firmware seems to support core 4 (pcm4 & ucode4) and b43 code got some
> support for old chips (<5).

The Broadcom V4 drivers do have core 4 firmware embedded in them and it is
extracted by b43-fwcutter; however, b43 will _NOT_ work with core 4 chips. The
firmware loader will only find firmware for core 5 and later. On the other hand,
core 5 devices have been tested with b43legacy. I have a local patch that I use
to switch my 14e4:4312 device so that it uses b43legacy. This allows me to test
any changes.

> Is the split was made because nobody know how to use firmware v4 with core 4 or
> because core 4 it so different from newer core.
> In the latter case why code for older chip (<5) is not removed from the driver ?

>From what I have heard, the older chips do not have the on-board memory to run
V4 firmware. Certainly, any chips that have core 2 cannot handle V4 firmware.

I suspect that any residual code for older chips left in b43 was missed. If you
want to prepare patches to remove such code, please do.

Larry

2009-05-29 20:43:17

by Luis R. Rodriguez

[permalink] [raw]
Subject: Re: b43 vs b43legacy

On Fri, May 29, 2009 at 12:19 PM, Matthieu CASTET
<[email protected]> wrote:
> Hi,
>
> what's the difference between b43 and b43legacy ?
>
> From a first point a view, it seems b43 is for core >= 5 and b43legacy for the
> other.
> There is also firmware difference : b43 need v4 and b43legacy need v3.
>
> But v4 firmware seems to support core 4 (pcm4 & ucode4) and b43 code got some
> support for old chips (<5).
>
> Is the split was made because nobody know how to use firmware v4 with core 4 or
> because core 4 it so different from newer core.
> In the latter case why code for older chip (<5) is not removed from the driver ?
>

http://wireless.kernel.org/en/users/Drivers/b43

Luis

2009-05-30 08:59:06

by Michael Büsch

[permalink] [raw]
Subject: Re: b43 vs b43legacy

On Friday 29 May 2009 21:19:23 Matthieu CASTET wrote:
> In the latter case why code for older chip (<5) is not removed from the driver ?

Nobody cares to do so.

--
Greetings, Michael.

2009-06-01 21:47:14

by matthieu castet

[permalink] [raw]
Subject: Re: b43 vs b43legacy

Larry Finger wrote:
> Matthieu CASTET wrote:
>> what's the difference between b43 and b43legacy ?
>>
>> >From a first point a view, it seems b43 is for core >= 5 and b43legacy for the
>> other.
>> There is also firmware difference : b43 need v4 and b43legacy need v3.
>
> The firmware difference is the primary one.
>
>> But v4 firmware seems to support core 4 (pcm4 & ucode4) and b43 code got some
>> support for old chips (<5).
>
> The Broadcom V4 drivers do have core 4 firmware embedded in them and it is
> extracted by b43-fwcutter; however, b43 will _NOT_ work with core 4 chips. The
> firmware loader will only find firmware for core 5 and later.
Ok but what prevent b43 to support core 4 chip with v4 firmware like the
broadcom driver does ?
I am aware that the current driver doesn't support it, but what are the
missing part to support it ?

If it is the difference from core4 from newer chip, why b43legacy
contains only few special case for core4 chip.

>
> I suspect that any residual code for older chips left in b43 was missed. If you
> want to prepare patches to remove such code, please do.
Yes, I could prepare such patches

Thanks

Matthieu

PS : I don't have core 4 chip nor plan to get some, I ask this out of
curiosity.

2009-06-02 15:17:05

by Michael Büsch

[permalink] [raw]
Subject: Re: b43 vs b43legacy

On Monday 01 June 2009 23:47:06 matthieu castet wrote:
> Ok but what prevent b43 to support core 4 chip with v4 firmware like the
> broadcom driver does ?
> I am aware that the current driver doesn't support it, but what are the
> missing part to support it ?

Recent broadcom drivers do not support <=rev4 anymore.
There are lots of differences between those devices and devices >=rev5.
So we chose to fork it.
That's it. It's as simple as that. Why does it surprise you that much? Lots
of other devices require a separate driver for legacy devices, too.

--
Greetings, Michael.

2009-06-01 22:17:06

by Larry Finger

[permalink] [raw]
Subject: Re: b43 vs b43legacy

matthieu castet wrote:
> Larry Finger wrote:
>> Matthieu CASTET wrote:
>>> what's the difference between b43 and b43legacy ?
>>>
>>> >From a first point a view, it seems b43 is for core >= 5 and
>>> b43legacy for the
>>> other.
>>> There is also firmware difference : b43 need v4 and b43legacy need v3.
>>
>> The firmware difference is the primary one.
>>
>>> But v4 firmware seems to support core 4 (pcm4 & ucode4) and b43 code
>>> got some
>>> support for old chips (<5).
>>
>> The Broadcom V4 drivers do have core 4 firmware embedded in them and
>> it is
>> extracted by b43-fwcutter; however, b43 will _NOT_ work with core 4
>> chips. The
>> firmware loader will only find firmware for core 5 and later.
> Ok but what prevent b43 to support core 4 chip with v4 firmware like the
> broadcom driver does ?
> I am aware that the current driver doesn't support it, but what are the
> missing part to support it ?

The firmware loader code is the first step. Beyond that, I have no idea.

> If it is the difference from core4 from newer chip, why b43legacy
> contains only few special case for core4 chip.

I do not know other than that is what the specs called for.

> PS : I don't have core 4 chip nor plan to get some, I ask this out of
> curiosity.

I do have such a chip, but I use it to verify b43legacy code.

Larry


2009-06-08 19:43:50

by matthieu castet

[permalink] [raw]
Subject: Re: b43 vs b43legacy

Michael Buesch wrote:
> On Monday 01 June 2009 23:47:06 matthieu castet wrote:
>> Ok but what prevent b43 to support core 4 chip with v4 firmware like the
>> broadcom driver does ?
>> I am aware that the current driver doesn't support it, but what are the
>> missing part to support it ?
>
> Recent broadcom drivers do not support <=rev4 anymore.
Which one ?
4.178.10.4 seem to support them [1].

attached is a patch that remove support for old core for b43.

[1]
$readelf -s wl_ap.o|grep -e d11.*4$
1261: 0000b8d0 2952 OBJECT GLOBAL DEFAULT 5 d11lp0initvals14
1406: 0000c458 288 OBJECT GLOBAL DEFAULT 5 d11lp0bsinitvals14
1516: 0000ee88 20128 OBJECT GLOBAL DEFAULT 5 d11ucode4
1520: 000018f8 3720 OBJECT GLOBAL DEFAULT 5 d11b0g0initvals4
1577: 0002f13c 30992 OBJECT GLOBAL DEFAULT 5 d11ucode14
1614: 00048060 1312 OBJECT GLOBAL DEFAULT 5 d11pcm4
1809: 00003640 56 OBJECT GLOBAL DEFAULT 5 d11a0g0bsinitvals4
1899: 00002780 56 OBJECT GLOBAL DEFAULT 5 d11b0g0bsinitvals4
1920: 000027b8 3720 OBJECT GLOBAL DEFAULT 5 d11a0g0initvals4


Signed-off-by: Matthieu CASTET <[email protected]>


Attachments:
b43_remove_oldcore.diff (7.49 kB)