Lenovo Yoga C940

From ArchWiki
Hardware PCI/USB ID Working?
Touchpad 06cb:00be Yes
Keyboard PS/2 Yes
Touchscreen 056a:51e6 Yes
Stylus 056a:51e6 Yes
Video 8086:8a52 Yes
Webcam (Acer) 5986:2115 Yes
Webcam (IMC) 13d3:56b2 Yes
Bluetooth 8087:0026 Yes
Audio 8086:34c8 Partial
Wireless 8086:34f0 Yes
Fingerprint Reader 06cb:00be 27c6:55b4 Partial

Installation

To access the boot menu and UEFI, use F1. Disable Secure Boot. UEFI boot works fine.

Accessibility

The UEFI user interface (both Vanilla and patched − see #Audio) is graphical. An option to switch to a text-based GUI is not provided. However, the options may be selected with the arrow keys and the values changed with F5 and F6 keys.

Function keys

By default, the Fn key does not need to be pressed to toggle the alternative function of the FX keys, and Fn+FX actually sends the FX key signal. This behavior can be reversed in the UEFI.

Key Visible?1 Marked?2 Effect
F1 Yes Yes XF86AudioMute
F2 Yes Yes XF86AudioLowerVolume
F3 Yes Yes XF86AudioRaiseVolume
F4 Yes Yes XF86AudioMicMute
F5 Yes Yes F5 (No change, despite the "Refresh" pictogram)
F6 Yes Yes XF86TouchpadOn/XF86TouchpadOff
F7 Yes Yes XF86RFKill
F8 Yes Yes XF86WebCam
F9 Yes Yes Super+l4
F10 Yes Yes Super+p4
F11 Yes Yes XF86MonBrightnessUp
F12 Yes Yes XF86MonBrightnessDown
Fn+Left Yes Yes Home
Fn+Right Yes Yes End
Fn+Up Yes Yes PageUp
Fn+Down Yes Yes PageDown
Fn+Space No Yes Changes keyboard backlight
  1. The key is visible to xev and similar tools.
  2. The physical key has a symbol on it, which describes its function.
  3. systemd-logind handles this by default.
  4. Press and release signals are sent on physical key press, nothing occurs on physical release.

Video

By default on Xorg, tearing is apparent when playing videos. See Intel graphics#Tearing.

There seems to be issues with Chromium based GPU acceleration, see Intel graphics#Corruption or unresponsiveness in Chromium and Firefox.

Audio

This laptop is equipped with 2+2 speaker combo: two on the hinge ("front speaker") and two on the bottom (wired on a single "bass" channel). The latter requires a custom initialization sequence that is not supported on mainline Linux (see bugzilla.kernel.org#205755). Therefore, two options are possible: either use the vanilla configuration and rely only on the front speakers, or flash a beta BIOS an activate the full speaker array. In both cases, the firmware is required in order for the soundcard to work. See Advanced Linux Sound Architecture#ALSA firmware.

Vanilla configuration

You need to blacklist the snd_hda_intel and snd_soc_skl modules for the soundcard to correctly work.

Using a beta BIOS

There exists an unreleased patched BIOS (from Lenovo) that initialize correctly the bass speakers, see comment 59. It is now only available on a mirror, which details the flashing procedure.

Note: A later official BIOS update (AUCN61WW) does not initialize the speakers correctly, even though it was released after the (AUCN57WW) beta version. The latest official BIOS update (AUCN62WW) has not been tested yet.
Warning: The beta BIOS is full of development options. While some of them are useless, others will brick your computer. You are strongly advised not to change any setting in the advanced menu unless you are absolutely sure of what you are doing.

If you did not follow the former advice and bricked you device, a procedure exists to emergency flash the BIOS, which can also be used to downgrade it:

  • Format a USB key to FAT32
  • Copy the desired BIOS on the key (or the one provided in this post, guaranteed to work), and rename it to Veyron.fd
  • (Force) shut down the computer, and plug it on AC power.
  • Insert the USB key
  • Boot while maintaining the key Fn+R during 10 seconds

The power indicator should blink orange rapidly, and the screen backlight will turn on after 2-3 minutes. Then, a scrambled progress bar will appear and slowly filled. Once completed, the computer will reboot with the desired BIOS restored.

Thermals

Thermal shutdowns are a problem unless you install pstate-frequencyAUR or thermald.

pstate-frequency

pstate-frequencyAUR allows the user to define Turbo Boost behavior and maximum clock frequencies. The user should activate pstate-frequency.service and pstate-frequency-sleep.service for the setting to persist after suspend or reboot. Configuration files are located in /etc/pstate-frequency.d/.

Changing the line PLAN_CPU_MAX=100 to PLAN_CPU_MAX=70 in /etc/pstate-frequency.d/02-balanced.plan will throttle the maximum clock speed from 3.90 GHz to 2.70 GHz on AC. Moreover, the default plan of pstate-frequency will throttle the CPU to 30 % (around 1.2 GHz; see /etc/pstate-frequency.d/01-powersave.plan) on battery power, removing the issue of thermal shutdowns.

thermald

A few changes are necessary for thermald to work as intended:

Add the following thermald config:

/etc/thermald/thermal-conf.xml
<?xml version="1.0"?> 
 <!-- BEGIN --> 
 <ThermalConfiguration> 
 <Platform>
	<Name> Auto generated </Name>
	<ProductName>81Q9</ProductName>
	<Preference>QUIET</Preference>
	<ThermalZones>
		<ThermalZone>
			<Type>auto_zone_0</Type>
			<TripPoints>
				<TripPoint>
					<SensorType>SEN2</SensorType>
					<Temperature>80000</Temperature>
					<Type>Passive</Type>
					<CoolingDevice>
						<Type>B0D4</Type>
						<SamplingPeriod>8</SamplingPeriod>
						<TargetState>2147483647</TargetState>
					</CoolingDevice>
				</TripPoint>
				<TripPoint>
					<SensorType>x86_pkg_temp</SensorType>
					<Temperature>80000</Temperature>
					<Type>Passive</Type>
					<CoolingDevice>
						<Type>Processor</Type>
						<SamplingPeriod>1</SamplingPeriod>
					</CoolingDevice>
				</TripPoint>
			</TripPoints>
		</ThermalZone>
	</ThermalZones>
</Platform>
</ThermalConfiguration>
<!-- END -->

You might wish to tweak the target temperature (i.e. 64000) if you are OK with your machine running a bit hotter.

Edit thermald.service and remove --adaptive and add --ignore-default-control to the ExecStart line:

ExecStart=/usr/bin/thermald --systemd --dbus-enable --ignore-default-control

Manual fan control does not work at all.

Power management

Battery Conservation Mode (charge to max 50%) can be set with:

# echo 1 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004\:00/conservation_mode

where VPC2004\:00 could vary depending on the model.

If shutdown is not working and the system hangs on "reboot: Shutting down", try adding intel_iommu=off to your Kernel parameters.

Tablet mode

By default, the kernel cannot detect when the device is folded keyboard-down (360 tablet mode), yoga-usage-mode-dkms-gitAUR adds a driver. If the desktop environment supports it (eg. KDE, Gnome, Sway) then the touchpad and keyboard will be disabled when the device is folded by default, and may offer more touch-friendly functionality.

Fingerprint reader

Fingerprint reader requires a beta custom library based on a reverse-engineered Windows driver, libfprint-2-tod1-synatudor-gitAUR. Once installed, the fingerprint reader must be configured following fprint's procedure.

If you have the goodix reader (27c6:55b4), you can use this driver libfprint-goodixtls-55x4AUR. Note: you will need to flash your device with goodix-fp-dump to use this