-
Notifications
You must be signed in to change notification settings - Fork 196
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
Pinebook Pro support #105
Comments
Can we try to use the generic uboot and kernel for this? I believe upstream uboot can run this machine |
If that's possible, absolutely. The kernel still needs a few patches, but is very close to mainline |
upstream uboot supporting the device does not allow to build a "generic" uboot. |
@xtraeme I do have the hardware here and am willing to test stuff, but I have no experience packaging things like the linux kernel, so your help is appreciated! A lot of the work done by the manjaro people can be used, like https://gitlab.manjaro.org/manjaro-arm/packages/core/linux-pinebookpro/tree/master for example, so it's mostly a job of "translating" stuff from their PKGBUILDs to our templates |
I've already been playing around with a simple rootfs install by replacing the root partition of the default debian image, so it's running their kernel and uboot right now. It booted just fine out of the box, but I did have to copy the wifi firmware to get wifi to work. Maybe we could make a pbp-firmware package like the one for the rpi3? That said, I should be able to test most things, but I'm not great at packaging, and stuff like configuring kernels and uboot is probably beyond me. |
I don't have any packaging knowledge, but I have a pbp and would be willing to offer my services to get void running on it. |
I think we don't lack testers, we mostly lack someone with packaging experience and time who is interested in working on this. I have a bit of experience and am certainly interested, but my schedule is pretty packed right now.. |
I can do the packaging. I'm also pretty busy right now, but I hope to find some time to work on that over the weekend. |
would really like to see this happen, i only have packaging experience with arch though. i have a lot of free time coming up, like 2 months free time for reasons and PBP is my favorite new toy, i will learn and help maintain if someone points me in the right direction. |
I just pushed WIP to 'pbp' branch on my forks:
I'm now working on packaging pinebookpro-uboot. |
you know, there is already void-linux/void-packages#17672 |
Also, we don't want a 4.4 kernel, it won't work with panfrost and the proprietary libmali which works with 4.4 doesn't work with modern userlands (and if you hack around it it still works poorly) |
From what I read so far, mainline kernel still doesn't support some features, e.g. suspend/resume. My plan is to initially use same version as official (factory) build and upgrade to mainline kernel as soon as it becomes feature complete. |
Suspend/resume may not work, but accelerated graphics not working is worse. You can use s2idle for suspend for now, which works. |
Assuming the kernel @renatoaguiar packaged is the same one I copied from the default debian (I can confirm they are both version 4.4.202): I am currently unable to launch any DE or WM both for wayland and x11 (I tested XFCE, KDE on both and Sway). I believe it is an issue with dbus because it seems NetworkManager doesn't work either (I normally use connman so I hadn't noticed before), but runit reports dbus as up, and I can't find any errors with socklog. I haven't tried a 5.4 or 5.5rc kernel from Manjaro yet because I haven't got those to boot yet, and I don't have a working UART cable to see what's wrong. In any case, it might be worth looking into. |
Wayland won't work on 4.4, except weston fbdev. Sway needs drm, and for that you need libmali (with weston you might be able to get away with pixman), and libmali does not expose enough of libgbm to have weston-drm/sway working. Out of curiosity, I set up proprietary libmali and went to make a preload library to stub out the missing libgbm calls, and got far enough to launch weston and sway with drm, but EGL still does not work. In X11, you will not get acceleration either, since GLAMOR requires EGL, which does not work. So yeah, unaccelerated fbdev or at most drm with llvmpipe is best you will get with the 4.4 kernel. Use 5.5-rc7 or 5.4 from the manjaro tree and panfrost if you want accel of any kind. |
Ah, that probably explains why KDE was complaining about $DISPLAY not being set. I didn't know about fbdev. I'm learning new things by the minute. In that case, I'll try to get a more recent kernel to run after I fix my UART cable. |
I updated the top post with the WIP stuff that happened so far. I think going with a 4.4 kernel doesn't make sense, since mainline is so close to being feature complete. I'm using the manjaro build at the moment and it works definitely good enough for me. |
Firmware for the mainline kernel is here: https://gitlab.manjaro.org/tsys/pinebook-firmware/ . I pushed 5.5 to the PR linked in the top comment, but have yet to test it. |
I'm using 5.5-rc7-panfrost-fixes branch and it works ok - I have not checked which branch your PR is based on now but you should use that one Btw, I talked to the pine64 folks at fosdem yesterday and showed off mine with void on it a little, turns out at least with the 5.5 kernel we have the best battery life of all distros, nothing else comes close :P (i get 16+ hrs with low brightness and wifi and some slight usage like irc and so) |
I was checking the latest news and It turns out @q66 was right from the beginning :) Mainline kernel support is progressing faster than I initially thought, so I'll be focusing now on verifying the existing kernel package from @CameronNemo and packaging whatever is still missing. |
I just finished compiling @CameronNemo 's kernel, and looking at the commit referenced in the template, it is the head of the v5.5 branch of manjaro's kernel. That said, it boots just fine and sway seems to work, although scrolling in Wayland-native firefox is a bit laggy. Is there any way for Wayland to check if it's using software rendering? As far as I can tell glxinfo is only accurate for X11 and XWayland. XWayland firefox works just fine and mesa is installed. I'll test some other DE's later this week. |
I just added pinebookpro-uboot to https://github.com/renatoaguiar/void-packages/tree/pbp. It still needs some cleanup, but I was good enough to generate a bootable image from https://github.com/renatoaguiar/void-mklive/tree/pbp. @CameronNemo could you rename your linux-pinebook-pro to pinebookpro-kernel, so it matches naming convention used on kernels for other platforms? |
pinebookpro-uboot: void-linux/void-packages#19196 |
I tried @renatoaguiar's build scripts. Just for anyone else that wants to try this: clone https://github.com/renatoaguiar/void-packages and run Run Then, clone https://github.com/renatoaguiar/void-mklive and run Next, we run Finally, to generate the img, I ran: I burned it to my eemc and it works! It's 4 am and I have been up since 7am so I will do further testing in the morning. Thanks for your work. =) If anyone wants me to test anything, please let me know. |
Thanks for trying that out and posting instructions :)
wpa_supplicant for aarch64 is available in official repos. You don't need to build it locally.
I didn't have to specify any extra packages in mkplatformfs. At least pinebookpro-base and wpa_supplicant are being installed automatically as part of pinebookpro platform, so you shouldn't need to list them in '-p'.
I haven't tried booting from emmc yet. Good to know that it works too :) |
So, to summarize: We have WIP stuff for everything now, we can use that to actually build images that work too, we just need to get the stuff merged now. Some thing have already gotten PRs, for the rest that still needs to be done. I updated the issue description, have I missed something there? Do we have something that's merged already? |
void-mklive: #109 |
pinebookpro-base: void-linux/void-packages#19216 |
@renatoaguiar So I installed void on the emmc but I changed my fstab in a way that it void failed to boot. Unfortunately, this failure to boot is not visible to the user. I looked to flash manjaro to an sd card and boot from it to fix the issue. However, the uboot on void doesnt prioritize booting from the sdcard before emmc like on most distros for pinebook pro. This is an important bug that needs to be fixed before these pull requests can be merged. I fixed my issue by following the advice here: https://forum.pine64.org/showthread.php?tid=8790 |
Hi all, I have a PR to update to U-Boot to the 2020.10 release: void-linux/void-packages#21199 |
I had an issue with some firmware blobs missing, so the wifi didn't work correctly when I ran the voidlinux image on my pinebook pro. The firmware came from here: https://gitlab.manjaro.org/manjaro-arm/packages/community/ap6256-firmware |
Awesome work! Thanks to everyone involved in this project. I really enjoy the Pinebook Pro and Void Linux is one of my favorite distros! I have a question regarding fde. I know how to install Void on x86 with lvm/fde but I just can't get it to work on the Pinebook Pro. I've tried moving files from the image after setting up lvm with unencrypted boot following the steps mentioned. I've tried so many combinations and I'm lost. I feel like I'm missing something important in this little "guide". Would you or someone else mind explaining this a little more in depth? Like a small howto would be very appreciated. Sorry if I'm missing something obvious here but I think this is also a great way to learn. Thnx and take care all! |
@snufkin99 The relevant parts for fde are in the luks, fstab and boot_scr functions (just look for these words, the function names are not exactly that). Also ensure to have the packages dracut, lvm2 (if using lvm) and cryptsetup installed. My email is on the website that is linked on my gitlab profile, that might be a better way to figure out communications without spamming the issue here : ) |
@jcgruenhage 12/12 are done on this ticket, are there remaining work items you'd like it kept open for? |
@the-maldridge yeah, sorry, haven't updated this ticket in a while. Ideally I'd like to see images on the download site, added that to the list. Does that sound okay to you, or would you prefer having the issue closed as it is right now? |
I'm experiencing kernel oops's in the pinebookpro-kernel 5.10.35 that prevent void from being usable. They usually trigger when the cpu/disk is under load, and I've reproduced this on both a usb root device as well as the emmc. Has anyone else seen this?
|
I still was using u-boot from my previous debian installation. Using the void package's u-boot on my emmc seems to have resolved this. |
Are the final images going to be generated? |
I wanted to wait until uboot has a version released that supports initialising the display panel and allow for some crude boot menu. Afaik 2021.07 should support that. (And maybe also fixup or default non pinebook pro kernel config to work fine on a pbp). So maybe August, maybe a bit later. |
@Johnnynator have you by chance tried a U-Boot with ATF with the suspend patch? (https://review.trustedfirmware.org/c/TF-A/trusted-firmware-a/+/9616) I have been meaning to give it a spin, but have not had much time. |
Re uboot: we should pribably fix that it breaks customized uboot stuff on each update: my luks encrypted pbp refuses to boot because I forgot to fix that after an upgrade. Easy-ish to fix, but I'll have to whip out a live system for that again |
Yeah, hardcoding the bootargs in the uboot kernel hook is bad. I currently use u-boot-menu, which just reuses the bootargs if the booted system. Should probably also just noticed, why do we even hardcode the Mac address in the uboot image |
I would be glad to see void just ship u-boot-menu by default for the PBP. Much cleaner, easier to understand and customize. |
If the latest u-boot has display support, then using u-boot-menu is probably the best thing to do. I do remember an oddity with u-boot's extlinux.conf parsing where the timeout value is evaluated as tenths of a second for some reason, and if the value was less than 10 then it was interpreted as "no timeout", meaning your computer was effectively hung if you had no display or serial console to proceed with. Also, last I checked, the install.d script in the u-boot-menu package uses some broken logic for figuring out the boot and root filesystems, and uses PARTUUID instead of UUID on the kernel cmdline, which is dubious. I have a fixed version of the script, but I haven't used the PBP in a long time so I haven't updated the package. |
Yeah, the u-boot-menu script would need some more work. (I only ever fixed it to not break on dash as sh). As alternative using grub or refind might even give a more user friendly (and familiar) interface, and are more tested than half broken extlinux generators named u-boot-menu :). And yes 2021.07 has working display support, but I need to investigate where my builds (also with 2021.04) fail to boot our kernels, |
Not seeing any handling for root at all. Looks like you inherited it from the PBP specific kernel script:
u-boot-menu does have some weird logic for /boot, but the logic seems to work. I guess it could be simplified a bit (e.g. just check if
Well feel free to shoot your changes over. I would be curious about what is broken. I don't doubt that there are edge cases not covered, but for the images created by void-mklive it seems to do alright. |
Ah you're right, I got that mixed up sometime in the last while. I'll take a look at all the scripts again when I pull out my PBP again. |
As for the uboot supporting visual boot and suspend to ram, you might consider using tow boot. I have been using this fork on my pinebookPro for a while and it works well. |
@user18130814200115-2 have you confirmed that it works with suspend to RAM? I have tried to get s2ram working and failed. |
I managed to get s2r working a while back on ArchlinuxARM with manjaro 5.13.? kernel. The visual boot works great though, it displays useful information and has a bootmenu which can also boot from usb. Generally an improvement on das uboot IMO edit: clairty |
would be nice to get void-linux/void-packages#46563 merged and include support for it in #384 |
This issue tracks progress towards a usable voidlinux image for the Pinebook Pro. Currently, we can already build a working image
How to read the list: A checked box means that the work is done and merged, an unchecked box with a PR linked means that this is basically done, but not merged yet.
The text was updated successfully, but these errors were encountered: