Update of at76 driver to 0.17 required

Bug #152626 reported by alaperrot
16
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Medium
Tim Gardner
linux-ubuntu-modules-2.6.22 (Ubuntu)
Won't Fix
Undecided
Ubuntu Kernel Network Team
linux-ubuntu-modules-2.6.24 (Ubuntu)
Won't Fix
Undecided
Ubuntu Kernel Network Team

Bug Description

Binary package hint: linux-ubuntu-modules-2.6.22-14-generic

I was testing a WiFi adapter I've got quite some time ago on both my main system (Kubuntu 7.04 AMD64) and test system (Kubuntu 7.10 AMD64).

The adapter is an Inventel USB WLAN, based on an Atmel at76c505a chip.

I've managed to get it working once (on Feisty using KNetworkManager), but most of the time, it does not work (cannot associate to the acces point, using KNetworkManager or iwconfig), and the at76_usb driver often crashes when I unplug the adapter from the USB port, preventing the system to shutdown correctly (hard reset required).

Both Feisty and Gutsy seem to have the same version 0.14beta1 of the driver bundled into the linux-ubuntu-modules package.

On Gutsy, I've tried to build the driver from the at76c503a-source package (version 0.15~dev0.20070427-2) using module-assistant, but this fail with GCC complaining of a missing 'mac' field in some structure.

Then, I've downloaded the latest version of the driver from http://at76c503a.berlios.de/, which is version 0.17 released on 2007-09-30. It compiles without any issue and works really fine for now on Gutsy.

So it would be great to upgrade the at76c503a driver to this new version 0.17 to get these at76c50x based WiFi adapter working out of the box.

Tags: cft-2.6.27
Revision history for this message
alaperrot (alaperrot) wrote :
Revision history for this message
alaperrot (alaperrot) wrote :
Revision history for this message
alaperrot (alaperrot) wrote :
Revision history for this message
alaperrot (alaperrot) wrote :

Another note: since this new at76c503a driver version 0.17 works great with Gutsy, I've just compiled and installed it on my Feisty system with the same result: the WiFi adapter is perfectly detected and configured by KNetworkManager and there was no crash so far.

Revision history for this message
Brandon Kruger (bmk789) wrote :

I have this same problem with a Linksys 11b USB adapter. Machine randomly freezes with caps lock and scroll lock flashing when the device is plugged in. When adapter is not plugged in the machine runs perfectly.

Changed in linux-ubuntu-modules-2.6.22:
assignee: nobody → ubuntu-kernel-network
status: New → Confirmed
Revision history for this message
Brandon Kruger (bmk789) wrote :
Revision history for this message
alaperrot (alaperrot) wrote :

It may be the same bug, I'm not sure. I've never noticed a crash of the at76 driver at startup when I was using the driver provided by Ubuntu (Feisty or Gutsy). The crash always occured when unplugging the adapter.

Now I'm running version 0.17 of the driver (available from http://developer.berlios.de/projects/at76c503a/), and it works really well on my computer.

Revision history for this message
Gustavo Rahal (gustavo-grahal) wrote :

Have the same problem. dmesg shows what logs posted by AnAlach show.

Revision history for this message
Gustavo Rahal (gustavo-grahal) wrote :

Forgot to mention that my adapter is a Linksys wusb11 ver 2.8.

Revision history for this message
Gustavo Rahal (gustavo-grahal) wrote :

AnAlach, how did you install version 0.17? Did you use at76_usb-0.17.tar.gz ? I compiled this version and it seems to load ok (I just execute a "make install")

then:

lsmod |grep at76
at76_usb 108004 0
usbcore 138632 4 at76_usb,ehci_hcd,uhci_hcd

but dmesg gives me:

[ 325.724483] /build/buildd/linux-ubuntu-modules-2.6.22-2.6.22/debian/build/build-generic/wireless/at76/at76c503.c: 2522: assertion dev->istate == INIT failed
[ 326.452209] /build/buildd/linux-ubuntu-modules-2.6.22-2.6.22/debian/build/build-generic/wireless/at76/at76c503.c: 2492: assertion dev->istate == SCANNING failed

so i'm not sure if there is anything else to do since there was a module rename... seems like it's still using the old module somehow.

Revision history for this message
alaperrot (alaperrot) wrote :

Yes, I've used at76_usb-0.17.tar.gz from berlios.de, but I've packaged it using the scripts from the at76c503a-source package in Ubuntu repository and then I've built it using module-assistant.

I've attached the modified at76c503a-source package with version 0.17 of the driver. Once you installed it, you have to use module-assistant to build and install the new at76_usb module.

Revision history for this message
Gustavo Rahal (gustavo-grahal) wrote :

Thanks for the help. I was actually a bit lazy and just noticed that I could copy the compiled .ko into /lib/modules/2.6.22-14-generic/ubuntu/wireless/at76/. Did that and it worked fine.
So version 0.17 is working pretty well with Linksys wusb11 ver 2.8.
+1 for a gutsy update with this new version

Revision history for this message
eggo (m1ke-m477hewz) wrote :

I seem to be having this same problem with a PCMCIA wireless adapter (actually two different ones) I have submitted a bug report here: https://bugs.launchpad.net/ubuntu/+bug/188294

Thanks for any help.

Revision history for this message
Cleber Santz (clebersantz) wrote :

Confirm.

After 2 days trying with standard driver that come with ubuntu i try update to at76 v0.17 and BOOOM, it works realy fine !!

But this version is not supporting WAP yet.

Release 8.04(Hardy Heron)

$ uname -a
Linux 2.6.24-12-generic #1 SMP Wed Mar 12 23:01:54 UTC 2008 i686 GNU/Linux

$ lsusb
Bus 001 Device 004: ID 03eb:7613 Atmel Corp.

Revision history for this message
exactt (giesbert) wrote :

could we please get the new version into hardy!!!!

Revision history for this message
exactt (giesbert) wrote :

setting to confirmed as hardy still ships version 0.14beta1

Changed in linux-ubuntu-modules-2.6.24:
status: New → Confirmed
Changed in linux-ubuntu-modules-2.6.24:
assignee: nobody → ubuntu-kernel-network
Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

Beginning with the Intrepid Ibex 8.10 development cycle the linux-ubuntu-modules package was actually merged with the linux kernel package. Going forward, bugs that would have been reported against linux-ubuntu-modules should now just be reported against linux. I've gone ahead and added the 'linux' task for this report so that this bug remains open against the actively developed kernel. It appears the version in Intrepid is still 0.14beta1 . Thanks.

Changed in linux:
assignee: nobody → ubuntu-kernel-team
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

The Ubuntu Kernel Team is planning to move to the 2.6.27 kernel for the upcoming Intrepid Ibex 8.10 release. As a result, the kernel team would appreciate it if you could please test this newer 2.6.27 Ubuntu kernel. There are one of two ways you should be able to test:

1) If you are comfortable installing packages on your own, the linux-image-2.6.27-* package is currently available for you to install and test.

--or--

2) The upcoming Alpha5 for Intrepid Ibex 8.10 will contain this newer 2.6.27 Ubuntu kernel. Alpha5 is set to be released Thursday Sept 4. Please watch http://www.ubuntu.com/testing for Alpha5 to be announced. You should then be able to test via a LiveCD.

Please let us know immediately if this newer 2.6.27 kernel resolves the bug reported here or if the issue remains. More importantly, please open a new bug report for each new bug/regression introduced by the 2.6.27 kernel and tag the bug report with 'linux-2.6.27'. Also, please specifically note if the issue does or does not appear in the 2.6.26 kernel. Thanks again, we really appreicate your help and feedback.

Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

This bug will remain open against the actively developed kernel bug against 2.6.22 and 2.6.24 this will be closed - http://wiki.ubuntu.com/StableReleaseUpdates. Thanks.

Changed in linux-ubuntu-modules-2.6.24:
status: Confirmed → Won't Fix
Changed in linux-ubuntu-modules-2.6.22:
status: Confirmed → Won't Fix
Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

2.6.27-7 (the Intrepid kernel) is just as bad. In fact it is worse, with often the kernel hanging intermittently with this driver.

Upgrading to at76_usb v0.17 from the berlios.de site seems to improve functionality no end.

Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

Just a note that it looks like the at76_usb v0.17 driver is upstream so it should be available for Jaunty.

Revision history for this message
Launchpad Janitor (janitor) wrote : Kernel team bugs

Per a decision made by the Ubuntu Kernel Team, bugs will longer be assigned to the ubuntu-kernel-team in Launchpad as part of the bug triage process. The ubuntu-kernel-team is being unassigned from this bug report. Refer to https://wiki.ubuntu.com/KernelTeamBugPolicies for more information. Thanks.

Revision history for this message
NickeM (nicklas-marcusson) wrote :

I found this guide how to patch and build at76_usb 0.17 driver for Intrepid Ibex, which works great:
http://guide.ubuntuforums.org/showthread.php?p=6531851#post6531851

It solves the bug report i wrote two years ago.
https://bugs.launchpad.net/ubuntu/+source/atmel-firmware/+bug/120800

Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

Jaunty alpha-3 still stuck on 0.14beta1. Really need that sync with upstream to go to 0.17.

Revision history for this message
Leann Ogasawara (leannogasawara) wrote :

Thanks Karl. Looks like the 0.17 driver is in the staging directory but is not enabled:

ogasawara@yoji:~/ubuntu-jaunty/drivers/staging/at76_usb$ grep -rn "#define DRIVER_VERSION" *

at76_usb.c:45:#define DRIVER_VERSION "0.17"

It appears CONFIG_USB_ATMEL will need to be enabled. I'll try to notify the kernel team. Thanks.

Andy Whitcroft (apw)
Changed in linux:
assignee: nobody → apw
status: Triaged → In Progress
Revision history for this message
Claudio (der-claudio) wrote :

Thanks to Andy Whitcroft for taking care of this bug.

Regarding at76_usb of the staging tree: It works! Enable it! (Kalle Valo, ex-maintainer or maintainer(?) says so too)

@NickeM: Thanks for posting my working-around. As I noted, it's just a work-around that works.

Revision history for this message
Andy Whitcroft (apw) wrote :

Ok I have disabled the Ubuntu version of this driver and enabled the staging version. I have built some test kernels with this applied. Could you test those and report back here. Kernels at the url below:

    http://people.ubuntu.com/~apw/lp152626-jaunty/

Changed in linux:
status: In Progress → Incomplete
Revision history for this message
Claudio (der-claudio) wrote :

Feedback: I can see that the old (ubuntu version) is out and the staging (0.17) is activated. Once I have compiled the at76_usb module from the staging tree myself and tested it successfully. But this jaunty kernel doesn't work properly on an/my intrepid system (another wlan driver fails too).

Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

Feedback: I've compiled the latest Jaunty kernel (2.6.28.9.9) with the staging tree version of the driver (CONFIG_USB_ATMEL=m, CONFIG_WIRELESS_AT76 is not set) and tried it with my at76 based card.

Unfortunately it doesn't work properly. The system boots, but the at76 module reports a firmware download error. I've checked I've got the latest firmware file installed, but still no joy. So there is something borked about the staging driver, even though that is based on v0.17 which should be superior to the older version in ubuntu/misc/wireless.

Revision history for this message
Claudio (der-claudio) wrote :

Feedback: I've tested two jaunty kernels (on a jaunty system ;-):
 - 2.6.8 patched by Andy Whitcroft (2009-01-30): doesn't work. it reported a firmware download error.
 - 2.6.8 "mainline" kernel (kernel without ubuntu patches) + compiling the at76-driver: it works, really! http://kernel.ubuntu.com/~kernel-ppa/mainline/

So IMO the Ubuntu-Kernel needs to patched another way to activate the at76-driver "correctly". Maybe one can find it out by comparing the mainline with the ubuntu one.

Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

Right - I will try and take a look!

Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

For some reason the Ubuntu sauce upgrades the staging/at76_usb files from their 2.6.28 version to a version at some point in the 2.6.29.rcX series (where X is between 4 and 8 as far as I can tell).

Now unfortunately that upgrade introduces a bug in the at76_get_op_mode function - a variable in that function was changed to a pointer, but a place where that variable was used was not changed to go with it. The attached one-line patch fixes that - which then enables firmware to download okay.

Note that upstream have also made the same trivial fix - 2.6.29-rc8 has it corrected.

HOWEVER, I still can't get the card working yet - its just moved on past firmware loading to other issues that I have yet to resolve.

BUT I NOTE that in the upstream (i.e. mainline 2.6.29-rc8) tree, they also seem to have reverted a fairly major change originally introduced in 2.6.29 from ieee80211 to mac80211. I suspect my new problems are related to this. So I will try (not today though!) saucing up my at76_usb files to reflect upstream 2.6.29-rc8.

Alternative one could ask why the Ubuntu sauce for a 2.6.28 tree is trying to back-port 2.6.29 code for this driver. If we just stuck with whats in upstream (for 2.6.28) then we would probably be fine, as indeed Claudio's tests suggest.

Revision history for this message
KarlRelton (karllinuxtest-relton) wrote :

I can confirm that by replacing in drivers/staging/at76_usb the files at76_usb.c and at76_usb.h with those from the mainline 2.6.29-rc8 tree, compiling (using this driver rather than ubuntu/misc/wireless) the card does work.

Tim Gardner (timg-tpi)
Changed in linux (Ubuntu):
assignee: apw → timg-tpi
status: Incomplete → In Progress
Revision history for this message
Tim Gardner (timg-tpi) wrote :
Changed in linux (Ubuntu):
milestone: none → ubuntu-9.04
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (3.5 KiB)

This bug was fixed in the package linux - 2.6.28-11.38

---------------
linux (2.6.28-11.38) jaunty; urgency=low

  [ Brad Figg ]

  * When AppArmor is configured, securityfs must be as well.
    - LP: #344370
  * ARM: Enable AA with SECURITYFS for imx51
    - LP: #344370

  [ Bryan Wu ]

  * Add 3 missing files to prerm remove file list
    - LP: #345623

  [ Daniel T Chen ]

  * SAUCE: (drop after 2.6.28) Don't trust hw-ptr blindly
    - LP: #330814
  * SAUCE: (drop after 2.6.28) Apply further pcm_lib updates for hw_ptr
    - LP: #330814

  [ Ike Panhc ]

  * Copy header files for various kernel media driver
    - LP: #322732

  [ Tim Gardner ]

  * Revert "Fix the VFP handling on the Feroceon CPU"
    Only applied to mv78xx0 ARM flavour.
  * Enabled drivers/staging/at76_usb
    - LP: #152626

  [ <email address hidden> ]

  * SAUCE: ipw2200: Enable LED by default
    - LP: #21367
  * SAUCE: wistron_btns: support Prestigio Wifi RF kill button over suspend
    - LP: #346586

  [ Upstream Kernel Changes ]

  * Build fix for __early_pfn_to_nid() undefined link error
  * Fix misreporting of #cores as #hyperthreads for Q9550
  * eventfd: remove fput() call from possible IRQ context
  * S390: __div64_31 broken for CONFIG_MARCH_G5
  * ALSA: Fix vunmap and free order in snd_free_sgbuf_pages()
  * ALSA: mixart, fix lock imbalance
  * ALSA: pcm_oss, fix locking typo
  * ALSA: hda - Fix DMA mask for ATI controllers
  * ALSA: hda - Workaround for buggy DMA position on ATI controllers
  * ALSA: opl3sa2 - Fix NULL dereference when suspending snd_opl3sa2
  * nfsd: nfsd should drop CAP_MKNOD for non-root
  * NFSD: provide encode routine for OP_OPENATTR
  * dm ioctl: validate name length when renaming
  * dm io: respect BIO_MAX_PAGES limit
  * dm crypt: fix kcryptd_async_done parameter
  * dm crypt: wait for endio to complete before destruction
  * ata_piix: add workaround for Samsung DB-P70
  * V4L/DVB (10218): cx23885: Fix Oops for mixed install of analog and
    digital only cards
  * thinkpad-acpi: fix module autoloading for older models
  * Add '-fwrapv' to gcc CFLAGS
  * Move cc-option to below arch-specific setup
  * USB: storage: Unusual USB device Prolific 2507 variation added
  * USB: Add Vendor/Product ID for new CDMA U727 to option driver
  * USB: option.c: add ZTE 622 modem device
  * USB: Add device id for Option GTM380 to option driver
  * USB: Option: let cdc-acm handle Sony Ericsson F3507g / Dell 5530
  * USB: Updated unusual-devs entry for USB mass storage on Nokia 6233
  * USB: unusual_devs: Add support for GI 0431 SD-Card interface
  * USB: serial: add FTDI USB/Serial converter devices
  * USB: serial: ftdi: enable UART detection on gnICE JTAG adaptors
    blacklist interface0
  * USB: serial: new cp2101 device id
  * USB: usbtmc: fix stupid bug in open()
  * USB: usbtmc: add protocol 1 support
  * USB: usbfs: keep async URBs until the device file is closed
  * USB: EHCI: expedite unlinks when the root hub is suspended
  * USB: EHCI: Fix isochronous URB leak
  * powerpc: Remove extra semicolon in fsl_soc.c
  * menu: fix embedded menu snafu
  * Linux 2.6.28.9
  * Add '-fwrapv' to gcc CFLAGS
    - LP: #348015
  * Move cc-option to below arch-s...

Read more...

Changed in linux:
status: Fix Committed → Fix Released
Revision history for this message
Claudio (der-claudio) wrote :

Great, it simply works now! :-D

Feedback: I've just booted the 9.04 release and am using my at76 adapter successfully.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.