5

I recently bought an HP Envy x360 with a

  • Ryzen 7 3700U processor,
  • 16GB of RAM and a
  • 512GB NVME SSD.

I want to install Linux on it, but both Ubuntu, Manjaro, and plain Arch linux won't boot. I can get to the grub menu, but once I select the option to boot, the screen goes black and nothing happens.

By the way, I'm trying to boot Ubuntu 19.04, Manjaro 18.04, and Arch 08.01.2019 and yes, I've disabled Secure Boot already.

Any ideas? Is it possibly an issue with the kernel version? Or maybe a boot argument I need to pass through grub?

4 Answers4

7

[The below is valid as of Aug 2019. It seems it is valid for systems with the new Ryzen 3000U (not to be confused with various probems on systems with Ryzen 2000U). New HP, DELL and probably Lenovo devices are affected by this BIOS bug. This is bug in BIOS, not Linux kernel. This might be fixed with kernels coming with Ubuntu 19.10]

Yes, I had the same problem with brand new HP ENVY x360 with Ryzen 7 3700U. Thanks to HP ingenious engineering, the BIOS has messed-up ACPI configuration tables.

Note: DO NOT delete pre-installed windows. You will need them to extract ACPI tables from your notebook's BIOS. Because Ubuntu in non-ACPI mode cannot see ACPI tables in BIOS, thus cannot extract them.

1) Simple solution: Boot ubuntu with turned off LAPIC and ACPI support (for me, olny Ubuntu 18.04.0 worked, no other version can boot as it seems. You can try other distro versions with other kernel versions):

  • In your BIOS, enable "Legacy support"
  • With your USB drive, interrupt POST process during HP logo by pressing F9. You should get to the blue Boot BIOS boot devices screen
  • Select "USB Device - 0.00" ( so no UEFI!)
  • You should now get booted to the violet Ubuntu boot screen, with a keyboard icon at the bottom. This is legacy (no UEFI) boot screen.
  • In Ubuntu boot menu, press F6 and change your boot paramenetrs to "nolapic acpi=off i8042.nopnp"

This should boot (and also install) Ubuntu, but "half" of the HW support (including CPU multicore support) is disabled with these settings. Still, it should get your Ubuntu booted and installed at least...

2) Complicated - but preferred and long term - solution (simplified): boot kernel with modified ACPI configuration in order to enable ACPI mode in Ubuntu:

  • In Windows, extract your ACPI tables from BIOS and store them somewhere safe
  • Decompile extracted FACP ACPI config table, modify value "reduced hardware support" from 1 to 0
  • Recompile your modified FACP table back to binary FACP.AML format
  • Create CPIO archive with this FACP.aml and provide it to your initrd kernel.

This should make your kernel boot with modified ACPI configuration, and full ACPI enabled. This is required to use a full potential of the laptop. This trick will also work on kernels 5.x.

It is ok to go for option 1), then once installed on SSD, you can try option 2) and update your installed kernel(s) with modified ACPI configs and remove the "nolapic acpi=off" boot modifiers to see if it worked :)

In detail, the above is discussed here: https://bugzilla.kernel.org/show_bug.cgi?id=203431

Note1: It seems that (probably all?) kernels 5.x have already attached cpio archive with "AuthenticAMD.bin" firmware. This file must be preserved within cpio archive together with you modified FACP.aml, otherwise kernels 5.x will crash booting even with modified FACP.aml.

Note2: Touchscreen and (almost) full ACPI support works on my device ONLY when I have "Legacy support = Enabled" in BIOS and Ubuntu is installed (and booted) in UEFI mode.

Note3: Kernels 5.2.x and newer boot with these modifications too, but RealTek wifi driver support is being re-worked in new kernels now, so not working on these new HP ENVY devices for now...

What works: Almost everything: Ryzen on 4c/8t, temperature monitoring, CPU power governors, touchpad, keyboard, BlueTooth, Wifi, webcam, sound speakers, mic, 3D HW acceleration (yes - gaming!), HDMI video+audio out, HDMI out via USB-C,touchsreen...

What does not work: internal motion sensors (kernel driver is promised by AMD during August), suspend&resume -> ACPI needs more work. I' using hibernation to disk instead...

Let me know if you have issues or need help, I will try to help directly.

(Written from HP Envy x360 15-ds0005 6WE51EA :) )

Boldos
  • 96
  • Thanks for the thorough answer! I'll check this out tomorrow! – SuperTal3 Aug 07 '19 at 01:06
  • 1
    As it seams, the easiest way is to 1) extract ACPI tables using windows. Then 2) install the ubuntu on local SSD with "nolapic acpi=off" mode. Then 3) boot your Ubuntu from local SSD and update your kernel with your modified acpi table. Then 4) remove "nolapic acpi=off" parameters from GRUB boot configuration. After that, 5) enjoy full power of Ryzen 7 + Vega 10 :) – Boldos Aug 08 '19 at 20:22
  • I created my own bootable Ubuntu 19.04 ISO image after all the steps above, when my HP ENVY was working with ACPI (and after some hours of Vega gaming behind me :)). I used Cubic for that: https://launchpad.net/cubic – Boldos Aug 08 '19 at 20:28
  • I have an HP Envy 15m-ds0012dx and I can't even get the thing to boot with bootargs "nolapic acpi=off i8042.nopnp". I do appreciate the response as I'm trying to build a boot ISO with the extracted and patched ACPI tables. Unfortunately, I haven't been able to get this to work either. – James Hemsing Aug 18 '19 at 20:14
  • I have prepared my own ISO for my HP Envy, which I'm actually using now. It is a modified Ubuntu 19.04 image: I used official mainline kernel 5.1.21 for this ISO. This kernel has also new facp.aml table attached to it with ACPI config modifications. On my system it boots & installs. You can download it here: [Webshare.cz] (https://webshare.cz/#/file/22M4124u63/ubuntu-19-04-0-2019-07-28-desktop-amd64-iso). – Boldos Aug 19 '19 at 10:56
  • Having trouble downloading your ISO (it keeps failing). I've tried your steps with Manjaro (see here: https://forum.manjaro.org/t/help-with-hp-envy-x360-15-ds000cto-ryzen-7-3700u/98906/51), but there must be something different about Ubuntu's kernel, since you're reporting a working keyboard, touchpad, and power management. If I can't get your ISO, I'll try this today with the standard Ubuntu 19.04 ISO and report back. – sez11a Aug 22 '19 at 15:34
  • Very sorry to hear that. I created another download with the same iso: [uloz.to] (https://uloz.to/file/EAvBmrAuGKPA/ubuntu-19-04-0-2019-07-28-desktop-amd64-iso) Hope this one works better. For non-working keyboard/touchpad: My updated ACPI table - which is shipped with this ISO - contains two modifications: Parameter "8042 Present on ports 60/64 (V2)" is set to "1", parameter "Hardware Reduced (V5)" is set to "0". The first mod (for 8042 ports) will make keyboard&touchpad visible and working for my kernel, even under ACPI. It is similar to kernel boot option i8042.nopnp on my machine. – Boldos Aug 22 '19 at 19:20
  • 1
    Unfortunately, that download failed too, but thank you for creating it. I went ahead yesterday and performed all these steps with the stock Ubuntu 19.04 ISO, and wound up with keyboard and touchpad not working. I just made the modification to the ACPI table you mentioned in your comment above this one, and the keyboard worked (but no touchpad)! Did you make any other modifications? Thanks for your help! – sez11a Aug 23 '19 at 17:48
  • Well, at the beginning, when I started experimenting with Linux on my device the non-ACPI i8042.. kernel boot option worked for keyboard 100%, for touchpad "sometimes" (i.e. sometimes/after some boots it worked, some other times it did not). Then I realized system can see "Synaptic PS/2 mouse" (or device SYNA3290:01 in ACPI mode) (you can check in /var/log/kern.log or terminal with 'xinput' command) so I believe there is most probably some UEFI/motion sensor/'tablet mode' automation trickery involved? Not sure... – Boldos Aug 24 '19 at 12:00
  • My solution: during those boots when touchpad worked (was 'turned on somehow'), I powered off machine (not rebooted!) from desktop. Somehow the laptop probably remembered the last status of touchpad (if it was on or off) I guess... After that it just works 100% times/boots for me. I cannot troubleshoot it now, since this is no longer reproducible for me :( ***Also: If the ACPI hack works for your device, would you please care to share the device model you are using? :) – Boldos Aug 24 '19 at 12:01
  • 1
    I did a hardware probe of the machine. Here it is: https://linux-hardware.org/?probe=814cd2dd3e

    Touchpad worked as you describe only when booted via USB installer; it never worked after the install.

    – sez11a Aug 26 '19 at 17:08
  • Here is my hw-probe: https://linux-hardware.org/?probe=dfc2d9b353 With regards to touchpad, not sure what else can I do to help :( Is your system installed&booted as UEFI? Also, maybe testing a newer kernel might be worth trying... – Boldos Aug 26 '19 at 18:25
  • Yes; installed and booted UEFI. I'm going to try this procedure again today, using a daily build of the next release (http://cdimage.ubuntu.com/kubuntu/daily-live/current/). – sez11a Aug 27 '19 at 14:10
  • Good luck! 2) Not sure which kernel version these 19.10 isos are using, but beware: as of now, support for our WiFi RTL8822BE does not work in kernels 5.2.* and 5.3.*. This is because a RTL drivers rework is in progress for these kernels and is still unfinished, thus our WiFi is not supported (yet). This is why I'm sticking with latest 5.1.21, which is new enough to have some new AMD APU features, but is old enough not to be affected by this RTL driver re-work :D (https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.1.21/)
  • – Boldos Aug 27 '19 at 16:07
  • Yes; I learned that yesterday. I couldn't install the daily build; grub wouldn't install and boot-repair won't run on the development release. I wound up installing Kubuntu 19.04, used Kernel 5.1, and now I think I've got it to where you have it, though I'm waiting for that elusive sporadic boot where the touchpad works (it happened while I had the USB booted, but not after the install). Thank you very much for your help; I guess we'll both limp along like this until our hardware is fully supported. :-) – sez11a Aug 28 '19 at 19:35
  • Well, you could always try to turn it on manually: A) from terminal "xinput" get the device ID (on my system I will get "↳ SYNA3290:01 06CB:CD4F Touchpad id=11") B) then try "xinput set-prop 11 'Device Enabled' 1". ID is dynamically assigned here. C) Also, you can try booting system to the point where touchpad works and then try the Vulkan 5sec power button press :) (just turn it off). For me the state of the touchpad got remembered and it keeps working from that point on... But not sure if there is a behavioral difference between UEFI/non-UEFI boots in this. – Boldos Aug 30 '19 at 09:56
  • Just FYI: the latest Arch Linux ISO and the latest Manjaro RC9 boot without changes on this machine, and everything is recognized: keyboard, touchpad, power management, etc. There must've either been some distro love or some magic in the 5.2.11 kernel. No ACPI hacks needed. I can only assume this fix will be in Ubuntu 19.10 as well (but it wasn't in the last build I tested). – sez11a Sep 03 '19 at 14:19
  • Yes, kernel 5.2.11 can boot without any mods on my machine too. Anyway, it still has issues connecting to some WiFi networks, so not fully usable for me yet. Also, AMD sensor support (which should cover HP ENVY devices) is planned in some of the upcoming kernel releases, so I'm eagerly awaiting next kernel version(s) :) – Boldos Sep 03 '19 at 14:31
  • I managed to extract the ACPI tables before I killed windows by updating it, it's not quite working yet, I think I missed the part about increasing the vendor ID. Is it OK to put facp.aml in /boot and pass /boot/facp.aml to init ? One of the ACPI guides I saw for a different laptop mentioned that. If not, whats the best way to create the CPIO, can I just copy an existing one and add this file to it (then make grub point at it) ? – Stuart Axon Sep 26 '20 at 02:16
  • I managed to download @Boldos iso and have made a torrent of it magnet:?xt=urn:btih:e39a8790a082ae29c753dd4b5621476a625d6b8c&dn=ubuntu-19.04-acpi-patched-for-HP-ENVY-Ryzen3700u – Stuart Axon Sep 26 '20 at 13:45