Skip to content

Instantly share code, notes, and snippets.

@then4p
Last active April 20, 2024 09:42
Show Gist options
  • Save then4p/d0579cde2fb7729eddfd28ff4a160930 to your computer and use it in GitHub Desktop.
Save then4p/d0579cde2fb7729eddfd28ff4a160930 to your computer and use it in GitHub Desktop.
Setup steps for Linux on Lenovo 82Y8 Yoga Pro 7 14APH8

Moved here: https://github.com/then4p/yoga-pro-7-14APH8-linux

Linux on the Lenovo 82Y8 Yoga Pro 7 14APH8 (Gen8) with Ryzen 7 7840HS and Nvidia GTX 4050

Finding a distro

Manjaro was the first distro that worked out of the box with the GPU and prime. Tried KDE Neon and EndeavourOS before but both had issues with GPU/Prime. I installed Manjaro with the proprietary GPU drivers and can run applications with prime-run x now.

Additional setup steps on Manjaro

Audio

Connected headphones didn't work. Switching over to pipewire by installing manjaro-pipewire fixes this. Volume control on the speakers didn't work, they were either off or on 100%. Here's the fix: https://askubuntu.com/a/1204558

Since the switch to pipewire, the conf file is in a different location: /usr/share/alsa-card-profile/mixer/paths/analog-output.conf.common

With the Master block added, headphones did not work. I was able to increase the Master volume using alsamix and then stored the settings with sudo alsactl store.

Power management

Per default Manjaro uses the power-profiles-daemon, I found tlp to offer slightly more power savings on battery (maybe 1-2W with same applications open). Performance on mains was unaffected. I've set the CPU power policy up a notch as I didn't notice any worse battery life. You can do that with tlpui or in the tlp.conf: CPU_ENERGY_PERF_POLICY_ON_BAT=balance_performance

TLP breaks powerdevil which let you set the performance profile, that didn't really have a big effect anyway.

Biometric auth

Installed howdy and used with these two links: https://wiki.archlinux.org/title/Howdy

https://gist.github.com/pastleo/76597c6ae8f95bb02982fea6df3a3ade

Fix white flickering after suspend/resume

After suspending the laptop or connecting/disconnecting external displays sometimes one or more displays would flicker white or become completely white with just the cursor moving.

The issue is described here: https://gitlab.freedesktop.org/drm/amd/-/issues/2354

Setting amdgpu.sg_display=0 as additional kernel parameter seems to fix this issue.

TODO

  • Prime is a bit finicky and typical use cases like steam don't automatically select the correct GPU. Also the gamescope microcompositor is currently broken on Nvidia
  • Volume controls with headphones do not work, adjusting 'bass speaker' in alsamixerfixes this. Probably has to do with the 4 channels used in speaker mode
@AboveYou
Copy link

AboveYou commented Jan 4, 2024

Thanks for the good work, your review made me buy the device and I don't regret it.

I fixed the volume control bug today and wrote a small script to automate the process after an update. Thought I leave a link because some folks can make use of it. Check it out here.

@then4p
Copy link
Author

then4p commented Apr 20, 2024

I've moved the tutorial to a repo, since I wanted to add config files for easyeffects Find it here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment