使用電池供電時連接耳機時系統會崩潰。 (Linux 薄荷 18)

使用電池供電時連接耳機時系統會崩潰。 (Linux 薄荷 18)

使用 Mint 電池供電時,如果我將耳機連接到耳機插孔,系統會立即崩潰並關閉。不過,當我在充電模式下使用 Mint 時,這種情況不會發生。此外,如果在系統啟動之前連接耳機,Mint 無法識別它們,並且為了使用它們,需要在 Mint 運行時重新連接耳機。

這是我的系統資訊:

System:    Host: Felix-Mint Kernel: 4.4.0-53-generic x86_64 (64 bit gcc: 5.4.0)
       Desktop: Cinnamon 3.2.7 (Gtk 3.18.9-1ubuntu3.1)
       Distro: Linux Mint 18.1 Serena 
Machine:   System: Dell (portable) product: Inspiron 7560
       Mobo: Dell model: 07PJP0 v: A00
       Bios: Dell v: 1.0.8 date: 12/01/2016
CPU:       Dual core Intel Core i7-7500U (-HT-MCP-) cache: 4096 KB
       flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx) bmips: 11615
       clock speeds: max: 2701 MHz 1: 700 MHz 2: 1500 MHz 3: 600 MHz
       4: 600 MHz
Graphics:  Card-1: Intel Device 5916 bus-ID: 00:02.0
       Card-2: NVIDIA GM108M [GeForce 940MX] bus-ID: 01:00.0
       Display Server: X.Org 1.18.4 drivers: intel (unloaded: fbdev,vesa)
       Resolution: [email protected]
       GLX Renderer: Mesa DRI Intel Kabylake GT2
       GLX Version: 3.0 Mesa 11.2.0 Direct Rendering: Yes
Audio:     Card Intel Device 9d71 driver: snd_hda_intel bus-ID: 00:1f.3
       Sound: Advanced Linux Sound Architecture v: k4.4.0-53-generic

瀏覽我的syslogs這裡是我發現的:

Mar 14 18:19:01 Felix-Mint kernel: [  299.826425] mce: [Hardware Error]: Machine check events logged

這是mcelog

mcelog: failed to prefill DIMM database from DMI data
mcelog: Family 6 Model 8e CPU: only decoding architectural errors
Hardware event. This is not a software error.
MCE 0
CPU 0 BANK 6 
MISC 43880018086 ADDR fef1ce80 
TIME 1489495442 Tue Mar 14 18:14:02 2017
MCG status:
MCi status:
Error overflow
Uncorrected error
MCi_MISC register valid
MCi_ADDR register valid
Processor context corrupt
MCA: corrected filtering (some unreported errors in same region)
Generic CACHE Level-2 Generic Error
STATUS ee2000000040110a MCGSTATUS 0
MCGCAP c08 APICID 0 SOCKETID 0 
CPUID Vendor Intel Family 6 Model 142
mcelog: Family 6 Model 8e CPU: only decoding architectural errors
Hardware event. This is not a software error.
MCE 1
CPU 0 BANK 7 
MISC 7880018086 ADDR fef1ce40 
TIME 1489495442 Tue Mar 14 18:14:02 2017
MCG status:
MCi status:
Error overflow
Uncorrected error
MCi_MISC register valid
MCi_ADDR register valid
Processor context corrupt
MCA: corrected filtering (some unreported errors in same region)
Generic CACHE Level-2 Generic Error
STATUS ee2000000040110a MCGSTATUS 0
MCGCAP c08 APICID 0 SOCKETID 0 
CPUID Vendor Intel Family 6 Model 142

以下是syslogs耳機連接並工作時的情況:

Apr 30 16:20:58 Felix-Mint kernel: [   16.819396] snd_hda_intel 0000:00:1f.3: enabling device (0000 -> 0002)
Apr 30 16:20:58 Felix-Mint kernel: [   16.819555] snd_hda_intel 0000:00:1f.3: bound 0000:00:02.0 (ops i915_audio_component_bind_ops [i915])
Apr 30 16:20:58 Felix-Mint kernel: [   16.845900] ieee80211 phy0: Selected rate control algorithm 'iwl-mvm-rs'
Apr 30 16:20:58 Felix-Mint kernel: [   16.909215] snd_hda_codec_realtek hdaudioC0D0: autoconfig for ALC3246: line_outs=1 (0x14/0x0/0x0/0x0/0x0) type:speaker
Apr 30 16:20:58 Felix-Mint kernel: [   16.909217] snd_hda_codec_realtek hdaudioC0D0:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
Apr 30 16:20:58 Felix-Mint kernel: [   16.909217] snd_hda_codec_realtek hdaudioC0D0:    hp_outs=1 (0x21/0x0/0x0/0x0/0x0)
Apr 30 16:20:58 Felix-Mint kernel: [   16.909218] snd_hda_codec_realtek hdaudioC0D0:    mono: mono_out=0x0
Apr 30 16:20:58 Felix-Mint kernel: [   16.909218] snd_hda_codec_realtek hdaudioC0D0:    inputs:
Apr 30 16:20:58 Felix-Mint kernel: [   16.909219] snd_hda_codec_realtek hdaudioC0D0:      Headset Mic=0x19
Apr 30 16:20:58 Felix-Mint kernel: [   16.909220] snd_hda_codec_realtek hdaudioC0D0:      Headphone Mic=0x1a
Apr 30 16:20:58 Felix-Mint kernel: [   16.909221] snd_hda_codec_realtek hdaudioC0D0:      Internal Mic=0x12
Apr 30 16:20:58 Felix-Mint kernel: [   17.139462] intel_rapl: Found RAPL domain package
Apr 30 16:20:58 Felix-Mint kernel: [   17.139464] intel_rapl: Found RAPL domain core
Apr 30 16:20:58 Felix-Mint kernel: [   17.139466] intel_rapl: Found RAPL domain uncore
Apr 30 16:20:58 Felix-Mint kernel: [   17.139468] intel_rapl: Found RAPL domain dram
Apr 30 16:20:58 Felix-Mint kernel: [   17.244470] dcdbas dcdbas: Dell Systems Management Base Driver (version 5.6.0-3.2)
Apr 30 16:20:58 Felix-Mint kernel: [   17.300464] input: HDA Intel PCH Headphone Mic as /devices/pci0000:00/0000:00:1f.3/sound/card0/input10
Apr 30 16:20:58 Felix-Mint kernel: [   17.300516] input: HDA Intel PCH HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input11
Apr 30 16:20:58 Felix-Mint kernel: [   17.300564] input: HDA Intel PCH HDMI/DP,pcm=7 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input12
Apr 30 16:20:58 Felix-Mint kernel: [   17.300609] input: HDA Intel PCH HDMI/DP,pcm=8 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input13
Apr 30 16:20:58 Felix-Mint kernel: [   17.437597] media: Linux media interface: v0.10
Apr 30 16:20:58 Felix-Mint kernel: [   17.462276] Linux video capture interface: v2.00

因此,我無法解碼並找出此錯誤的確切原因,這肯定是由於在電池模式下連接耳機導致意外關閉/停止而引起的。我還檢查了 4.4、4.8 和 4.10,這些核心版本都沒有解決該問題。

答案1

因此,禁用 tlp 中的省電選項似乎對我有用。全部TLP設定儲存在設定檔中/etc/default/tlp。預設配置提供開箱即用的最佳化節能功能。一些高級功能(例如關閉光碟機和電池閾值)需要明確啟動。以 _BAT 結尾的參數在使用電池運作時有效。

禁用音訊省電模式。音訊省電模式的超時(以秒為單位)(支援 Intel HDA、AC97)。值為 0 將停用節能功能。

SOUND_POWER_SAVE_ON_BAT=0

然後重新啟動 tlp 服務:sudo service tlp restart

來源:http://linrunner.de/en/tlp/docs/tlp-configuration.html#audio

這應該適用於 Ubuntu 14.04、16.04 和 16.10;以及 Linux Mint 17 和 18。

答案2

我查遍了整個互聯網,發現這樣的問題(mce錯誤)困擾著不高興的kabylake處理器的所有者。我有筆記型電腦 Dell Vostro 15 5568,也有同樣的問題。

uname -a
Linux station 4.9.16-gentoo #55 SMP Thu May 4 21:52:33 MSK 2017 x86_64 Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz GenuineIntel GNU/Linux

我的麥克日誌:

mcelog --cpu kabylake

Hardware event. This is not a software error.
MCE 0
CPU 0 BANK 6 
MISC 43880018086 ADDR fef1ce80 
TIME 1493934959 Fri May  5 00:55:59 2017
MCG status:
MCi status:
Error overflow
Uncorrected error
MCi_MISC register valid
MCi_ADDR register valid
Processor context corrupt
MCA: corrected filtering (some unreported errors in same region)
Generic CACHE Level-2 Generic Error
STATUS ee0000000040110a MCGSTATUS 0
MCGCAP c08 APICID 0 SOCKETID 0 
PPIN ee0000000040110a
CPUID Vendor Intel Family 6 Model 142
Hardware event. This is not a software error.
MCE 1
CPU 0 BANK 7 
MISC 7880018086 ADDR fef1ce40 
TIME 1493934959 Fri May  5 00:55:59 2017
MCG status:
MCi status:
Error overflow
Uncorrected error
MCi_MISC register valid
MCi_ADDR register valid
Processor context corrupt
MCA: corrected filtering (some unreported errors in same region)
Generic CACHE Level-2 Generic Error
STATUS ee0000000040110a MCGSTATUS 0
MCGCAP c08 APICID 0 SOCKETID 0 
CPUID Vendor Intel Family 6 Model 142

當我觀看影片時,內部鍵盤有時會凍結一段時間,在此期間我可以使用觸控板移動遊標,但無法點擊。連接外部 USB 滑鼠只會有幫助。當最後一個耳機使用電池電源時,我在將耳機連接到筆記型電腦時遇到了類似的問題。發生這種情況是因為我們的音訊硬體無法正確切換到省電模式。我發現的唯一解決方法這裡。您應該將參數變更INTEL_AUDIO_POWERSAVEfalsein file /usr/lib/pm-utils/power.d/intel-audio-powersave

我猜想與 kabylake 有關係,希望他們盡快檢查並解決問題。

相關內容