Skip to content

[BUG] ESSX 8336 No local devices (speakers/headphones) on N4120 tablet (Chuwi Hi10X) #2955

Closed

Description

@callegar

Describe the bug

Cannot seem to be able to get sound working on the Chuwi Hi10X convertible/tablet. It looks like there are two versions of this tablet using the same Hi10X name. The problematic one uses a Celeron N4120 Gemini lake processor and related chipset.

Trying with manjaro linux that uses a quite recent kernel and alsa. Audio is not detected apart from the HDMI outputs.

Tried options snd-intel-dspcfg dsp_driver=1 that does not seem to help.

Alto tried options snd-intel-dspcfg dsp_driver=3 that creates a lot of activity on dmesg (with many errors). Will attach output here if relevant.

Audio works in Windows and that OS shows "Smart Sound Technology (Intel(R) SST) OED" for the audio part not attached to HDMI. The device codes I am getting there are 3198, 0222 and AE34. And for all of them the vendor code is 8086 (intel).

Before proceeding with an attempt to collect more data I would like to know if sound is expected to be working in linux on this hardware or if it is still a work in progress, so that testing is premature.

To Reproduce

aplay -l only reports HDMI outputs.

Reproduction Rate

Always.

Expected behavior

Sound should be available via the internal speakers and the audio jack (mic+headphones).

Impact

Total showstopper. Only way to use audio on this machine is to use bluetooth headphones.

Environment

Unclear to me how to get this for my system that is installed from a distro.

  1. Branch name and commit hash of the 2 repositories: sof (firmware/topology) and linux (kernel driver).
    • Kernel: {SHA}
    • SOF: {SHA}
  2. Name of the topology file
    • Topology: {FILE}
  3. Name of the platform(s) on which the bug is observed.
    • Platform: {PLATFORM}

Screenshots or console output

Will provide all that may be needed if audio can be expected to be working on this system.
Unclear to me how to get the sof-logger to debug.

Activity

  1. changed the title [-][BUG] No sound on N4120 tablet (Chuwi Hi10X)[/-] [+][BUG] No local devices (speakers/headphones) on N4120 tablet (Chuwi Hi10X)[/+] on Jun 1, 2021
  2. callegar commented on Jun 1, 2021

    @callegar
    Author

    Moving to a 5.12 kernel, with snd-intel-dspcfg dsp_driver=3 the firmware appears to load correctly. However, a topology file for idisp only seems to be loaded and the local devices remain missing.

    The situation seems similar (to some extent) to the one described in https://askubuntu.com/questions/1330755/no-sound-on-gemini-lake-with-xubuntu, that also refers to geminilake.

  3. kv2019i commented on Jun 1, 2021

    @kv2019i
    Collaborator

    @callegar wrote:

    Before proceeding with an attempt to collect more data I would like to know if sound is expected to be working in linux on this hardware or if it is still a work in progress, so that testing is premature.

    The DSP side on N4120 is supported on Linux (e.g. there are multiple Chromebooks with N4120). But for devices that have shipped with Windows, it all depends how the vendor has put the hw together, what codec, how it's hooked up, are there codec drivers in Linux for the hw, etc, etc.

    So before that can be answered, more info is needed on the hw.

    Can you do a NHLT dump and attach the output to this bug?

    sudo bash
    cat /sys/firmware/acpi/tables/NHLT >NHLT.bin
    

    The NHLT.bin might reveal something about this machine. NHLT is a set of tables in ACPI providing the OS (Linux here) information about how the audio peripherals are connected. More info at https://01.org/sites/default/files/595976_intel_sst_nhlt.pdf

  4. transferred this issue fromthesofproject/sofon Jun 1, 2021
  5. callegar commented on Jun 1, 2021

    @callegar
    Author

    Here is the file. Had to zip it otherwise github did not let me download it.
    I see the word ALASKA in the file. There is this word in something that the kernel tries to load (failing) if I set snd-intel-dspcfg dsp_driver=2.

    nhlt.zip

  6. kv2019i commented on Jun 1, 2021

    @kv2019i
    Collaborator

    So it seems there's a I2S codec connected, but NHLT doesn't reveal make or model. We support a few configuration for GLK upstream, you can see the list in:
    linux/sound/soc/intel/common/soc-acpi-intel-glk-match.c

    It would seem this is not a supported configuration, so some new development (by someone who has a device) is needed. At minimum, an entry is needed to soc-acpi-intel-glk-match.c, but more likely is some changes and/or new code is needed in machine drivers. The codec most probably is already supported upstream.

  7. plbossart commented on Jun 1, 2021

    @plbossart
    Member

    ALASKA isn't linked to audio codecs.

    I think we need to start with the basics assuming the DSP is not enabled and it's an HDaudio codec. I am not aware of any non-Chromebook devices with I2C/I2S and of any support on Windows for this kind of codecs.

    @callegar You need to start with removing all options and checking how snd-hda-intel deals with the hardware. attach dmesg and alsa-info (separtely)

  8. callegar commented on Jun 1, 2021

    @callegar
    Author

    Here is the dmesg obtained after removing any modprobe option related to snd-intel-dspcfg dsp_driver=....
    dmesg.txt

  9. callegar commented on Jun 1, 2021

    @callegar
    Author

    ... And here I also have the alsa info
    alsa-info.txt

  10. callegar commented on Jun 2, 2021

    @callegar
    Author

    @kv2019i:

    it seems there's a I2S codec connected, but NHLT doesn't reveal make or model.

    before I switched to linux, I have collected the hardware info I could get from windows. Here I see a "hierarchy" of audio devices, springing from a 8086.3198 Intel SST audio subsystem. Local microphone and speakers appear to be attached via a 8086.0222 OED device (don't know what OED stands for) and 8086.AE34. Could any of them point at the actual CODEC?

    I also have the windows partition images that can be mounted for inspection (including a recovery image). Do you believe that anything there could hint at some hardware description and at how the codec should be managed?

  11. kv2019i commented on Jun 2, 2021

    @kv2019i
    Collaborator

    @plbossart It seems DSP is enabled and NHLT lists a I2S port programmed:
    [ 3.994142] snd_hda_intel 0000:00:0e.0: DSP detected with PCI class/subclass/prog-if info 0x040100

    @callegar You can look at this old bug https://bugzilla.kernel.org/show_bug.cgi?id=189261 to see typical steps to dig up information from Windows. DSDT dump with probably reveal details -- I'd guess it's a Realtek codec so ACPI HID will be 10EC something.

  12. callegar commented on Jun 2, 2021

    @callegar
    Author

    @kv2019i I'm not really able to read the dsdt dump file, but grepping for 10EC returns nothing.

    dsdt.dsl.txt

  13. callegar commented on Jun 2, 2021

    @callegar
    Author

    @kv2019i incidentally, using options snd-intel-dspcfg dsp_driver=3 shows in dmesg that a firmware is actually loaded and booted. Would that dmesg dump be useful too?

  14. callegar commented on Jun 2, 2021

    @callegar
    Author

    Among the ACPI devices I find an ESSX8336. This is an Everst sound device, right? Can it be relevant?
    I have also found this on github, but unclear to me if it should apply and how: https://github.com/yangxiaohua2009/GLK-ES8336
    The repo owner seems to be the same person writing in the bugzilla.kernel.org thread (about audio on the Chuwi X10/X12 you have just pointed me at).

  15. 176 remaining items

  16. callegar commented on Dec 13, 2022

    @callegar
    Author

    @yangxiaohua2009

    I have tested using the provided UCM files. Still no sound.

    A more detailed report:

    1. Used the quirk to invert the jack detection. This worked (partially):

      • With no headphones plugged in, the volume control tool says "speakers" and with the headphones plugged in it says "headphones"
      • However there is no mic detection working. Either with or without the headphones plugged in the mixer shows a "headset mic" as an inactive device. Namely, you need to tick "show inactive devices" to have the recording device shown and it is always "headset mic".
    2. Installed the UCM files. Used the script ucm.sh. System detected by the script as 8336 ucm latest. This seems correct and everything looks in place.

    3. Used the 4.sh script to fix the controls. The first set of amixer commands succeed and produce output. The second set (the one with -c 1) fails with Invalid card number '1'

    With the above, neither the test function in the audio setting system configuration panel, neither alsa's speaker_test produce any sound neither via the speaker nor via the headphones.

    Any other clue?

  17. yangxiaohua2009 commented on Dec 14, 2022

    @yangxiaohua2009

    Please provide your alsainfo when playing music.

  18. callegar commented on Dec 14, 2022

    @callegar
    Author

    Here is the alsa info alsa_info.log

  19. plbossart commented on Dec 14, 2022

    @plbossart
    Member

    There's a quirk for the headset mic @callegar

    #define SOC_ES8336_HEADSET_MIC1 BIT(8)

    maybe go from snd_soc_sof_es8336: quirk=0x40 to snd_soc_sof_es8336: quirk=0x140 ?

  20. callegar commented on Dec 15, 2022

    @callegar
    Author

    Tested. Unfortunately changing from 0x40 to 0x140 with the quirks had no effect. Checked with dmesg that the quirk is actually being picked up by the driver and it is, however headset mic is still always shown as an inactive device (either with and without the headphones plugged in)

  21. callegar commented on Dec 18, 2022

    @callegar
    Author

    Just a quick note to: (i) check if the alsa_info was obtained in the right way to be useful; and (ii) whether the bug could be reopened. The issue appears to still be there while having the issue close could lead someone to think that the issue for this laptop is solved. This could be misleading for someone shopping for a linux capable convertible.

  22. callegar commented on Jan 6, 2023

    @callegar
    Author

    @yangxiaohua2009 was the alsainfo somehow useful? Did I get it correctly (was not completely sure about what you meant by "alsainfo when playing music").

    Is there anything else that can be tried on this machine? Can the bug be reopened as a warning for others?

  23. yangxiaohua2009 commented on Jan 9, 2023

    @yangxiaohua2009

    Your headphone sound is very low, please set it larger

    Simple mixer control 'Headphone',0
      Capabilities: pvolume pswitch pswitch-joined
      Playback channels: Front Left - Front Right
      Limits: Playback 0 - 3
      Mono:
      Front Left: Playback 0 [0%] [-48.00dB] [off]
      Front Right: Playback 0 [0%] [-48.00dB] [off]
    

    I have a shell script to do this: 4.zip

  24. callegar commented on Feb 6, 2023

    @callegar
    Author

    This does not work either...

    I am getting the impression that with the chuwi hi10x the issue is not with some mixer control level setting, rather much more fundamental in the way the codec is employed. Chuwi is probably taking a very non standard approach, maybe to reuse something of some previous design of theirs and part of the audio subsystem may be gated under some hidden logic. The fact that the mic remains unavailable seems to hint in this direction.

    I remember I read in the past that some previous Chuwi design was gating some audio connections under some undocumented gpio controls, wonder if the situation could be the same here.

  25. yangxiaohua2009 commented on Apr 7, 2023

    @yangxiaohua2009

    @callegar You may want to get the amixer contents correct first. If you suspect that the gpio setting is wrong, just enable hp gpio quirk and the gpio revert quirk.

  26. callegar commented on Apr 8, 2023

    @callegar
    Author

    I tried the 4.zip script above, but with no success. I will try again. I believe that this is for setting the amixer correctly. I have also tried a gpio quirk reversing headphone detection (which made the detection correct, but still produced no sound, nor detection of the mic). How are the hp gpio quirk and the revert quirk enabled (i.e. what are the relevant bits in the quirks mask?)

  27. yangxiaohua2009 commented on Apr 10, 2023

    @yangxiaohua2009

    For Headphone gpio, see codec here.
    You may want to enable bit 7 #define SOF_ES8336_HEADPHONE_GPIO BIT(7)

    Also, you may want to try quirk 0x00, 0x01 and 0x02, changing the ssp number but I doubt if this works.

  28. meiyujack commented on Dec 23, 2023

    @meiyujack

    I figure out. Just install the driver, as you seen (dmesg | grep sof ), here is the address: https://github.com/thesofproject/sof-bin/
    and after you install alsa-utils, DAC need dB gain 0 (up arrow to adjust).
    Reboot will reset, continue...
    Mine is
    amixer sset DAC 4 192
    That is 100%, 0.00dB
    The important is your speakers volume maximum and during your song playing, you can hear it.
    Maybe test is too short...

  29. callegar commented on Dec 29, 2023

    @callegar
    Author

    I have sound. The trick for me was to disable the suspend-to-idle in pulseaudio. When suspended this device does not come up again.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Communityend-user or distro-reported issuesGLKApplies to Gemini LakecodecCodec HW or driver restrictioncodec ES8336

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions