New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Patched touchbar driver not working in kernel 6.0 #189
Comments
Yes, I can confirm the provided error but it is possible to easily overcome it as described by the following comment: roadrunner2/macbook12-spi-driver#67 (comment) Still to be published a proper fix upstream to the repository, but at least it is possible quite easily to make it work. |
yeah that's right. I forked it to remove the saving functionality. |
@marc-git I still can't compile it under 6.3.8-200.fc38... Building module: |
I used the macbook12-spi-driver-dkms from the AUR. It uses a patch. |
I can delete that from dkms.conf but it still won't work. |
that patch is not working for me in 6.6.13 |
patch doesn't work for me on Fedora 39 (6.6.14) or openSUSE Tumbleweed (6.7.2). (note however, did work flawlessly on Debian Stable/6.1.0)
perhaps someone smarter than me would know a fix? in a last ditch effort I tried the t2linux fork (https://github.com/t2linux/apple-ib-drv), and I ran into the same issue. |
The build error with .remove is trivial to fix, but for me the touch bar doesn't work with 6.6 regardless. The driver detects it, registers the input device, but the touch bar just stays black. It worked ok on Linux 6.1 with the same driver. It randomly worked twice, but I don't understand why and could not reproduce this. |
Could this be due to |
I don't have usbmuxd running at all. I am now building a 6.1 kernel again to see if something else changed (like accidental deletion of the firmware from the efi boot partition). If things still work with the old kernel I'll try my luck with a bisect. |
With Linux 6.1.76 the touch bar is working with @marc-git 's driver. With 6.4 and 6.6 it doesn't work most of the time. So I have a baseline for bisecting. A problem is that in "bad" kernels it is randomly starting up, and I haven't figured out why - I estimate that it works 10% of the time. So if the touch bar starts up I have to reboot a few times to make sure the kernel revision is really working and not randomly (un)lucky. |
I patched /usr/lib/udev/rules.d/39-usbmuxd.rules according to: Instead of using a new script to fix this issue. That works also. Without the patch it was not lighting up.
I run Arch Linux, which is shipping the latest kernel version.It's been through server 6.6.x versions. It's on 6.7 by now and haven't had any issues with the TouchBar. |
Are you running with just different usbmuxd rules? No home brew spi drivers? |
yes.
just the one from the AUR package, which has a patch build in. So just I deleted the generated stuff from the aur package and did a makepkg again, no errors. It is up to date, I update my system regularly. So in order to get it to work I do:
|
My bisect ended with this kernel commit as the first bad one:
Suffice to say, this doesn't make much sense. Only with some unlucky random side effect would SCSI-related changes break a USB HID device. I'll try to build the source branch of that merge and see if I can reproduce the issue. If that's the case I can bisect over the 142 commits the merge introduced. |
@stefand that took some effort 💪already |
So my previous bisect ended up with a non-sensical commit because the touch bar luckily worked 3 times with a "bad" kernel. On a second attempt I ended up with this commit as breaking the touch bar on my system:
This makes more sense - it talks about T2 macbooks pro. My MacBookPro14,3 has a touch bar, but not a T2 chip. That would also explain why the touch bar driver works fine for some people here. |
Reverting e04955db on a 6.6 kernel makes the touch bar come up reliably. I guess the problem only affects pre T2 macs. Sadly I don't know the USB technical details to figure out how to fix this properly. Since the touch bar driver still lives out-of-tree it will be tricky to get the kernel devs to fix it. I'll try to get the attention of the t2linux people. |
@stefand I have MacBook 14,3 (A1707). In Mac OS System information, under hardware->Controller I see Apple T1 Security-chip. Firmware 14Y910. The AUR patch I use hasn't been updated, checked that too. I do run with the I act like I'm Mac OS trick. Found here. I use rEFInd to be precise, shouldn't matter. Maybe that matters. I boot into Mac OS (Ventura 13.6.4) from time to time too and run the updates in Mac OS. This sometimes updates firmware, could be something too. Though Ventura doesn't receive all the updates anymore. I might be missing something completely here, but I just don't get why it's working on mine, except I'm on 6.7.4-arch-1 kernel version. |
@gjvanderheiden the touch bar works for me occasionally with an unmodified 6.6 kernel. I don't know if this is runtime luck or has something to do with how the kernel and/or driver are built. I tried updating to 6.7, but it doesn't change the behavior. Maybe the presence of usbmuxd influences things in a positive way, at least when the workaround discussed in this bug is used. |
@stefand Any luck with them? |
@marc-git There is no response yet to the bug I filed. |
The patched touchbar driver from @PatrickVerner is no longer working on the latest kernel. The compile error I get is
applespi.c:1810:38: error: invalid application of 'sizeof' to incomplete type 'struct efivar_entry'
Confused why this suddenly became a problem. Anyone want to hazard a guess at a solution?
The text was updated successfully, but these errors were encountered: