b43: Add support for new firmware
Subsystems (2)
PATCH 1/1 b43: Add support for new firmware
This patch adds support for new firmware.
Old firmware is still supported until July 2008.
To get new firmware, go to ftp://ftp.linksys.com/opensourcecode/wrt150nv11/1.51.3/ and download the tarball. We don't have a smaller tarball, yet. That will be fixed later.
You can extract firmware out of the "wl_ap.o" file contained in this tarball using latest fwcutter. You must pass the option --unsupported to fwcutter.
Fwcutter-010 with official support for a new firmware image will be released soon.
---
For 2.6.25
drivers/net/wireless/b43/dma.c +11 -11
@@ -804,44 +804,43 @@ struct b43_dmaring *b43_setup_dmaring(st ring->meta =kcalloc (nr_slots,sizeof (struct b43_dmadesc_meta ),GFP_KERNEL );if (!ring->meta) goto err_kfree_ring;if (for_tx) { ring->txhdr_cache =kcalloc (nr_slots, -sizeof (struct b43_txhdr_fw4 ), +b43_txhdr_size (dev),GFP_KERNEL );if (!ring->txhdr_cache) goto err_kfree_meta;/* test for ability to dma to txhdr_cache */ dma_test =dma_map_single (dev->dev->dev, ring->txhdr_cache, -sizeof (struct b43_txhdr_fw4 ), +b43_txhdr_size (dev),DMA_TO_DEVICE );if (dma_mapping_error (dma_test)) {/* ugh realloc */ kfree (ring->txhdr_cache); ring->txhdr_cache =kcalloc (nr_slots, -sizeof (struct -b43_txhdr_fw4 ), +b43_txhdr_size (dev),GFP_KERNEL |GFP_DMA );if (!ring->txhdr_cache) goto err_kfree_meta; dma_test =dma_map_single (dev->dev->dev, ring->txhdr_cache, -sizeof (struct b43_txhdr_fw4 ), +b43_txhdr_size (dev),DMA_TO_DEVICE );if (dma_mapping_error (dma_test)) goto err_kfree_txhdr_cache; }dma_unmap_single (dev->dev->dev, - dma_test,sizeof (struct b43_txhdr_fw4 ), + dma_test,b43_txhdr_size (dev),DMA_TO_DEVICE ); } ring->dev = dev; ring->nr_slots = nr_slots; ring->mmio_base =b43_dmacontroller_base (dma64, controller_index);
@@ -1119,32 +1118,33 @@ static int dma_tx_fragment(struct b43_dmint err;struct b43_dmadesc_generic *desc;struct b43_dmadesc_meta *meta;struct b43_dmadesc_meta *meta_hdr;struct sk_buff *bounce_skb;u16 cookie; +size_t hdrsize =b43_txhdr_size (ring->dev);#define SLOTS_PER_PACKET 2B43_WARN_ON (skb_shinfo (skb)->nr_frags);/* Get a slot for the header. */ slot =request_slot (ring); desc = ops->idx2desc (ring, slot, &meta_hdr);memset (meta_hdr,0 ,sizeof (*meta_hdr)); - header = &(ring->txhdr_cache[slot *sizeof (struct b43_txhdr_fw4 )]); + header = &(ring->txhdr_cache[slot * hdrsize]); cookie =generate_cookie (ring, slot);b43_generate_txhdr (ring->dev, header, skb->data, skb->len, ctl, cookie); meta_hdr->dmaaddr =map_descbuffer (ring, (unsigned char *)header, -sizeof (struct b43_txhdr_fw4 ),1 ); + hdrsize,1 );if (dma_mapping_error (meta_hdr->dmaaddr))return -EIO ; ops->fill_descriptor (ring, desc, meta_hdr->dmaaddr, -sizeof (struct b43_txhdr_fw4 ),1 ,0 ,0 ); + hdrsize,1 ,0 ,0 );/* Get a slot for the payload. */ slot =request_slot (ring); desc = ops->idx2desc (ring, slot, &meta);memset (meta,0 ,sizeof (*meta));
@@ -1186,13 +1186,13 @@ static int dma_tx_fragment(struct b43_dmreturn 0 ; out_free_bounce:dev_kfree_skb_any (skb); out_unmap_hdr:unmap_descbuffer (ring, meta_hdr->dmaaddr, -sizeof (struct b43_txhdr_fw4 ),1 ); + hdrsize,1 );return err; }static inline int should_inject_overflow (struct b43_dmaring *ring) {#ifdef CONFIG_B43_DEBUG
@@ -1295,13 +1295,13 @@ void b43_dma_handle_txstatus(struct b43_if (meta->skb)unmap_descbuffer (ring, meta->dmaaddr, meta->skb->len,1 );else unmap_descbuffer (ring, meta->dmaaddr, -sizeof (struct b43_txhdr_fw4 ),1 ); +b43_txhdr_size (dev),1 );if (meta->is_last_fragment) {B43_WARN_ON (!meta->skb);/* Call back to inform the ieee80211 subsystem about the * status of the transmission. * Some fields of txstat are already filled in dma_tx().
drivers/net/wireless/b43/main.c +36 -14
167 lines not on this page · raw message
drivers/net/wireless/b43/xmit.c +94 -50
248 lines not on this page · raw message
drivers/net/wireless/b43/xmit.h +146 -54
220 lines not on this page · raw message
Documentation/feature-removal-schedule.txt +9 -0
@@ -355,6 +355,15 @@ What: rc80211-simple rate control algori When: 2.6.26 Files: net/mac80211/rc80211-simple.c Why: This algorithm was provided for reference but always exhibited bad responsiveness and performance and has some serious flaws. It has been replaced by rc80211-pid. Who: Stefano Brivio <[email protected]> + +--------------------------- + +What: b43 support for firmware revision < 410 +When: July 2008 +Why: The support code for the old firmware hurts code readability/maintainability + and slightly hurts runtime performance. Bugfixes for the old firmware + are not provided by Broadcom anymore. +Who: Michael Buesch <[email protected]>
drivers/net/wireless/b43/phy.h +2 -0
@@ -177,12 +177,14 @@ void b43_gtab_write(struct b43_wldev *deenum {B43_ANTENNA0 ,/* Antenna 0 */ B43_ANTENNA1 ,/* Antenna 0 */ B43_ANTENNA_AUTO1 ,/* Automatic, starting with antenna 1 */ B43_ANTENNA_AUTO0 ,/* Automatic, starting with antenna 0 */ +B43_ANTENNA2 , +B43_ANTENNA3 =8 ,B43_ANTENNA_AUTO =B43_ANTENNA_AUTO0 ,B43_ANTENNA_DEFAULT =B43_ANTENNA_AUTO , };enum {
Quoted 7 lines · Michael Buesch
This patch adds support for new firmware.
Old firmware is still supported until July 2008.To get new firmware, go to ftp://ftp.linksys.com/opensourcecode/wrt150nv11/1.51.3/ and download the tarball. We don't have a smaller tarball, yet. That will be fixed later.
I have finally found some time and hardware to test it, but the tarball is overwhelming at its 186M. And the worst thing, the server disconnected after 30M and appears to be down right now. P.S. It's up, ETA is 48 minutes.
There were two files there. I hope either is fine. I'm trying to download WRT150NV11_v1.51.3_ETSI.tgz
Cannot we petition Linksys to put wl_ap.o outside the tarball? Or maybe Broadcom could do it?
Even a zip file would be better. It's possible to cut a part of the zip file and uncompress it with gzip.
It's really a travesty of open source. The file is "available", but you have do download 186M of useless (for me at least) mips compilers and other stuff. And I have a relatively good connection.
Quoted 5 lines
You can extract firmware out of the "wl_ap.o" file contained in this tarball using latest fwcutter. You must pass the option --unsupported to fwcutter.
Fwcutter-010 with official support for a new firmware image will be released soon.
Do you know that the Subversion repository of fwcutter has no files at all? I mean svn://svn.berlios.de/bcm43xx/trunk
Yes, I will try --unsupported, with version 009.
Signature · 2 lines
Regards, Pavel Roskin
Quoted 10 lines · On Tue, 15 Jan 2008 13:27:42 -0500 Pavel Roskin <[email protected]> wrote:
I have finally found some time and hardware to test it, but the tarball is overwhelming at its 186M. And the worst thing, the server disconnected after 30M and appears to be down right now.
P.S. It's up, ETA is 48 minutes.There were two files there. I hope either is fine. I'm trying to download WRT150NV11_v1.51.3_ETSI.tgz
Cannot we petition Linksys to put wl_ap.o outside the tarball? Or maybe Broadcom could do it?
Good luck. ;) The only long-term lasting solution I see is to put more effort on an open firmware. The instruction set has been figured out, we just lack people and time there.
Quoted 4 lines
Do you know that the Subversion repository of fwcutter has no files at all? I mean svn://svn.berlios.de/bcm43xx/trunk
Yes, I will try --unsupported, with version 009.
fwcutter development now happens here:
http://bu3sch.de/gitweb?p=b43-tools.git;a=summary
Maybe we should add this along with git URLs on linuxwireless.org.
--
Ciao
Stefano
Quoted 11 lines · On Tuesday 15 January 2008 20:15:38 Stefano Brivio wrote:
Quoted 8 lines · On Tue, 15 Jan 2008 13:27:42 -0500 Pavel Roskin <[email protected]> wrote:
I have finally found some time and hardware to test it, but the tarball is overwhelming at its 186M. And the worst thing, the server disconnected after 30M and appears to be down right now.
P.S. It's up, ETA is 48 minutes.There were two files there. I hope either is fine. I'm trying to download WRT150NV11_v1.51.3_ETSI.tgz
Quoted 6 lines
Quoted 2 lines
Cannot we petition Linksys to put wl_ap.o outside the tarball? Or maybe Broadcom could do it?
Good luck. ;) The only long-term lasting solution I see is to put more effort on an open firmware. The instruction set has been figured out, we just lack people and time there.
We already have a better file on an openwrt server that will be the officially supported one soon.
I just have to create a new fwcutter tarball and link from linuxwireless.org to it. I already added support for the file to fwcutter git.
See Stefano's comment below.
Quoted 7 lines
Quoted 4 lines
Do you know that the Subversion repository of fwcutter has no files at all? I mean svn://svn.berlios.de/bcm43xx/trunk
Yes, I will try --unsupported, with version 009.
fwcutter development now happens here:
http://bu3sch.de/gitweb?p=b43-tools.git;a=summary
Yep, the berlios stuff is dropped completely, except the download section for the fwcutter tarballs. But that may also change in future. We will announce that on linuxwireless.org.
Quoted 1 line
Maybe we should add this along with git URLs on linuxwireless.org.
Please do it, if you feel so.
Signature · 1 line
Greetings Michael.
Quoted 3 lines · On Tuesday 15 January 2008 23:21:40 Michael Buesch wrote:
Yep, the berlios stuff is dropped completely, except the download section for the fwcutter tarballs. But that may also change in future. We will announce that on linuxwireless.org.
Actually, I think I will change that _now_.
I'll simply put the stuff on my server. berlios is just too annoying. I'll put the new URLs on the b43 linuxwireless.org page.
Signature · 1 line
Greetings Michael.