Lenovo ThinkPad X1 Carbon (Gen 6)

From ArchWiki
Revision as of 09:36, 2 August 2018 by Lahwaacz.bot (talk | contribs) (replaced external links, simplification and beautification of wikilinks, fixed section fragments, flagged broken section links (interactive))
Jump to: navigation, search
Tip: A great resource for thinkpads is https://www.thinkwiki.org/wiki/ThinkWiki

Model description

The Lenovo ThinkPad X1 Carbon, 6th generation is an ultrabook introduced in early 2018. It comes in several variants(20KH* and 20KG*) and features a 14" screen, 8th-gen Intel Core processors and integrated Intel UHD 620 graphics.

To ensure you have this version, install the package dmidecode and run:

# dmidecode -t system | grep Version

Version: ThinkPad X1 Carbon 6th

Support

Device Working Modules
Intel graphics Yes i915, (intel_agp)
Wireless network Yes iwlmvm
Native Ethernet with included dongle Yes  ?
Mobile broadband No***  ?
Audio Yes snd_hda_intel
Touchpad Yes* psmouse, rmi_smbus, i2c_i801
TrackPoint Yes psmouse, rmi_smbus, i2c_i801
Camera Yes uvcvideo
Fingerprint Reader No**  ?
Power management Yes  ?
Bluetooth Yes btusb
microSD card reader Yes scsi_mod
Keyboard Backlight Yes thinkpad_acpi
Function/Multimedia Keys Yes  ?

* via workaround

** progress being made on driver

*** no working linux pcie driver for Fibocom L850-GL forum link - also see this forum for more progress.

BIOS

The most convenient way to install Arch Linux is by disabling "Secure Boot" Security -> Secure Boot - Set to "Disabled". However it is possible to self-sign your kernel and boot with it enabled. For further information have a look at the Secure Boot article.

In case your efivars are not properly set it is most likely due to you not being booted into UEFI. Should the problem persist be sure to consult the UEFI#UEFI variables section.

Updates

BIOS update 1.25 was released on 2018-06-28. Obtain geteltoritoAUR and run ./geteltorito.pl -o bios-update.img n23ur08w.iso on the downloaded ISO file to create a valid El Torito image file, then flash this file on a USB drive via dd like you would flash Arch installation media. For further information see flashing BIOS from Linux.

The ThinkPad X1 Carbon supports setting a custom splash image at the earliest boot stage(instead of the red "Lenovo" logo), more information can be found in the README.TXT located in the FLASH folder of the update image.

Suspend issues

Suspend-to-RAM (S3) not supported by default

The 6th Generation X1 Carbon supports S0i3 (also known as Windows Modern Standby) and does not support the S3 sleep state. A guide exists with instructions for patching ACPI DSDT tables to add S3 support.

A forum thread has further discussion related to this issue.

Missing S3 also causes hybrid-suspend to go directly to hibernate; the mentioned patch fixes this issue.

S2idle support

From the Lenovo forums: Add the following kernel parameter to enable S2idle support:

acpi.ec_no_wakeup=1

For example, for GRUB, one might edit `/etc/default/grub` and edit `GRUB_CMDLINE_LINUX_DEFAULT`:

GRUB_CMDLINE_LINUX_DEFAULT="quiet acpi.ec_no_wakeup=1"

then perform

sudo update-grub

and restart the system.

Note: This disables wakeup/resume via lid open.
Note: This supports S2idle state, not S0i3 state as some seem to have been led to believe!

You might also need to disable the Realtek memory card reader (which appears to use a constant 2-3 W) either via the BIOS or via

echo "2-3" | sudo tee /sys/bus/usb/drivers/usb/unbind

The power consumption might still be higher than that of the S3 state in this case.

BIOS configurations

  • Config -> Thunderbolt BIOS Assist Mode - Set to "Enabled". When disabled, on Linux, power usage appears to be significantly higher because of a substantial number of CPU wakeups during s2idle.

Power management/Throttling issues

Due to wrong configured power management registers the CPU may consume a lot less power than under windows and the thermal throttling occurs at 80°C (97°C when using Windows, see T480s throttling bug).

There is a post in the official Lenovo forum to inform Lenovo about this issue.

Temporary fix

Until Lenovo fixes this issue, you can manually set the limit.

To begin, install msr-tools.

Create the file /usr/local/bin/cpu-throttling.sh (making it executable) containing the following:

#!/bin/bash

/bin/modprobe msr
wrmsr -a 0x1a2 0x3000000 # which sets the offset to 3 C, so the new trip point is 97 C 

Then create the associated service file /etc/systemd/system/cpu-throttling.service:

[Unit]
Description=set cpu heating limit to 97°c

[Service]
ExecStart=/usr/local/bin/cpu-throttling.sh
RemainAfterExit=no

[Install]
WantedBy=timers.target

And also the timer in /etc/systemd/system/cpu-throttling.timer:

[Unit]
Description=set cpu heating limit to 97°c every minute

[Timer]
OnActiveSec=60
OnUnitActiveSec=60
Unit=cpu-throttling.service

[Install]
WantedBy=timers.target

Then, enable it:

# systemctl enable cpu-throttling.timer

Reboot and check with:

# rdmsr -f 29:24 -d 0x1a2

3
Note: If the rdmsr command outputs: 'rdmsr: open: No such file or directory', you may have to configure the msr module to load automatically. See Kernel module#Automatic module handling for more details.

TrackPoint and Touchpad issues

On the 20KG model, the Touchpad(Synaptics) and TrackPoint(Elantech) do not work together, one has to disable the TrackPoint in BIOS to get the Touchpad to work reliably out of the box. The root of the issue seems to be that the default loading of the TrackPoint via ancient PS/2 drivers conflicts with Touchpad loading. Synaptics has introduced a new way of doing things named RMI(4) that fixes some those issues. Further explanation is collected in this thread.

As a workaround, add synaptics_intertouch=1 to the psmouse kernel module options, for example in the cmdline of the boot loader:

 [...] root=/dev/sda1 rw psmouse.synaptics_intertouch=1 [...]

or by editing /etc/modprobe.d/psmouse.conf:

 options psmouse synaptics_intertouch=1
Note: When using TLP with default powersaving settings, there might be occasional hiccups such as dropouts of tap-to-click functionality for the Touchpad, as well as the TrackPoint not surviving suspends and needing to be re-initialized

Reconnecting dead trackpad

echo -n "none" | sudo tee /sys/bus/serio/devices/serio1/drvctl
echo -n "reconnect" | sudo tee /sys/bus/serio/devices/serio1/drvctl

Full-disk encryption

Ramdisk module

With LUKS for root, i915 needs to be loaded in ramdisk in order to access the password prompt. Add i915 to MODULES list in /etc/mkinitcpio.conf and regenerate the ramdisk.

References

Additional resources