[Bug 1019316] New: Sound is played on speaker and headphones at the same time on GPD Win
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316 Bug ID: 1019316 Summary: Sound is played on speaker and headphones at the same time on GPD Win Classification: openSUSE Product: openSUSE Distribution Version: Leap 42.2 Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Sound Assignee: tiwai@suse.com Reporter: adrien.plazas@suse.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- I installed Leap 42.2 with the latest vanilla kernel (https://build.opensuse.org/project/show/Kernel:vanilla) on a GPD Win. Its sound chip is a chtrt5645. It plays sound at the same time on the included mono speaker and the headphones, and when plugging in or out headphones in the jack I see no change in the GNOME Control Center's audio output page: it usually displays switch between "Speakers" and "Headphones", but there it unconditionally displays "Headphones". Also, the mono speaker only outputs the left channel. The expected behavior is to have it switch between either the mono speaker (playing all the channels mixed) or the stereo headphones when some are plugged in. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c1
Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c2
--- Comment #2 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c3
--- Comment #3 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c4
--- Comment #4 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c5
--- Comment #5 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c6
--- Comment #6 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c7
Hans de Goede
Unfortunately it can't work:
Handle 0x0001, DMI type 1, 27 bytes System Information Manufacturer: Default string Product Name: Default string Version: Default string Serial Number: Default string
BIOS must fill the right strings to DMI entries. Do you have a BIOS update? Or inform/ask to the manufacturer about this.
I'm not sure which BIOS Adrien has, but I've the latest version of the BIOS (where they removed almost all settings, which in a way is a good thing as before you could break the system in many interesting ways), but this is still unfixed. I also noticed this problem, as we really need a quirk for the wrongly enabled sdio-wifi node in ACPI too, which causes the actually used pci-e wifi to not work when probed by the sdhci driver (likely the enable gpio gets set to disabled by the sdhci-acpi code)... I was thinking that maybe we need some other way to uniquely identify machines, like doing a sha256sum over the entire BIOS image, or some such ? Alternatively since without a way to apply quirks we're going to need a dsdt overlay (see bug 1019337) would it be possible to fix this in an updated dstd ? Regards, Hans -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c13
--- Comment #13 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c14
--- Comment #14 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c15
--- Comment #15 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c16
--- Comment #16 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c17
--- Comment #17 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c18
--- Comment #18 from Hans de Goede
I updated home:tiwai:test:cht repo again, and now the inverted detection is handled in software, so it should work with jd_invert=1 option. Give it a try.
Can you mail me the patches for this and/or point me to a git branch with the patches ? -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c19
--- Comment #19 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c20
--- Comment #20 from Adrien Plazas
I updated home:tiwai:test:cht repo again, and now the inverted detection is handled in software, so it should work with jd_invert=1 option. Give it a try.
I just tested it with jd_mode=3 jd_invert=1: - when starting without headphones, I have sound on speakers as expected; - then I plug the headphones, and I have sound on the headphones, perfect again; - then I unplug the headphones, the sound stay on the headphones… - when starting with the headphones, sound stays on the headphones all the time. I'll test other modes. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c21
--- Comment #21 from Takashi Iwai
(In reply to Takashi Iwai from comment #17)
I updated home:tiwai:test:cht repo again, and now the inverted detection is handled in software, so it should work with jd_invert=1 option. Give it a try.
I just tested it with jd_mode=3 jd_invert=1: - when starting without headphones, I have sound on speakers as expected; - then I plug the headphones, and I have sound on the headphones, perfect again; - then I unplug the headphones, the sound stay on the headphones… - when starting with the headphones, sound stays on the headphones all the time.
I'll test other modes.
Could you try to install the following rt5465-default-kmp, reboot and check the kernel messages starting with 'XXX'? If nothing appears, check whether the weak-updates/* (or updates/*) appears in the module path: /usr/sbin/modinfo snd-soc-rt5645 | grep file -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c22
--- Comment #22 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c23
--- Comment #23 from Adrien Plazas
Could you try to install the following rt5465-default-kmp, reboot and check the kernel messages starting with 'XXX'? If nothing appears, check whether the weak-updates/* (or updates/*) appears in the module path: /usr/sbin/modinfo snd-soc-rt5645 | grep file
I couldn't find a package named rt5465-default-kmp or anything similar, where can I find it? -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c24
--- Comment #24 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c25
--- Comment #25 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c26
--- Comment #26 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c27
--- Comment #27 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c28
Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c29
--- Comment #29 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c30
--- Comment #30 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c31
--- Comment #31 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c32
--- Comment #32 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c33
--- Comment #33 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c34
--- Comment #34 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c35
Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c36
--- Comment #36 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c37
--- Comment #37 from Hans de Goede
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c38
--- Comment #38 from Takashi Iwai
Hi,
One remark about the patch, you know that you can set .driver_data in a dmi_system_id table ? That would lead to somewhat cleaner code here IMHO,
Yeah, thanks, I know of it. But I wanted to make the patch as short as possible for now. A further cleanup can be done later. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c39
--- Comment #39 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c40
--- Comment #40 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c41
Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c42
--- Comment #42 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c43
--- Comment #43 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c44
--- Comment #44 from Adrien Plazas
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c45
--- Comment #45 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c46
--- Comment #46 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c47
--- Comment #47 from Adrien Plazas
Adrien, could you try the 4.11-rc7 kernel in IBS home:tiwai:test:mjwarrior repo?
Unfortunately no, for whatever reason my TW install stopped working and I can't manage to install a new one. I'll try again and let you know. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c48
--- Comment #48 from Adrien Plazas
Adrien, could you try the 4.11-rc7 kernel in IBS home:tiwai:test:mjwarrior repo? It should contain all fixes including the very latest patchset from Realtek.
I managed to install it and test it: - battery state, charging etc. seems to work fine; - screen brightness adjustment doesn't work; - PulseAudio doesn't seem to work, sometimes it seems to work but I don't know by which magic and hence I couldn't test further, it may be because of a changed setting somewhere; - accelerometer works tough it seems inverted on both axes, I need to check my kernel params; - wifi seems to work, but again I didn't take the time to test it properly yet; - suspend and wake-up seems to work, the lid-switch too; I need to clean my install up somehow, but there is a clear progress. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c49
--- Comment #49 from Takashi Iwai
- screen brightness adjustment doesn't work;
IIRC, the DSDT has to be overridden to support pwm properly?
- PulseAudio doesn't seem to work, sometimes it seems to work but I don't know by which magic and hence I couldn't test further, it may be because of a changed setting somewhere;
To be sure, remove ~/.config/pulse/* once. The audio streaming part hasn't changed much, but rather a question is whether the jack detection works reliably. Could you check whether plugging/unplugging changes the state correctly while running GNOME mixer or pavucontrol dialog?
- accelerometer works tough it seems inverted on both axes, I need to check my kernel params;
You'd need to set up udev rules and hwdb for this. Check Hans' blog entry. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c50
--- Comment #50 from Adrien Plazas
(In reply to Adrien Plazas from comment #48)
- screen brightness adjustment doesn't work;
IIRC, the DSDT has to be overridden to support pwm properly?
No change after applying what is written on Hans' blog post.
- PulseAudio doesn't seem to work, sometimes it seems to work but I don't know by which magic and hence I couldn't test further, it may be because of a changed setting somewhere;
To be sure, remove ~/.config/pulse/* once. The audio streaming part hasn't changed much, but rather a question is whether the jack detection works reliably. Could you check whether plugging/unplugging changes the state correctly while running GNOME mixer or pavucontrol dialog?
I still see no input or output devices, it looks like PulseAudio isn't working at all (`ps -e | grep pulse` outputs nothing).
- accelerometer works tough it seems inverted on both axes, I need to check my kernel params;
You'd need to set up udev rules and hwdb for this. Check Hans' blog entry.
I just did and it works fine now. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c51
--- Comment #51 from Takashi Iwai
(In reply to Takashi Iwai from comment #49)
(In reply to Adrien Plazas from comment #48)
- screen brightness adjustment doesn't work;
IIRC, the DSDT has to be overridden to support pwm properly?
No change after applying what is written on Hans' blog post.
Hmm. You updated dracut as well? It's found in the same OBS repo.
- PulseAudio doesn't seem to work, sometimes it seems to work but I don't know by which magic and hence I couldn't test further, it may be because of a changed setting somewhere;
To be sure, remove ~/.config/pulse/* once. The audio streaming part hasn't changed much, but rather a question is whether the jack detection works reliably. Could you check whether plugging/unplugging changes the state correctly while running GNOME mixer or pavucontrol dialog?
I still see no input or output devices, it looks like PulseAudio isn't working at all (`ps -e | grep pulse` outputs nothing).
Ah, it must be the issue with HDMI LPE audio. Try to blacklist the driver, add the following in /etc/modprobe.d/99-local.conf: blacklist snd-hdmi-lpe-audio -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c52
--- Comment #52 from Adrien Plazas
(In reply to Adrien Plazas from comment #50)
(In reply to Takashi Iwai from comment #49)
(In reply to Adrien Plazas from comment #48)
- screen brightness adjustment doesn't work;
IIRC, the DSDT has to be overridden to support pwm properly?
No change after applying what is written on Hans' blog post.
Hmm. You updated dracut as well? It's found in the same OBS repo.
I don't see it in home:tiwai:test:mjwarrior on IBS.
Ah, it must be the issue with HDMI LPE audio. Try to blacklist the driver, add the following in /etc/modprobe.d/99-local.conf: blacklist snd-hdmi-lpe-audio
It works perfectly that way! :) -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c53
--- Comment #53 from Takashi Iwai
(In reply to Takashi Iwai from comment #51)
(In reply to Adrien Plazas from comment #50)
(In reply to Takashi Iwai from comment #49)
(In reply to Adrien Plazas from comment #48)
- screen brightness adjustment doesn't work;
IIRC, the DSDT has to be overridden to support pwm properly?
No change after applying what is written on Hans' blog post.
Hmm. You updated dracut as well? It's found in the same OBS repo.
I don't see it in home:tiwai:test:mjwarrior on IBS.
It's in OBS (not IBS) home:tiwai:mjwarrior repo, sorry for confusion.
Ah, it must be the issue with HDMI LPE audio. Try to blacklist the driver, add the following in /etc/modprobe.d/99-local.conf: blacklist snd-hdmi-lpe-audio
It works perfectly that way! :)
Good to hear. You can fix in another way by fiddling PulseAudio configuration. But blacklisting the HDMI audio driver would be the easiest if you don't need it. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c54
--- Comment #54 from Adrien Plazas
It's in OBS (not IBS) home:tiwai:mjwarrior repo, sorry for confusion.
Ah yes, it works perfectly with this new dracut. :)
Good to hear. You can fix in another way by fiddling PulseAudio configuration. But blacklisting the HDMI audio driver would be the easiest if you don't need it.
Ideally we should have both working, but it's better than no sound at all. :) Actually I found a bug: when starting the machine with headphones, the headphones are detected correctly but sound is also played on the speakers; unplugging the headphones put everything back into order. I suspect a wrongly initialized state somewhere. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c55
--- Comment #55 from Takashi Iwai
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c56
--- Comment #56 from Adrien Plazas
Hm, maybe it's a PulseAudio issue. Could you check the jack status in the following after the fresh boot? % amixer contents | grep -A2 Jack
Then check GNOME mixer or pavucontrol to see whether PA recognizes the same jack state.
Starts plugged, GNOME displays "Headphones": numid=175,iface=CARD,name='Headphone Jack' ; type=BOOLEAN,access=r-------,values=1 : values=on numid=176,iface=CARD,name='Headset Mic Jack' ; type=BOOLEAN,access=r-------,values=1 : values=on Unplug, GNOME displays "Speaker": numid=175,iface=CARD,name='Headphone Jack' ; type=BOOLEAN,access=r-------,values=1 : values=off numid=176,iface=CARD,name='Headset Mic Jack' ; type=BOOLEAN,access=r-------,values=1 : values=off Plug, GNOME displays "Headphones": numid=175,iface=CARD,name='Headphone Jack' ; type=BOOLEAN,access=r-------,values=1 : values=on numid=176,iface=CARD,name='Headset Mic Jack' ; type=BOOLEAN,access=r-------,values=1 : values=on And vice versa when starting unplugged. But somehow I can't manage to have sound on both on a fresh start now… all seems to work perfectly fine. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316
http://bugzilla.opensuse.org/show_bug.cgi?id=1019316#c57
--- Comment #57 from Takashi Iwai
participants (1)
-
bugzilla_noreply@novell.com