The ultimate Linux laptop

Published on: 2023-12-26

Well, this is kind of awkward. I wrote a blog post around a year ago where I claimed to have found the perfect Linux laptop. 

It turns out, dear reader, that I lied to you. I was never able to fix the glaring suspend/resume problem that I hinted at in the updates to the article. So, I did what no self-respecting Tinkerer would do after months of troubleshooting: I decided to give up and throw money at the problem, hoping it would go away.

Like the last time, I had a list of must-haves (I really dislike the word "requirements") that the new laptop should bring in order to contend:

Point 1 - AMD based

This was born out of the fact that I have a desktop machine running full AMD (5600x + 6700xt on an AM4 mainboard), which has been working absolutely flawlessly for about 3 years now. I bought it during the pandemic to play Valheim, and it's just been so insanely unproblematic (running Ubuntu) that I hope to mirror that experience for my laptop. The plan is to only have a single computer.

The no NVIDIA part should be obvious

Point 2 - Thunderbolt

I love how you can simply connect your laptop with a docking station and have a desktop replacement with a single wire. USB4 works also (Thunderbolt 4 is basically just USB4 with all features). There's unfortunately some ambiguity around PCIe passthrough in USB4 (vendors don't need to pass PCIe lanes to be USB4 conform). Thankfully, Microsoft (those two words in close proximity, wow) specified that every laptop that wants to be "Windows 11 ready" must expose PCIe lanes via USB4 (this is called "Thunderbolt 3 compatibility"). 

Also, I want to try out an eGPU setup. There's going to be a separate blog post about this, but as a small teaser, I am writing this blog post with a working, hotpluggable eGPU setup :)

Point 3 - powerful and fast

I want to replace my desktop with this laptop. My desktop isn't an insane speed machine by any stretch, but it does compile code pretty fast. Ideally, this laptop can also do that, and even chomp through some games. 

Point 4 - portable, ideally 13.3 inches

Yeah, I like small laptops. For some reason, even though I have been sitting in front of computers for over 20 years now, I still have pretty good eyesight. This means I don't need to go to 15" laptops just yet. This may change in the future when I grow older, but for now, I will enjoy smaller form factors for as long as I can.

Point 5 - no soldered RAM

Okay, at that point, I had to compromise. It turns out there's no LPDDR5-capable machine with SODIMM bars. One reason for that is the low number of pins that are present in SODIMM connectors. Imagine having a 2048-bit memory bus (like they are used on HBM modules) on a SODIMM interface; there's simply nobody who specified such a standard for pluggable SODIMM modules. The LP in LPDDR5 stands for "Low Power," which can't deal with the signal integrity losses of SODIMM connectors. It needs a nice, clean PCB trace without some noisy physical mounting connector. The upside of this is that LPDDR consumes a lot less power than the normal SODIMM-mounted DDR RAM found in other notebooks. By the way, the LPDDR standard is not just DDR with some added specs; it's a completely different specification from DDR and was developed independently.

The laptop I went for in the end has 64GB LPDDR5. I don't foresee me needing to upgrade RAM for a long time.

Point 6 - It shall be chargeable via USBC-PD

Pretty self-explaining, I guess. When traveling (and even at home, if I think about it), I want to have one charger for everything. USBC-PD makes life easy. Probably one of the best technological improvements for me is the unification of charging infrastructure that USBC made possible.

Point 7 - I want a touchscreen

Yeah, I know, this point is a bit weird. But I love how I can lay on the sofa and scroll through a website with the laptop on my chest. It's purely a personal opinion, but touchscreens are awesome. I learned to love them with my older Dell Latitude, which also had one. Once you have one, I am pretty sure you'll find that one situation that makes a touchscreen worth it. It's different for everybody, though.

Point 8 - FullHD (1080p/1200p) screen

I can't stand 4k screens on a tiny form factor such as 13.3". I see pixels only when I look very, very closely. The added strain on the GPU and battery just isn't worth it to me. Also, fractional scaling is nice within most desktop environments under Wayland, but it's not very nice in GRUB or other older textmode interfaces.

Point 9 - ANSI-US (QWERTY) keyboard layout

I love ANSI-US. Easy access to brackets, special characters, and no wasted keys on local language features such as the German umlauts I use those incredibly rarely.

Manufacturer

Frame.Work

I have read many positive things about the Frame.Work laptop, and when I heard that they would offer an AMD version, I was really interested. It is almost an ideal candidate. It's running Coreboot, has an AMD CPU, is repairable, extendable and upgradable (specifically, the "expansion card" system is really nice!). But they don't offer a touchscreen. I thought very long about accepting that drawback and going the Frame.work route - but I couldn't get myself to ignore that one drawback. If they ever offer a touchscreen, I may reconsider.

Dell

I liked my Dell Latitude very much. I looked for a laptop from Dell, but they wouldn't even offer a thin or light 13.3" laptop with 32+GB RAM and an AMD CPU. All their XPS13 are Intel. Added to that, the new XPS13 has some sort of touch-buttons (instead of using the fn toggle + Fx keys), and I like physical buttons. Maybe they work well in practice, but I didn't want to risk it.

For reference, this was the laptop I looked at, which seemed like the best fit for me: https://www.dell.com/de-de/shop/dell-notebooks/xps-13-plus-laptop/spd/xps-13-9320-laptop/cn93352cc

HP

Next manufacturer I looked at was HP. I owned a HP Spectre x360 some time ago and liked it a lot too. They don't exist with AMD CPUs, at least not at the time I looked. The HP Pro x360 435 looked like a potential match, however: https://www.hp.com/de-de/shop/product.aspx?id=816D9EA&opt=ABD&sel=NTB

The only problem was that HP simply doesn't allow configuration of the keyboard. In Germany, you're seemingly forced to buy a German layout. In the end, I decided against it and looked at the third manufacturer.

Lenovo

Now, I try not to buy Chinese. I am wary about the security implications of doing so. I don't like their human rights track record (and yes, I think the US is better in this regard). I think the chinese political system is a threat to the free world.

I even messaged the BSI via email and asked what their opinion is on Lenovo. They weren't very helpful, though, and replied back with a template that stated that I could check their security advisories. I mean, yeah, but still, I had hoped for a more nuanced opinion. Oh well.

Also, as far as I was able to research, all the big American companies have at least some supply chain in China (Even though that's changing). You can't really avoid it, unless you go back in time and use a device which can run Coreboot. Alternatively, you can also go for something like the Talos II - but that's very far outside of my budget (and it's no laptop :)).

If you search for this discussion online, there's a lot of people who aren't worried, or are worried about things I am not worried about. There's lots of argumentation going into the direction that people should just not use Windows and Chrome (I don't use either) if they are so worried, and that smartphones are so much worse (mine isn't, I run GrapheneOS). I feel like this discussion is misdirected; the real Lenovo backdoors (if there are any) are going to be in the embedded controller firmware onboard the laptop, or in the UEFI code. This is something I see discussed very rarely. The only "comforting" thought here is that I really doubt that ex-filtration of data via the internet would be easy to hide in properly firewalled corporate networks. It would make the news pretty fast, if some corporation figured out weird traffic originating from their fleet of Thinkpads. Maybe someday I will try to reverse engineer a Lenovo firmware blob and attempt to answer this question for myself.

In the end, I decided that it's worth at least checking what they are offering (especially since I was able to get Lenovo store access with ~20% discount). I am not complacent here - I still think that the laptop could be backdoor-ed in a way that's hard to detect. I just chose to live with that thought, since I fail to see clandestine extraction methods that wouldn't be noticed in various cooperate environments (perhaps even by me in my heavily segregated VLANs where I regularly check for unknown traffic).

Anyhow, it turns out, they offer a machine that 100% fits what I am after: The Thinkpad Z13 Gen 2.

I could configure it with 7840U, 64GB RAM, touchscreen, and ANSI-US layout (called "Backlit, Black/Arctic Grey with Fingerprint Reader - English (Euro) "). It was also about 300 Euros cheaper than Dell and HP devices, while offering 64GB RAM.

It took quite a while to arrive in Germany (around two weeks). Most of that time was UPS (they have horrible tracking; it's really insanely bad), and it seemed that the laptop was in stock in my configuration.

The laptop

Here are the exact specs:

H/W path Device Class Description ============================================================== system 21JVCTO1WW (LENOVO_MT_21JV_BU_Think_FM_ThinkPad Z13 Gen 2) /0 bus 21JVCTO1WW /0/0 memory 512KiB L1 cache /0/1 memory 8MiB L2 cache /0/2 memory 16MiB L3 cache /0/3 processor AMD Ryzen 7 PRO 7840U w/ Radeon 780M Graphics /0/5 memory 64GiB System Memory /0/5/0 memory 16GiB Synchronous Unbuffered (Unregistered) 7500 MHz (0.1 ns) /0/5/1 memory 16GiB Synchronous Unbuffered (Unregistered) 7500 MHz (0.1 ns) /0/5/2 memory 16GiB Synchronous Unbuffered (Unregistered) 7500 MHz (0.1 ns) /0/5/3 memory 16GiB Synchronous Unbuffered (Unregistered) 7500 MHz (0.1 ns) /0/15 memory 128KiB BIOS /0/100 bridge Advanced Micro Devices, Inc. [AMD] /0/100/0.2 generic Advanced Micro Devices, Inc. [AMD] /0/100/2.2 bridge Advanced Micro Devices, Inc. [AMD] /0/100/2.2/0 wlp1s0 network MT7922 802.11ax PCI Express Wireless Network Adapter /0/100/2.4 bridge Advanced Micro Devices, Inc. [AMD] /0/100/2.4/0 /dev/nvme0 storage WD PC SN740 SDDQMQE-2T00-1201 /0/100/2.4/0/0 hwmon2 disk NVMe disk /0/100/2.4/0/2 /dev/ng0n1 disk NVMe disk /0/100/2.4/0/1 /dev/nvme0n1 disk 2048GB NVMe disk /0/100/2.4/0/1/1 volume 511MiB Windows FAT volume /0/100/2.4/0/1/2 /dev/nvme0n1p2 volume 488MiB EFI partition /0/100/2.4/0/1/3 /dev/nvme0n1p3 volume 1906GiB EFI partition /0/100/3.1 bridge Advanced Micro Devices, Inc. [AMD] /0/100/4.1 bridge Advanced Micro Devices, Inc. [AMD] /0/100/8.1 bridge Advanced Micro Devices, Inc. [AMD] /0/100/8.1/0 /dev/fb0 display Phoenix1 /0/100/8.1/0.1 card0 multimedia Rembrandt Radeon High Definition Audio Controller /0/100/8.1/0.1/0 input23 input HD-Audio Generic HDMI/DP,pcm=3 /0/100/8.1/0.1/1 input24 input HD-Audio Generic HDMI/DP,pcm=7 /0/100/8.1/0.1/2 input25 input HD-Audio Generic HDMI/DP,pcm=8 /0/100/8.1/0.1/3 input26 input HD-Audio Generic HDMI/DP,pcm=9 /0/100/8.1/0.2 generic Advanced Micro Devices, Inc. [AMD] /0/100/8.1/0.3 bus Advanced Micro Devices, Inc. [AMD] /0/100/8.1/0.3/0 usb1 bus xHCI Host Controller /0/100/8.1/0.3/0/3 communication Wireless_Device /0/100/8.1/0.3/0/5 generic Generic USB device /0/100/8.1/0.3/1 usb2 bus xHCI Host Controller /0/100/8.1/0.4 bus Advanced Micro Devices, Inc. [AMD] /0/100/8.1/0.4/0 usb3 bus xHCI Host Controller /0/100/8.1/0.4/0/1 input28 multimedia Integrated RGB Camera: Integrat /0/100/8.1/0.4/1 usb4 bus xHCI Host Controller /0/100/8.1/0.5 multimedia ACP/ACP3X/ACP6x Audio Coprocessor /0/100/8.1/0.6 card1 multimedia Family 17h/19h HD Audio Controller /0/100/8.1/0.6/0 input27 input HDA Digital PCBeep /0/100/8.1/0.6/1 input30 input HD-Audio Generic Mic /0/100/8.1/0.6/2 input31 input HD-Audio Generic Headphone /0/100/8.2 bridge Advanced Micro Devices, Inc. [AMD] /0/100/8.2/0 generic Advanced Micro Devices, Inc. [AMD] /0/100/8.2/0.1 generic Advanced Micro Devices, Inc. [AMD] /0/100/8.3 bridge Advanced Micro Devices, Inc. [AMD] /0/100/8.3/0 generic Advanced Micro Devices, Inc. [AMD] /0/100/8.3/0.3 bus Advanced Micro Devices, Inc. [AMD] /0/100/8.3/0.3/0 usb5 bus xHCI Host Controller /0/100/8.3/0.3/1 usb6 bus xHCI Host Controller /0/100/8.3/0.4 bus Advanced Micro Devices, Inc. [AMD] /0/100/8.3/0.4/0 usb7 bus xHCI Host Controller /0/100/8.3/0.4/1 usb8 bus xHCI Host Controller /0/100/8.3/0.5 bus Advanced Micro Devices, Inc. [AMD] /0/100/8.3/0.6 bus Advanced Micro Devices, Inc. [AMD] /0/100/14 bus FCH SMBus Controller /0/100/14.3 bridge FCH LPC Bridge /0/100/14.3/0 system PnP device PNP0c02 /0/100/14.3/1 system PnP device PNP0b00 /0/100/14.3/2 generic PnP device LEN0071 /0/100/14.3/3 generic PnP device LEN0316 /0/100/14.3/4 system PnP device PNP0c02 /0/100/14.3/5 system PnP device PNP0c01 /0/101 bridge Advanced Micro Devices, Inc. [AMD] /0/102 bridge Advanced Micro Devices, Inc. [AMD] /0/103 bridge Advanced Micro Devices, Inc. [AMD] /0/104 bridge Advanced Micro Devices, Inc. [AMD] /0/105 bridge Advanced Micro Devices, Inc. [AMD] /0/106 bridge Advanced Micro Devices, Inc. [AMD] /0/107 bridge Advanced Micro Devices, Inc. [AMD] /0/108 bridge Advanced Micro Devices, Inc. [AMD] /0/109 bridge Advanced Micro Devices, Inc. [AMD] /0/10a bridge Advanced Micro Devices, Inc. [AMD] /0/10b bridge Advanced Micro Devices, Inc. [AMD] /0/10c bridge Advanced Micro Devices, Inc. [AMD] /0/10d bridge Advanced Micro Devices, Inc. [AMD] /1 power 5B10W51881 /2 input0 input AT Translated Set 2 keyboard /3 input15 input Wacom HID 5385 Pen /4 input16 input Wacom HID 5385 Finger /5 input18 input PC Speaker /6 input19 input ThinkPad Extra Buttons /7 input2 input Power Button /8 input20 input SNSL0028:00 2C2F:0028 Mouse /9 input21 input SNSL0028:00 2C2F:0028 Touchpad /a input3 input Lid Switch /b input4 input TPPS/2 Elan TrackPoint /c input5 input Sleep Button /d input6 input Video Bus

(The output here comes from lshw -short -sanitize btw, since I was asked.) It's an absolute beast in a 13.3-inch form factor.

I read quite a few comments on this laptop before deciding to buy it, and many people weren't sure about the keyboard. I can confidently say that I love it. It's quiet, has very good travel (1.35mm on paper, but feels like much more). Very nice feedback, and it is full-sized (it stretches the complete width of the chassis). Also, no weird fn <> CTRL swapping is needed (sorry, old-school ThinkPad fans!). CTRL is where it's supposed to be—in the leftmost pinkie position.

The touchpad was a bit annoying at first (pinching and zooming sometimes weren't working). Having checked libinputs bug tracker for something similar, I found an issue from somebody who had the inverse problem. He found that kernel parameter psmouse.synaptics_intertouch=0 solved his problem. I booted with that option, and yeah. It really does solve all my problems with the touchpad. It is insane that the secondary bus for Synaptics devices is still such a problem. 

If you have this laptop, try it yourself: run libinput debug-events --verbose without the above kernel parameter, and try pinch-zooming a bit. You'll see a lot of times that libinput will detect only a POINTER_MOTION event even though you pinched, while this completely stops with the kernel parameter. I am not sure, but this seems like a bug in the device firmware, which would need to be fixed by Lenovo.

So, how does suspend/resume work now? Wasn't that the main reason for even buying this? To make a long story short, it works absolutely flawlessly on Debian 12 (6.1.0-16-amd64 #1 SMP PREEMPTDYNAMIC Debian 6.1.67-1 (2023-12-12) x8664 GNU/Linux). It instantly suspends and wakes up in about one second. Overnight power draw when suspended is ~4%, which is superb for me.

The only remaining problem for me is that hardware decode of VP9 currently doesn't work correctly - Youtube uses that a lot. There's a Mesa bug logged about this, and at time of writing there exists a preliminary firmware fix for it. Let's hope it finds its way into Debian at some point :). Also, I had a amdgpu hang/reset randomly when opening a webpage. I hope these sort of things get fixed as time goes by for this relatively new platform.

I will keep you informed if any of this changes.

Site generated on 2024-01-29 14:07:12. Changelog on Github.
Subscribe with RSS: https://lpcvoid.com/rss