Bugzilla – Bug 1189456
Add ashmem and binder drivers
Last modified: 2024-07-19 14:38:44 UTC
Anbox, ReDroid and other Android emulation/abstraction solutions need the ashmem and binder linux drivers. These drivers are part of the mainline kernel since a some time. https://anbox.io/ https://docs.anbox.io/userguide/install_kernel_modules.html https://hub.docker.com/r/redroid/redroid The debian guys are using patches for having these drivers built as modules: https://docs.anbox.io/userguide/install_kernel_modules.html#install-with-in-tree-modules
All those android drivers are built-in only, and that's enough reason to push back for now, unfortunately. The patches to build them as modules look promising, but they have to be upstreamed at first, as we have a policy "upstream first".
And those hackish patches for making modular would be hardly accepted by upstream; there has been already an attempt but failed: https://lore.kernel.org/linux-fsdevel/20180730143710.14413-1-christian@brauner.io
I'm afraid there is a little we can do about this until a proper solution is provided (and merged).
So basically we'll never get WayDroid in the official repositories, then?
Right. It has to be addressed in the upstream at first.
Waydroid does not require any patches, you only need the included module already available in the kernel CONFIG_ANDROID=y CONFIG_ANDROID_BINDER_IPC=y CONFIG_ANDROID_BINDER_DEVICES="binder,hwbinder,vndbinder"
*** Bug 1219258 has been marked as a duplicate of this bug. ***
To repeat the point: as mentioned in comment 1, the problem is that binder stuff is provided only for built-in kernel. That is, even if that's just a matter of a few kconfig knobs, enabling them will bring a potential problem on the kernel core unconditionally, and that's what we can't accept for the default kernel (that can be used for servers and other serious usages). And, allowing binder to be built as modules needs some changes, and this was declined by the upstream. This part has to be addressed in the upstream at first. Meanwhile, building an unofficial kernel with the enablement of binder config is pretty easy. I've set up OBS repos for Tumbleweed and Leap 15.5 kernels with the enablement of binder. Those are found in OBS home:tiwai:kernel:binder-stable and home:tiwai:kernel:binder-sle15-sp5 repos, respectively. http://download.opensuse.org/repositories/home:/tiwai:/kernel:/binder-stable/standard/ http://download.opensuse.org/repositories/home:/tiwai:/kernel:/binder-sle15-sp5/pool/ You can use those kernels instead of the official ones. Those are linked targets, hence they will follow the Tumbleweed and SLE15-SP5 kernel changes and be rebuilt automatically upon each update. Note that the above kernels are unofficial builds, and it means that you'd need to turn off Secure Boot. Give it a try, and let me know if it's still something missing.
(In reply to Takashi Iwai from comment #5) > Right. It has to be addressed in the upstream at first. Do you know where I can track the issue describing what needs to be done upstream? Without it being present in this thread, the rationale for the WONTFIX is missing its most important element.
It was described in comment#1. It should be possible to build Android IPC as "loadable module", not just as build-in module. "CONFIG_ANDROID_BINDER_IPC=m"
And see comment 2.