English Community

Linux Operating SystemsUbuntu
All Forum Topics
Options

21 Posts

07-12-2019

AU

45 Signins

252 Page Views

  • Posts: 21
  • Registered: ‎07-12-2019
  • Location: AU
  • Views: 252
  • Message 81 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-12, 21:50 PM

Sounds like you've missed getting the kernel source - and how you do that depends on the distro (or of course you can just grab it from kernel.org). That should get you the scripts/kconfig folder. If you've not done it before your first step is probably to build a kernel - there are lots of guides online but it can be a bit daunting

 

For the broken link - looks like the files have moved around recently. I *think* instead you want to use:

https://github.com/alsa-project/alsa-ucm-conf/tree/master/ucm2/sof-hda-dsp

(based on https://github.com/alsa-project/alsa-ucm-conf/commit/d560d25481916e296387e680a2ec0833a81f68d5#diff-0331b40c89f63747bcebea3b0fdcd7f7) but I've not tried it myself yet - I'll give it a go as soon as I'm able to (and I'll update the guide)

  


@MarkRHPearson thanks for your work on Linux support for these laptops, much appreciated. I've been running bleeding-edge kernel, ALSA and SOF firmware combinations on my X1Y4, and can confirm a 5.4-rc7 kernel (from https://github.com/thesofproject/linux/commit/f55db62ec6a17a50cc3f82729c7aaee82dc56033), alsa-lib from master with the ucm2 UCMs, and the 1.3 signed SOF firmware and topology you've linked to previously works very well your guide. Tweeters/Bass speaker, the DMIC microphone and HDMI/DP/headphone jack sensing all working well.

 

Only remaining issue is that ALSA can control the speaker/mic mute LEDs but Pulseaudio doesn't seem to currently. I understand this is being worked on upstream.

 

For anyone interested in the tribulations, see my comments on https://github.com/thesofproject/linux/pull/1442

 

Relevant Kconfig:

 

# CONFIG_SND_SOC_SOF_ACPI is not set
CONFIG_SND_SOC_SOF=m
CONFIG_SND_SOC_SOF_PROBE_WORK_QUEUE=y
CONFIG_SND_SOC_SOF_INTEL_TOPLEVEL=y
CONFIG_SND_SOC_SOF_INTEL_PCI=m
CONFIG_SND_SOC_SOF_INTEL_COMMON=m
# CONFIG_SND_SOC_SOF_MERRIFIELD_SUPPORT is not set
# CONFIG_SND_SOC_SOF_APOLLOLAKE_SUPPORT is not set
# CONFIG_SND_SOC_SOF_GEMINILAKE_SUPPORT is not set
CONFIG_SND_SOC_SOF_CANNONLAKE_SUPPORT=y
CONFIG_SND_SOC_SOF_CANNONLAKE=m
# CONFIG_SND_SOC_SOF_COFFEELAKE_SUPPORT is not set
# CONFIG_SND_SOC_SOF_ICELAKE_SUPPORT is not set
# CONFIG_SND_SOC_SOF_COMETLAKE_LP_SUPPORT is not set
# CONFIG_SND_SOC_SOF_COMETLAKE_H_SUPPORT is not set
# CONFIG_SND_SOC_SOF_TIGERLAKE_SUPPORT is not set
# CONFIG_SND_SOC_SOF_ELKHARTLAKE_SUPPORT is not set
# CONFIG_SND_SOC_SOF_JASPERLAKE_SUPPORT is not set
CONFIG_SND_SOC_SOF_HDA_COMMON=m
CONFIG_SND_SOC_SOF_HDA_LINK=y
CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC=y
# CONFIG_SND_SOC_SOF_HDA_ALWAYS_ENABLE_DMI_L1 is not set
CONFIG_SND_SOC_SOF_HDA_COMMON_HDMI_CODEC=y
CONFIG_SND_SOC_SOF_HDA_LINK_BASELINE=m
CONFIG_SND_SOC_SOF_HDA=m
CONFIG_SND_SOC_SOF_XTENSA=m

 

Reply
Options

21 Posts

07-12-2019

AU

45 Signins

252 Page Views

  • Posts: 21
  • Registered: ‎07-12-2019
  • Location: AU
  • Views: 252
  • Message 82 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-14, 13:51 PM

Also I see Fedora 31 has just pushed ALSA 1.2.1 to their updates-testing repo (https://koji.fedoraproject.org/koji/rpminfo?rpmID=19596721)

which includes the SOF 1.3 DSP firmware, topology and UCM files, which fully enable the DMIC, tweeter and bass speakers, and jack sensing. Unfortunately their 5.3.11 kernel config does not enable kernel support for SOF by default (# CONFIG_SND_SOC_SOF_INTEL_TOPLEVEL is not set) therefore a custom kernel (ideally from https://github.com/thesofproject/linux/tree/topic/sof-dev) with the config above enabled is still required.

Reply
Options

1 Posts

11-16-2019

HK

3 Signins

21 Page Views

  • Posts: 1
  • Registered: ‎11-16-2019
  • Location: HK
  • Views: 21
  • Message 83 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-16, 13:29 PM

Hi. I followed all the steps outlined by @MarkRHPearson but then when I rebooted my computer, all the audio was gone and when I try to change the volume through the volume buttons, it said "Dummy Output". Could you please help me thanks. 

Reply
Options

21 Posts

07-12-2019

AU

45 Signins

252 Page Views

  • Posts: 21
  • Registered: ‎07-12-2019
  • Location: AU
  • Views: 252
  • Message 84 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-16, 14:01 PM

 wrote:

Hi. I followed all the steps outlined by @MarkRHPearson but then when I rebooted my computer, all the audio was gone and when I try to change the volume through the volume buttons, it said "Dummy Output". Could you please help me thanks. 


Feel free to PM me the output of "dmesg | grep SOF" and "cat /boot/config-`uname -r` | grep SOF" and I can take a look.

Reply
Options

212 Posts

07-22-2019

CA

224 Signins

2076 Page Views

  • Posts: 212
  • Registered: ‎07-22-2019
  • Location: CA
  • Views: 2076
  • Message 85 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-16, 14:15 PM

I'll happily have a look as well

In my experience if you only have the dummy device it means the SOF driver had some issues during initialisation - failure to load the firmware or the topology files. Check in the dmesg output for anything with "sof" particularly.

Thanks @tokyovigilante

Reply
Options

33 Posts

11-08-2016

US

87 Signins

701 Page Views

  • Posts: 33
  • Registered: ‎11-08-2016
  • Location: US
  • Views: 701
  • Message 86 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-24, 18:49 PM

Can anyone post the settings for the Realtek audio chip from /proc/asound/card0/codec#0

 

I have a Yoga C940 which also has five speakers but I can't get them to work right.

 

Thanks.

Reply
Options

11 Posts

08-06-2019

GB

17 Signins

60 Page Views

  • Posts: 11
  • Registered: ‎08-06-2019
  • Location: GB
  • Views: 60
  • Message 87 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-26, 6:07 AM

I upgraded to the newly released kernel 5.4 in the hope of some sound driver improvements, but for some reason no soundcards (pacmd list-cards) are detected anymore.  I haven't found a fix that works yet.

 

No problems with kernel 5.3.13.

 

Edit: also no longer possible to wake from sleep.

Reply
Options

4 Posts

04-01-2009

ZA

11 Signins

45 Page Views

  • Posts: 4
  • Registered: ‎04-01-2009
  • Location: ZA
  • Views: 45
  • Message 88 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-27, 5:54 AM
Just to second this .... I have the same problem.
Reply
Options

11 Posts

08-06-2019

GB

17 Signins

60 Page Views

  • Posts: 11
  • Registered: ‎08-06-2019
  • Location: GB
  • Views: 60
  • Message 89 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-30, 3:58 AM

Re the sound part of the above:

 

When booted into the 5.4.1 kernel, the relevant output of "lspci -v" is:

 

    Audio device: Intel Corporation Device 9dc8 (rev 11) (prog-if 80)
        Subsystem: Lenovo Device 2292
        Flags: bus master, fast devsel, latency 64, IRQ 169
        Memory at ea23c000 (64-bit, non-prefetchable) [size=16K]
        Memory at ea000000 (64-bit, non-prefetchable) [size=1M]
        Capabilities: <access denied>
        Kernel driver in use: sof-audio-pci
        Kernel modules: snd_hda_intel, snd_sof_pci

 

Output of "pacmd list-cards":

 

    0 card(s) available.

 

Output of "dmesg | grep SOF" is empty.

 

Differences between "cat /boot/config-`uname -r` | grep SOF" from 5.3.14 to 5.4.1:

 

    Added
        # CONFIG_SND_SOC_SOF_NOCODEC_SUPPORT is not set
        CONFIG_SND_SOC_SOF_PROBE_WORK_QUEUE=y
        CONFIG_SND_SOC_SOF_TIGERLAKE_SUPPORT=y
        CONFIG_SND_SOC_SOF_TIGERLAKE=m
        CONFIG_SND_SOC_SOF_ELKHARTLAKE_SUPPORT=y
        CONFIG_SND_SOC_SOF_ELKHARTLAKE=m
        CONFIG_SND_SOC_SOF_HDA_LINK=y
        CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC=y
        CONFIG_SND_SOC_SOF_HDA_ALWAYS_ENABLE_DMI_L1=y
        CONFIG_SND_SOC_SOF_HDA=m

    Removed
        CONFIG_SND_SOC_SOF_NOCODEC=m
        CONFIG_SND_SOC_SOF_NOCODEC_SUPPORT=y
        # CONFIG_SND_SOC_SOF_HDA_ALWAYS_ENABLE_DMI_L1 is not set

 

I'm uprading the kernel with Ukuu which I guess pulls from Ubuntu mainline.

 

Sorry if this is no help to anyone.

Reply
Options

21 Posts

07-12-2019

AU

45 Signins

252 Page Views

  • Posts: 21
  • Registered: ‎07-12-2019
  • Location: AU
  • Views: 252
  • Message 90 of 157

Re: [Guide] X1 Carbon 7th Generation Ubuntu compatability

2019-11-30, 4:14 AM

 wrote:

Re the sound part of the above:

 

When booted into the 5.4.1 kernel, the relevant output of "lspci -v" is:

 

    Audio device: Intel Corporation Device 9dc8 (rev 11) (prog-if 80)
        Subsystem: Lenovo Device 2292
        Flags: bus master, fast devsel, latency 64, IRQ 169
        Memory at ea23c000 (64-bit, non-prefetchable) [size=16K]
        Memory at ea000000 (64-bit, non-prefetchable) [size=1M]
        Capabilities: <access denied>
        Kernel driver in use: sof-audio-pci
        Kernel modules: snd_hda_intel, snd_sof_pci

 

Output of "pacmd list-cards":

 

    0 card(s) available.

 

Output of "dmesg | grep SOF" is empty.

 

Differences between "cat /boot/config-`uname -r` | grep SOF" from 5.3.14 to 5.4.1:

 

    Added
        # CONFIG_SND_SOC_SOF_NOCODEC_SUPPORT is not set
        CONFIG_SND_SOC_SOF_PROBE_WORK_QUEUE=y
        CONFIG_SND_SOC_SOF_TIGERLAKE_SUPPORT=y
        CONFIG_SND_SOC_SOF_TIGERLAKE=m
        CONFIG_SND_SOC_SOF_ELKHARTLAKE_SUPPORT=y
        CONFIG_SND_SOC_SOF_ELKHARTLAKE=m
        CONFIG_SND_SOC_SOF_HDA_LINK=y
        CONFIG_SND_SOC_SOF_HDA_AUDIO_CODEC=y
        CONFIG_SND_SOC_SOF_HDA_ALWAYS_ENABLE_DMI_L1=y
        CONFIG_SND_SOC_SOF_HDA=m

    Removed
        CONFIG_SND_SOC_SOF_NOCODEC=m
        CONFIG_SND_SOC_SOF_NOCODEC_SUPPORT=y
        # CONFIG_SND_SOC_SOF_HDA_ALWAYS_ENABLE_DMI_L1 is not set

 

I'm uprading the kernel with Ukuu which I guess pulls from Ubuntu mainline.

 

Sorry if this is no help to anyone.


I believe Ubuntu is missing some relevant kernel config, but this may have changed. Fedora has backported some fixes from 5.5 to 5.4, you may still need to build your own kernel. Certainly ALSA 1.2.1 (which is the first version which ships the correct firmware and UCM files) needs some backported fixes from 5.5. You'll probably need to build at least a 5.4 kernel from upstream with this patch: http://people.redhat.com/~jkysela/sof/fedora-sof-v1-5.4-rc8.patch

 

The relevant bug thread for Fedora is here:

https://bugzilla.redhat.com/show_bug.cgi?id=1772498

 

Reply
Forum Home

Community Guidelines

Please review our Guidelines before posting.

Learn More

Check out current deals!

Go Shop
X

Save

X

Delete