PDA

View Full Version : [all variants] [SOLVED] New kernel driver for the BCM5974 touchpad (Macbook Air, Penryn)



Pages : 1 [2]

kosumi68
November 10th, 2008, 10:23 AM
The hardware problem only showed in linux.



Bus 003 Device 003: ID 0409:005a NEC Corp. HighSpeed Hub


Don't recognize this one. Is it external? It would also be interesting to see the full usb listing if the 05ac:0230 device after the failure.


sudo lsusb -vvv -d 05ac:0230

ichekryg
November 10th, 2008, 08:54 PM
[22434.976158] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[22434.976171] usb 6-2: USB disconnect, address 77
[22435.352199] usb 6-2: new full speed USB device using uhci_hcd and address 78
[22435.543522] usb 6-2: configuration #1 chosen from 1 choice
[22435.553705] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input162
[22435.601302] input,hidraw1: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[22436.060895] hidraw2: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[22436.070403] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input163
illyac@illya-laptop:~$ sudo lsusb -vvv -d 05ac:0230
[sudo] password for illyac:

Bus 006 Device 080: ID 05ac:0230 Apple, Inc.
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 8
idVendor 0x05ac Apple, Inc.
idProduct 0x0230
bcdDevice 0.70
iManufacturer 1 Apple, Inc.
iProduct 2 Apple Internal Keyboard / Trackpad
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 84
bNumInterfaces 3
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xa0
(Bus Powered)
Remote Wakeup
MaxPower 40mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 1 Boot Interface Subclass
bInterfaceProtocol 1 Keyboard
iInterface 3 Apple Internal Keyboard
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.11
bCountryCode 33 US
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 156
Report Descriptors:
** UNAVAILABLE **
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x000a 1x 10 bytes
bInterval 8
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 0 No Subclass
bInterfaceProtocol 0 None
iInterface 4 Touchpad
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.11
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 27
Report Descriptors:
** UNAVAILABLE **
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 2
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 2
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 1 Boot Interface Subclass
bInterfaceProtocol 2 Mouse
iInterface 4 Touchpad
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.11
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 52
Report Descriptors:
** UNAVAILABLE **
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x84 EP 4 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0008 1x 8 bytes
bInterval 8
Device Status: 0x0000
(Bus Powered)

ichekryg
November 10th, 2008, 09:31 PM
< The hardware problem only showed in linux.
I think i am able to verify and confirm that this issue due to the faulty hardware (as described in http://ubuntuforums.org/showpost.php?p=5286529&postcount=27)

Is there any fix for this on the linux side?

kosumi68
November 10th, 2008, 10:10 PM
< The hardware problem only showed in linux.
I think i am able to verify and confirm that this issue due to the faulty hardware (as described in http://ubuntuforums.org/showpost.php?p=5286529&postcount=27)



Thanks for the output. I compared it to the standard layout - I wanted to make sure nothing odd was going on with the usb interface mapping. It all looks normal. Seems you were unlucky to get one of the flaky machines :-(

[QUOTE]
Is there any fix for this on the linux side?


I will have a look at possible recovery options in the driver, but it does not look promising. Closing and reopening the device might do it as a temporery fix, but as long as X is running, this does not happen without force. You can reload the driver to get it running again


sudo rmmod bcm5974; sudo modprobe bcm5974 debug=3

kosumi68
November 10th, 2008, 10:24 PM
I edited the last post; running with debug=3 will give an additional bit of crucial information as to why the drive does not recover properly. If you would like to run with that option for or a while, and when the problem occurs, report a good chunk of your dmesg, it would help.

Just to make sure what the symptoms are: first you have no problems, then suddenly something stops working. Frozen mouse? No multi-touch? A detailed description of the actual symptoms will also help.

Thanks!

ichekryg
November 12th, 2008, 03:46 PM
The issue manifests itself with intermittent interrupts in keyboard responsiveness. For example, when i type all the sudden keyboard stops working, pressing any buttons has no effect what-so-ever. This lasts about a second or two, then it resumes back to normal. I don't use touchpad much (external mouse), so i didn't test the touchpad responsiveness. Again, the issue lasts about sec or two, so by the time i've realized i have an issue, it is gone. The issue can start (and usually does) right from the logon screan; i.e. i can detect keyboard malfunction while typing my user name/password.

Here is the dmesg before bcm reload (issue already detected):
[ 537.320309] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[ 537.320329] usb 6-2: USB disconnect, address 6
[ 537.425208] bcm5974: bcm5974: could not read from device
[ 537.696202] usb 6-2: new full speed USB device using uhci_hcd and address 7
[ 537.882815] usb 6-2: configuration #1 chosen from 1 choice
[ 537.892955] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input22
[ 537.933290] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 538.072301] usbhid: ctrl urb status -75 received
[ 538.073803] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 538.075718] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input23
[ 538.179387] bcm5974: bcm5974: could not read from device
[ 538.179405] bcm5974: mode switch failed
[ 538.312110] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[ 538.312131] usb 6-2: USB disconnect, address 7
[ 538.660214] usb 6-2: new full speed USB device using uhci_hcd and address 8
[ 538.855360] usb 6-2: configuration #1 chosen from 1 choice
[ 538.866470] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input24
[ 538.924537] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 539.374466] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 539.379134] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input25

this is where i reloaded bcm driver

[ 634.741581] usbcore: deregistering interface driver bcm5974
[ 634.827952] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input26
[ 634.868159] usbcore: registered new interface driver bcm5974
[ 634.930871] bcm5974: switched to wellspring mode.
[ 634.965870] bcm5974: switched to normal mode.
[ 634.981901] bcm5974: switched to wellspring mode.
[ 635.000876] bcm5974: switched to normal mode.
[ 635.031960] bcm5974: switched to wellspring mode.
[ 635.049941] bcm5974: switched to normal mode.
[ 635.083929] bcm5974: switched to wellspring mode.
[ 635.097916] bcm5974: switched to normal mode.
[ 635.122908] bcm5974: switched to wellspring mode.
[ 722.824246] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[ 722.824271] usb 6-2: USB disconnect, address 8
[ 722.827901] bcm5974: bcm5974: button urb failed: -19
[ 722.940250] bcm5974: bcm5974: could not read from device
[ 723.196201] usb 6-2: new full speed USB device using uhci_hcd and address 9
[ 723.380065] usb 6-2: configuration #1 chosen from 1 choice
[ 723.388174] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input27
[ 723.437504] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 723.896531] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 723.905816] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input28
[ 724.079285] bcm5974: switched to wellspring mode.
[ 724.121275] bcm5974: switched to normal mode.
[ 724.146273] bcm5974: switched to wellspring mode.
[ 724.173253] bcm5974: switched to normal mode.
[ 724.204359] bcm5974: switched to wellspring mode.
[ 724.235357] bcm5974: switched to normal mode.
[ 724.260258] bcm5974: switched to wellspring mode.
[ 789.040248] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[ 789.040270] usb 6-2: USB disconnect, address 9
[ 789.041784] bcm5974: bcm5974: trackpad urb failed: -19
[ 789.148258] bcm5974: bcm5974: could not read from device
[ 789.420180] usb 6-2: new full speed USB device using uhci_hcd and address 10
[ 789.608922] usb 6-2: configuration #1 chosen from 1 choice
[ 789.620088] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input29
[ 789.684297] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 790.127080] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 790.134937] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input30
[ 790.335172] bcm5974: switched to wellspring mode.
[ 790.366151] bcm5974: switched to normal mode.
[ 790.411247] bcm5974: switched to wellspring mode.
[ 790.430234] bcm5974: switched to normal mode.
[ 790.455228] bcm5974: switched to wellspring mode.
[ 790.470210] bcm5974: switched to normal mode.
[ 790.495198] bcm5974: switched to wellspring mode.
[ 790.509193] bcm5974: switched to normal mode.
[ 790.536168] bcm5974: switched to wellspring mode.
[ 810.120273] hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[ 810.120295] usb 6-2: USB disconnect, address 10
[ 810.123277] bcm5974: bcm5974: button urb failed: -19
[ 810.249303] bcm5974: bcm5974: could not read from device
[ 810.523722] usb 6-2: new full speed USB device using uhci_hcd and address 11
[ 810.712368] usb 6-2: configuration #1 chosen from 1 choice
[ 810.721539] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input31
[ 810.774794] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 811.229061] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
[ 811.230962] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input32
[ 811.358618] bcm5974: switched to wellspring mode.
[ 811.393622] bcm5974: switched to normal mode.
[ 811.434612] bcm5974: switched to wellspring mode.
[ 811.449004] bcm5974: switched to normal mode.
[ 811.474579] bcm5974: switched to wellspring mode.
[ 811.488582] bcm5974: switched to normal mode.
[ 811.522576] bcm5974: switched to wellspring mode.
[ 811.536568] bcm5974: switched to normal mode.
[ 811.563772] bcm5974: switched to wellspring mode.

kosumi68
November 12th, 2008, 08:17 PM
From the logs, and from your statements, the trackpad has not even been involved in the tests. It seems there is nothing wrong here, except for the hardware problem.

ichekryg
November 12th, 2008, 08:58 PM
Not sure if this helps or not, but here is another observation:
Steps:
1. boot up
2. log on
3. tail -f /var/log/messages
4. don't do anything at all (no typing, scrolling, etc)
Result:
Issue occurs on its own (ot-of-the-blue).
dmesg:
Nov 12 14:54:28 mpb kernel: [ 871.872340] usb 6-2: USB disconnect, address 24
Nov 12 14:54:28 mpb kernel: [ 872.264133] usb 6-2: new full speed USB device using uhci_hcd and address 25
Nov 12 14:54:28 mpb kernel: [ 872.452113] usb 6-2: configuration #1 chosen from 1 choice
Nov 12 14:54:28 mpb kernel: [ 872.472953] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input56
Nov 12 14:54:28 mpb kernel: [ 872.517071] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:28 mpb kernel: [ 872.562230] usbhid: ctrl urb status -75 received
Nov 12 14:54:28 mpb kernel: [ 872.562443] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:28 mpb kernel: [ 872.564533] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input57
Nov 12 14:54:28 mpb kernel: [ 872.620351] usb 6-2: USB disconnect, address 25
Nov 12 14:54:29 mpb kernel: [ 873.029082] usb 6-2: new full speed USB device using uhci_hcd and address 26
Nov 12 14:54:29 mpb kernel: [ 873.226966] usb 6-2: configuration #1 chosen from 1 choice
Nov 12 14:54:29 mpb kernel: [ 873.241399] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input58
Nov 12 14:54:29 mpb kernel: [ 873.284356] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:29 mpb kernel: [ 873.370211] usbhid: ctrl urb status -75 received
Nov 12 14:54:29 mpb kernel: [ 873.370354] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:29 mpb kernel: [ 873.375055] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input59
Nov 12 14:54:29 mpb kernel: [ 873.608203] usb 6-2: USB disconnect, address 26
Nov 12 14:54:30 mpb kernel: [ 873.972422] usb 6-2: new full speed USB device using uhci_hcd and address 27
Nov 12 14:54:30 mpb kernel: [ 874.160422] usb 6-2: configuration #1 chosen from 1 choice
Nov 12 14:54:30 mpb kernel: [ 874.168939] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.0/input/input60
Nov 12 14:54:30 mpb kernel: [ 874.213203] input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:31 mpb kernel: [ 874.676450] hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2
Nov 12 14:54:31 mpb kernel: [ 874.678631] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb6/6-2/6-2:1.2/input/input61

kosumi68
November 12th, 2008, 09:33 PM
Yep, that is how the hardware problem establishes itself. Getting the machine in for repairs might be your best option.

bristoljim
November 20th, 2008, 04:47 PM
Hi, I'm trying to find the sources for bcm5974-dkms but am having no joy.

Have tried bzr branch lp:~rydberg/+junk/bcm5974-dkms but it's saying its not a branch.

I'm running Debian Lenny (2.6.26 + mactel patches), not Ubuntu, but http://web.comhem.se/rydberg/Bits/ directs me here as the forum thread for bcm5974-dkms.

# uname -a
Linux baleal 2.6.26-mactel #1 SMP PREEMPT Wed Nov 19 11:55:51 GMT 2008 x86_64 GNU/Linux

My aim is to get (at least) two finger scroll working on my MacBook Pro 4,1 Penryn. Any help much appreciated.

_mario_
November 20th, 2008, 06:25 PM
Hi, I'm trying to find the sources for bcm5974-dkms but am having no joy.
...
My aim is to get (at least) two finger scroll working on my MacBook Pro 4,1 Penryn. Any help much appreciated.

this package, as well as its sources, are available in the mactel repository: http://ppa.launchpad.net/mactel-support/ubuntu/pool/main/b/bcm5974-dkms/.

good luck & ciao,
Mario

kosumi68
November 29th, 2008, 02:12 PM
Hi, I'm trying to find the sources for bcm5974-dkms but am having no joy.


The GIT repository for bcm5974-dkms has been moved to a more permanent address at http://bitmath.org/code/bcm5974-dkms/

Botto
November 30th, 2008, 11:34 AM
Hi, when trying to install the latest version of your driver I get the following error.
E: usbhid-dkms: subprocess post-installation script returned error exit status 2

I'm running x86_64 but when running in a 32 bit edition usbhid installs just fine. Seems to be some issue with 64bit ubuntu.

Any help? Thank you

bristoljim
December 2nd, 2008, 04:08 PM
this package, as well as its sources, are available in the mactel repository: http://ppa.launchpad.net/mactel-support/ubuntu/pool/main/b/bcm5974-dkms/.

good luck & ciao,
Mario

Thanks Mario. Luck I need :)

bristoljim
December 2nd, 2008, 04:09 PM
The GIT repository for bcm5974-dkms has been moved to a more permanent address at http://bitmath.org/code/bcm5974-dkms/

Thanks kosumi68

cornelius2
April 6th, 2009, 06:03 AM
I posted a patch (+ deb package) for bcm5974-dkms to make click-and-drag work with Macbook 5,1:
EDIT (improved version): https://bugs.edge.launchpad.net/mactel-support/+bug/356317

Please test it and let me know where to submit the patch for consideration for upstream inclusion.

Thanks.

ichekryg
June 24th, 2009, 03:51 AM
Yep, that is how the hardware problem establishes itself. Getting the machine in for repairs might be your best option.

Just checking in if there are any changes since my last post in regards to the alternatives to bcm5974.

Thanks for the suggestion to get my machine to repair, however, since this issue does not manifest it self in OsX at all, there is nothing wrong trom the MBP-OsX perspective.

The way i see it, bcm5974 driver keeps unloading and loading, creating unresponsiveness in the keyboard. Since bcm5974 should be dedicated exclusively to the management of the trackpad, why would it cause interrupt in the keyboard functionality?

vanRijn
February 5th, 2010, 02:27 PM
Just to reply to cornelius2's message, I'm using a MacbookPro 5,5 and I need click and drag to work. I'm currently using http://launchpadlibrarian.net/24871974/bcm5974-dkms_1.1.4_all_test.deb and it works great. Anyone know what the status is on getting click+drag working on the newer touchpads?

kosumi68
February 5th, 2010, 05:16 PM
Check out the Multitouch X Driver project at http://ubuntuforums.org/showthread.php?t=1334696.

Maletor
June 6th, 2010, 07:50 PM
I love this project. I really hope we can get tap to click working. It's a tad bit buggy but much better than not being able to use the trackpad. This makes Ubuntu on Mac completely transparent.

It's worth noting that none of this works without the mactel ppa and bcm5974. That should probably be noted in the first post as I followed the instructions and my trackpad stopped working.

Thanks for this driver. Maybe it can be integrated into lucid so we don't have to install this by hand or dig through Google to find this post.

Instead of doing make install I would recommend checkinstall as that's what the ubuntu wiki recommends.

muryoh
June 22nd, 2010, 10:02 PM
Hello ):P
I'm using the new 6.2 Macbook Pro.
For some reason, my trackpad won't work on Gentoo, and I can't figure why. I tried Ubuntu 10.04, and it does work without any tweaking. I don't know why! I do know that when the usbhid module isn't loaded, the trackpad works fine.

I'm not up to date with usbhid or udev, but it does sound like a quirk issue. Could anybody provide me with the tweaks performed on previous releases of Ubuntu to get the trackpad to work fine with usbhid?

Thanks. :p

kosumi68
June 24th, 2010, 10:54 AM
Hello ):P
I'm using the new 6.2 Macbook Pro.
For some reason, my trackpad won't work on Gentoo, and I can't figure why. I tried Ubuntu 10.04, and it does work without any tweaking. I don't know why! I do know that when the usbhid module isn't loaded, the trackpad works fine.

I'm not up to date with usbhid or udev, but it does sound like a quirk issue. Could anybody provide me with the tweaks performed on previous releases of Ubuntu to get the trackpad to work fine with usbhid?

Thanks. :p

Hi, do you use a ramdisk when booting up?

raumkundschafter
July 2nd, 2010, 05:29 PM
i'm havin problems with the trackpad and keyboard on a penryn macbook - due to my dmesg it's propably an issue with the bcm5974 driver...

dmesg output:
...
[176267.592140] apple 0003:05AC:0231.1A2F: hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input1
[176267.594143] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.2/input/input6710
[176267.660056] bcm5974: bcm5974: could not read from device
[176267.660060] bcm5974: mode switch failed
[176267.669053] bcm5974: bcm5974: could not read from device
[176267.669055] bcm5974: mode switch failed
[176267.750533] hub 7-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[176267.750538] usb 7-2: USB disconnect, address 96
[176267.998294] usb 7-2: new full speed USB device using uhci_hcd and address 97
[176268.229152] usb 7-2: configuration #1 chosen from 1 choice
[176268.242485] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.0/input/input6711
[176268.242554] apple 0003:05AC:0231.1A30: input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input0
[176268.259067] usb 7-2: ctrl urb status -75 received

this is on ubuntu karmic - any hints how to hunt this bug are welcome!

just filled the following bug report:
https://bugs.launchpad.net/ubuntu/+bug/601132

kosumi68
July 2nd, 2010, 10:23 PM
i'm havin problems with the trackpad and keyboard on a penryn macbook - due to my dmesg it's propably an issue with the bcm5974 driver...

dmesg output:
...
[176267.592140] apple 0003:05AC:0231.1A2F: hidraw1: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input1
[176267.594143] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.2/input/input6710
[176267.660056] bcm5974: bcm5974: could not read from device
[176267.660060] bcm5974: mode switch failed
[176267.669053] bcm5974: bcm5974: could not read from device
[176267.669055] bcm5974: mode switch failed
[176267.750533] hub 7-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
[176267.750538] usb 7-2: USB disconnect, address 96
[176267.998294] usb 7-2: new full speed USB device using uhci_hcd and address 97
[176268.229152] usb 7-2: configuration #1 chosen from 1 choice
[176268.242485] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.0/input/input6711
[176268.242554] apple 0003:05AC:0231.1A30: input,hidraw0: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input0
[176268.259067] usb 7-2: ctrl urb status -75 received

this is on ubuntu karmic - any hints how to hunt this bug are welcome!

just filled the following bug report:
https://bugs.launchpad.net/ubuntu/+bug/601132

Hi, thanks for the report. I am sorry, but this sounds like a known hardware (usb) problem. You will find references by searching for "ubuntu macbook disabled by hub (EMI?)".

muryoh
July 8th, 2010, 04:56 PM
Hi, do you use a ramdisk when booting up?

I apologize for the long delay, I'm the one asking yet I'm the one forgetting about the post... :(
No, I'm not using a ramdisk.

muryoh
July 19th, 2010, 12:23 PM
ok, got it. Sneaky kernel options did the trick : https://bugzilla.kernel.org/show_bug.cgi?id=14987

Thanks :-)

JonasPetersson
June 6th, 2011, 09:39 AM
Has anyone else started to have problems with this driver recently? Overall it has worked wonders and on the odd occasion it would stop working I'd just toggle to text console rmmod+modprobe and a few seconds after switching back everything was fine again. Yesterday this no longer helped so I tried restarting X - still broken. Note that seemingly any variant of clicking (right left depending on number of fingers - but I've intentionally disabled tapping) still worked, just moving failed. In the end I rebooted and it was fine.

This morning it was the same again (I'm currently using a USB mouse).

Any and all suggestions are welcome. This is on a MacBookPro6,1 upgraded to Natty about a month ago. I've run Ubuntu on it ever since I got it (within a month or so of its release) and the module has never misbehaved before.

Best / Jonas

[Hmm, Seems like a "Heisenbug": I tried adding some debugging to the module and suddenly it worked again! Very annoying. ]

JonasPetersson
June 15th, 2011, 02:55 PM
For the record, it just happened again and this time it stayed broken after i modprobed with debug=8. The situation is identical in that clicking appears to work, but movement hardly ever does anything. The debug flag yields some lines like these in dmesg:
[836847.062151] bcm5974: switched to wellspring mode.
[836847.077168] bcm5974: abs: p: +0255 w: +0015 x: +0402 y: +0396 nmin: 1 nmax: 1 n: 1 ibt: 0
[836847.117028] bcm5974: abs: p: +0255 w: +0015 x: +0402 y: +0396 nmin: 1 nmax: 1 n: 1 ibt: 0
[836850.392018] bcm5974: abs: p: +0255 w: +0015 x: +0978 y: +0159 nmin: 3 nmax: 3 n: 3 ibt: 0
[836850.403021] bcm5974: abs: p: +0255 w: +0015 x: +0981 y: +0158 nmin: 3 nmax: 3 n: 3 ibt: 0

That seems to indicate that report_tp_state() is called with fingers pressed (makes sense considering what I see) and that bcm5974_wellspring_mode() is called with on==true - whether that makes sense is somewhat beyond obvious to me at the moment...

Any and all hints are welcome.

kcleong
June 21st, 2011, 02:57 PM
The synclient command does not work on my Macbook Pro 7,1 using Ubuntu 11.04. When I'm typing on the keyboard the touchpad responds to clicks/movement. I believe I can use syndaemon to disable the touchpad while typing.


$ synclient -m 500
Can't access shared memory area. SHMConfig disabled?
Couldn't find synaptics properties. No synaptics driver loaded?


The bcm5974 diag script:

$ /usr/src/bcm5974-1.1.9/scripts/bcm5974-diagnostics
-----------------------------------------------------------------------
* Kernel version: 2.6.38-8-generic
* Synaptics version: 1.3.99+git20110116.0e27ce3a-0ubuntu12.1
* USB device: Bus 004 Device 002: ID 05ac:0237 Apple, Inc. Internal Keyboard/Trackpad (ISO)
* /lib/modules/2.6.38-8-generic/kernel/drivers/input/mouse/bcm5974.ko: exists
* /etc/modules: bcm5974 no longer explicitly listed, good
* /etc/modprobe.d/options: file not found
* /etc/modprobe.d/bcm5974: no such file, good
* /lib/modules/2.6.38-8-generic/modules.usbmap: maps to bcm5974, good
* bcm5974: module is loaded
* /proc/bus/input/devices: module is registered
Couldn't find synaptics properties. No synaptics driver loaded?


Can anyone point me in a direction to get the synclient working?

philcolbourn
June 22nd, 2011, 11:14 AM
Has anyone else started to have problems with this driver recently? Overall it has worked wonders and on the odd occasion it would stop working I'd just toggle to text console rmmod+modprobe and a few seconds after switching back everything was fine again. Yesterday this no longer helped so I tried restarting X - still broken. Note that seemingly any variant of clicking (right left depending on number of fingers - but I've intentionally disabled tapping) still worked, just moving failed. In the end I rebooted and it was fine.

This morning it was the same again (I'm currently using a USB mouse).

Any and all suggestions are welcome. This is on a MacBookPro6,1 upgraded to Natty about a month ago. I've run Ubuntu on it ever since I got it (within a month or so of its release) and the module has never misbehaved before.

Best / Jonas

[Hmm, Seems like a "Heisenbug": I tried adding some debugging to the module and suddenly it worked again! Very annoying. ]

Similar story for me.

MacBook Pro 4,1 Natty 11.04

I'd say it started a month ago and just got worse over time.
I have found out this:

Apple keyboard and touchpad share a USB port or something like that. Hence we need a mode switch - so I gather.

With touchpad bcm5974 removed, apple keyboard works fine.

With apple keyboard hid_apple removed, touchpad works fine.

With both loaded, both eventually become unusable and my USB hub seems to
reset all the time and xorg loads and unload it's drivers making my situation unworkable.

I too am using a USB mouse.

This morning I thought it might be hardware since with a cold laptop, my machine was usable but as it warmed it got worse and eventually became unusable.

But, on OS-X all is well. So must be a driver issue - perhaps hid_apple?

How can I help?

2.6.38-8-generic #42-Ubuntu SMP Mon Apr 11 03:31:24 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux

modinfo hid_apple
filename: /lib/modules/2.6.38-8-generic/updates/dkms/hid-apple.ko

modinfo bcm5974
filename: /lib/modules/2.6.38-8-generic/updates/dkms/bcm5974.ko

Jun 22 09:16:41 max kernel: [ 1682.040256] usb 7-2: new full speed USB device using uhci_hcd and address 42

Jun 22 09:16:41 max kernel: [ 1682.270631] input: Apple, Inc. Apple Internal Keyboard / Trackpad as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.0/input/input88

Jun 22 09:16:41 max kernel: [ 1682.270931] apple 0003:05AC:0230.0052: input,hidraw1: USB HID v1.11 Keyboard [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input0

Jun 22 09:16:41 max kernel: [ 1682.284471] usb 7-2: ctrl urb status -75 received

Jun 22 09:16:41 max kernel: [ 1682.284678] apple 0003:05AC:0230.0053: hidraw2: USB HID v1.11 Device [Apple, Inc. Apple Internal Keyboard / Trackpad] on usb-0000:00:1d.2-2/input1

Jun 22 09:16:41 max kernel: [ 1682.286701] input: bcm5974 as /devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.2/input/input89

Jun 22 09:16:41 max kernel: [ 1682.290311] hub 7-0:1.0: port 2 disabled by hub (EMI?), re-enabling...

Jun 22 09:16:41 max kernel: [ 1682.290323] usb 7-2: USB disconnect, address 42

Jun 22 09:16:42 max kernel: [ 1682.820394] usb 7-2: new full speed USB device using uhci_hcd and address 43

ad nausea

[ 27965.540] (EE) xf86OpenSerial: Cannot open device /dev/input/event9
Input/output error.
[ 27965.540] (EE) Synaptics driver unable to open device
[ 27965.540] (EE) PreInit returned 11 for "bcm5974"
[ 27965.540] (II) UnloadModule: "synaptics"
[ 27965.540] (II) Unloading synaptics
[ 27965.580] (II) config/udev: removing device Apple, Inc. Apple Internal Keyboard / Tra
ckpad
[ 27965.580] (II) Apple, Inc. Apple Internal Keyboard / Trackpad: Close
[ 27965.580] (II) UnloadModule: "evdev"
[ 27965.580] (II) Unloading evdev
[ 27966.254] (II) config/udev: Adding input device Apple, Inc. Apple Internal Keyboard / Trackpad (/dev/input/event8)
[ 27966.254] (**) Apple, Inc. Apple Internal Keyboard / Trackpad: Applying InputClass "evdev keyboard catchall"
[ 27966.254] (II) Using input driver 'evdev' for 'Apple, Inc. Apple Internal Keyboard / Trackpad'
[ 27966.254] (II) Loading /usr/lib/xorg/modules/input/evdev_drv.so
[ 27966.254] (**) Apple, Inc. Apple Internal Keyboard / Trackpad: always reports core events
[ 27966.254] (**) Apple, Inc. Apple Internal Keyboard / Trackpad: Device: "/dev/input/event8"
[ 27966.280] (--) Apple, Inc. Apple Internal Keyboard / Trackpad: Found keys
[ 27966.280] (II) Apple, Inc. Apple Internal Keyboard / Trackpad: Configuring as keyboard
[ 27966.280] (**) Option "config_info" "udev:/sys/devices/pci0000:00/0000:00:1d.2/usb7/7-2/7-2:1.0/input/input1133/event8"
[ 27966.280] (II) XINPUT: Adding extended input device "Apple, Inc. Apple Internal Keyboard / Trackpad" (type: KEYBOARD)
[ 27966.280] (**) Option "xkb_rules" "evdev"
[ 27966.280] (**) Option "xkb_model" "macbook79"
[ 27966.280] (**) Option "xkb_layout" "us"
[ 27966.280] (**) Option "xkb_options" "lv3:ralt_switch"
[ 27966.357] (II) config/udev: Adding input device bcm5974 (/dev/input/event9)
[ 27966.357] (**) bcm5974: Applying InputClass "evdev touchpad catchall"
[ 27966.357] (**) bcm5974: Applying InputClass "touchpad catchall"
[ 27966.357] (II) Using input driver 'synaptics' for 'bcm5974'
[ 27966.357] (II) Loading /usr/lib/xorg/modules/input/synaptics_drv.so
[ 27966.357] (**) bcm5974: always reports core events
[ 27966.357] (**) Option "Device" "/dev/input/event9"
[ 27966.450] (EE) xf86OpenSerial: Cannot open device /dev/input/event9
Input/output error.

and it repeats every time.

Here is my script to test removing apple keyboard module to test my touchpad driver:

#!/bin/bash
T=60

logger "removing apple keyboard for $T seconds and installing touchpad..."
rmmod hid_apple
modprobe bcm5974
sleep $T
logger "installing apple keyboard and disabling touchpad"
modprobe hid_apple
rmmod bcm5974

philcolbourn
June 22nd, 2011, 03:09 PM
Something simple to try: remove lirc and associated libs.

Why?

My MacBook Pro 4,1 USB hub has keyboard, touchpad and IR device on it.

Maybe lirc is messing up other devices on this bus?

It seems to have worked for me, but it is still early minutes.

JonasPetersson
July 15th, 2011, 02:52 PM
Something simple to try: remove lirc and associated libs.

Why?

My MacBook Pro 4,1 USB hub has keyboard, touchpad and IR device on it.

Maybe lirc is messing up other devices on this bus?

It seems to have worked for me, but it is still early minutes.

Hi Phil, (/me just back from holidays)

Good plan as such and I'm happy that it seems to work for you, but I don't even have lirc installed so it can hardly be the issue in my case. So far it has not showed up again (that is, it has only manifested twice) which makes identifying the cause tricky...

philcolbourn
July 15th, 2011, 04:05 PM
Hi Phil, (/me just back from holidays)

Good plan as such and I'm happy that it seems to work for you, but I don't even have lirc installed so it can hardly be the issue in my case. So far it has not showed up again (that is, it has only manifested twice) which makes identifying the cause tricky...

It was early minutes...

What I know: you need to have pm remove and re-install the bcm5974 module before and after sleep.

Add a file to /etc/pm/config.d that contains this:
SUSPEND_MODULES="bcm5974"

And... don't sleep with LibreOffice/OpenOffice running.

That's it. Something is badly wrong with LibreOffice/Nvidia/trackpad that causes LibreOffice to run slow when refreshing, the bcm5974 module can die and it seems to happen to those with Nvidia module installed.

I can go a whole day without the problem with LibreOffice running, and other days I have to kill LibreOffice and rmmod/modprobe bcm5974 if I forget and leave it running.

cmatts
July 15th, 2011, 09:58 PM
[unbuntu noob]hi, i am trying to install ubuntu v11 narwale on my macbook air 3,2
i made it through about 5 pages of this thread.

my tractpad is almost unusable. keep acting like i did a mouse click and doing unpredictable things generally.

did the driver update on the first page. then started reading all the code tweaks to get it to work (?).

so is there a simple - install this drive solution? or do i need to finish reading the 15pages of trial and error?

thanks.
[/unbuntu noob]

edit: just read this thread.
http://ubuntuforums.org/showthread.php?t=1799460
might just move on and look into a pc laptop or just go back to my old macbook pro that has unbuntu running (seemingly fine)

dfacto
July 28th, 2011, 04:49 AM
Hey all--trying to get this driver working on the new MacBookAir4,2.

I posted at xf86-input-mtrack: The Other Multitouch Trackpad Driver (http://ubuntuforums.org/showthread.php?p=11093861#post11093861) but now I'm wondering if I should have asked here.

dmesg doesn't give any indication of a problem but synclient -l says no driver loaded. I am having trouble trying to isolate who "owns" this problem--this kernel driver or the xorg driver.

Any tips/advice is appreciated.

Thanks!


Update: I made some minor modifications to bcm5974.c to add support for the MacBookAir4,2. The patch is available here (http://www.almostsure.com/mba42/bcm5974-dkms.patch); the deb and all other files (http://www.almostsure.com/mba42/working/) are available as well.

I had some problems getting the driver to load (blacklisting usbhid didn't work) so I ended up using /etc/rc.local as a workaround. Suggestions welcome. (More details can be found in the MacBookAir4,1/2 thread (http://ubuntuforums.org/showpost.php?p=11106203&postcount=59).)

cnuernber
April 28th, 2012, 05:41 PM
To solve:

bcm5974: could not read from device

edit /etc/default/grub
and change:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

to:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i8042.nopnp=1"


This will also make your touchpad settings persistent.

bravegag
April 30th, 2012, 12:37 AM
Hello,

I tried several suggestions like the one on the first page and doesn't work in Ubuntu 12.04. The system update fails and the later installation fails as well.

I have a MBP 5,2 and the touchpad works very badly. For all those desperate just plug any decent mouse and move on. I plugged in the Apple Mighty Mouse and works like a charm with right-click and everything. I also tried Logitech mouses and they work tip top too.

My advice ... "don't get too attached to things" :) be pragmatic and use a viable solution instead.

HTH,
Giovanni