Macbook Pro 11,4上的待机和关机挂起


14

几周前,我设法在我的2015年中(11,4)Macbook Pro上使Ubuntu Desktop 14.04和Mac OS 10.10.4(Yosemite)双重启动。由于某些原因,计算机在关机和待机状态下挂起。特别:

  • 告诉机器关机(例如,sudo poweroff,sudo shutdown now等)将导致正常的关机例程,直到最后一行“系统现在将停止”。进入这里后,系统冻结,而我只能关闭它的唯一方法是手动按住电源按钮几秒钟以进行硬关机。

  • 让机器处于待机状态会导致其进入黑屏并变得无响应。将其恢复原状的唯一方法是按住电源按钮几秒钟以进行硬关机。重新启动计算机后,我在恢复时收到“检测到系统错误”通知。

一些相关的注意事项:

  • MBP正在运行集成的Intel Iris Pro和用于图形的AMD Radeon R9 M370X组合,我正在使用fglrx-updates的专有驱动程序。我从早期版本的Ubuntu的其他看似相关的案例中知道,问题出在专有的图形驱动程序上。但是,切换回打开的XOrg驱动程序并apt-get清除fglrx-updates不能解决任何一个问题。

  • 如果我尝试休眠而不是待机,则显示会返回并稍后再返回桌面(就像从休眠中唤醒一样)。

  • 重新启动工作正常。实际上,我可以从Ubuntu上彻底关闭计算机的唯一方法是重新启动,然后从rEFInd关闭或引导进入OS X并关闭。

我不确定哪种日志最适合发布(这是我第一次问一个问题),但是如果有人有任何见解,我很乐意尽快找到正确的日志。

更新1:将其置于待机状态实际上会导致屏幕关闭,然后几乎立即打开,然后再次关闭并挂起。返回Ubuntu时收到的系统错误如下:

ProblemType: KernelOops
Annotation: This occured during a previous suspend and prevented it from resuming properly.
Architecture: amd64
Date: Thu Sep 10 22:50:55 2015
DistroRelease: Ubuntu 14.04
ExecutablePath: /usr/share/apport/apportcheckresume
ExecutableTimestamp: 1439395460
Failure: suspend/resume
InterpreterPath: /usr/bin/python3.4
Package: linux-image-3.19.0-25-generic 3.19.0-25.26~14.04.1

我还附有下面的睡眠日志。

Initial commandline parameters: 
Thu Sep 10 22:50:05 EDT 2015: Running hooks for suspend.
Running hook /usr/lib/pm-utils/sleep.d/000kernel-change suspend suspend:
/usr/lib/pm-utils/sleep.d/000kernel-change suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/000record-status suspend suspend:
/usr/lib/pm-utils/sleep.d/000record-status suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/00logging suspend suspend:
Linux fruit 3.19.0-25-generic #26~14.04.1-Ubuntu SMP Fri Jul 24 21:16:20 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
Module                  Size  Used by
nvram                  16384  0 
msr                    16384  0 
btusb                  40960  0 
joydev                 20480  0 
bcm5974                20480  0 
pci_stub               16384  1 
vboxpci                24576  0 
vboxnetadp             28672  0 
vboxnetflt             28672  0 
vboxdrv               450560  3 vboxnetadp,vboxnetflt,vboxpci
xt_CHECKSUM            16384  1 
iptable_mangle         16384  1 
ipt_MASQUERADE         16384  1 
nf_nat_masquerade_ipv4    16384  1 ipt_MASQUERADE
iptable_nat            16384  1 
nf_conntrack_ipv4      16384  1 
nf_defrag_ipv4         16384  1 nf_conntrack_ipv4
nf_nat_ipv4            16384  1 iptable_nat
nf_nat                 24576  2 nf_nat_ipv4,nf_nat_masquerade_ipv4
nf_conntrack          106496  4 nf_nat,nf_nat_ipv4,nf_nat_masquerade_ipv4,nf_conntrack_ipv4
xt_tcpudp              16384  5 
bridge                110592  0 
stp                    16384  1 bridge
llc                    16384  2 stp,bridge
iptable_filter         16384  1 
ip_tables              28672  3 iptable_filter,iptable_mangle,iptable_nat
x_tables               36864  6 xt_CHECKSUM,ip_tables,xt_tcpudp,ipt_MASQUERADE,iptable_filter,iptable_mangle
applesmc               20480  0 
input_polldev          16384  1 applesmc
x86_pkg_temp_thermal    16384  0 
intel_powerclamp       20480  0 
coretemp               16384  0 
kvm_intel             151552  0 
kvm                   479232  1 kvm_intel
brcmfmac              278528  0 
brcmutil               16384  1 brcmfmac
lpc_ich                24576  0 
cfg80211              524288  1 brcmfmac
bdc_pci                16384  0 
mei_me                 20480  0 
mei                    90112  1 mei_me
sbs                    16384  0 
sbshc                  16384  1 sbs
apple_gmux             16384  0 
mac_hid                16384  0 
snd_hda_codec_cirrus    20480  1 
snd_hda_codec_generic    69632  1 snd_hda_codec_cirrus
snd_hda_codec_hdmi     53248  1 
snd_hda_intel          32768  10 
snd_hda_controller     32768  1 snd_hda_intel
snd_hda_codec         143360  5 snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel,snd_hda_controller,snd_hda_codec_cirrus
snd_hwdep              20480  1 snd_hda_codec
fglrx               12460032  127 
snd_pcm               106496  4 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_controller
snd_seq_midi           16384  0 
snd_seq_midi_event     16384  1 snd_seq_midi
snd_rawmidi            32768  1 snd_seq_midi
snd_seq                65536  2 snd_seq_midi_event,snd_seq_midi
snd_seq_device         16384  3 snd_seq,snd_rawmidi,snd_seq_midi
snd_timer              32768  2 snd_pcm,snd_seq
snd                    86016  31 snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_seq,snd_rawmidi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel,snd_seq_device,snd_hda_codec_cirrus
apple_bl               16384  1 apple_gmux
amd_iommu_v2           20480  1 fglrx
soundcore              16384  2 snd,snd_hda_codec
shpchp                 40960  0 
bnep                   20480  2 
rfcomm                 69632  0 
bluetooth             491520  11 bnep,btusb,rfcomm
binfmt_misc            20480  1 
parport_pc             32768  0 
ppdev                  20480  0 
lp                     20480  0 
parport                45056  3 lp,ppdev,parport_pc
nls_iso8859_1          16384  1 
dm_crypt               24576  1 
hid_generic            16384  0 
hid_apple              16384  0 
crct10dif_pclmul       16384  0 
crc32_pclmul           16384  0 
ghash_clmulni_intel    16384  0 
aesni_intel           172032  2 
aes_x86_64             20480  1 aesni_intel
lrw                    16384  1 aesni_intel
gf128mul               16384  1 lrw
glue_helper            16384  1 aesni_intel
ablk_helper            16384  1 aesni_intel
cryptd                 20480  4 ghash_clmulni_intel,aesni_intel,ablk_helper
uas                    24576  0 
usb_storage            69632  1 uas
ahci                   36864  3 
usbhid                 53248  0 
libahci                32768  1 ahci
hid                   110592  3 hid_generic,usbhid,hid_apple
video                  20480  1 apple_gmux
             total       used       free     shared    buffers     cached
Mem:      16306696    1188872   15117824      22748      47276     365684
-/+ buffers/cache:     775912   15530784
Swap:      4194300          0    4194300
/usr/lib/pm-utils/sleep.d/00logging suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/00powersave suspend suspend:
/usr/lib/pm-utils/sleep.d/00powersave suspend suspend: success.

Running hook /etc/pm/sleep.d/10_grub-common suspend suspend:
/etc/pm/sleep.d/10_grub-common suspend suspend: success.

Running hook /etc/pm/sleep.d/10_unattended-upgrades-hibernate suspend suspend:
/etc/pm/sleep.d/10_unattended-upgrades-hibernate suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/49tlp suspend suspend:
/usr/lib/pm-utils/sleep.d/49tlp suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/50unload_alx suspend suspend:
/usr/lib/pm-utils/sleep.d/50unload_alx suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/60_wpa_supplicant suspend suspend:
Failed to connect to non-global ctrl_ifname: (null)  error: No such file or directory
/usr/lib/pm-utils/sleep.d/60_wpa_supplicant suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/75modules suspend suspend:
/usr/lib/pm-utils/sleep.d/75modules suspend suspend: not applicable.

Running hook /usr/lib/pm-utils/sleep.d/90clock suspend suspend:
/usr/lib/pm-utils/sleep.d/90clock suspend suspend: not applicable.

Running hook /usr/lib/pm-utils/sleep.d/94cpufreq suspend suspend:
/usr/lib/pm-utils/sleep.d/94cpufreq suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/95anacron suspend suspend:
stop: Unknown instance: 
/usr/lib/pm-utils/sleep.d/95anacron suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/95hdparm-apm suspend suspend:
/usr/lib/pm-utils/sleep.d/95hdparm-apm suspend suspend: not applicable.

Running hook /usr/lib/pm-utils/sleep.d/95led suspend suspend:
/usr/lib/pm-utils/sleep.d/95led suspend suspend: not applicable.

Running hook /usr/lib/pm-utils/sleep.d/98video-quirk-db-handler suspend suspend:
ATI Catalyst driver detected, not using quirks.
/usr/lib/pm-utils/sleep.d/98video-quirk-db-handler suspend suspend: success.

Running hook /usr/lib/pm-utils/sleep.d/99video suspend suspend:
kernel.acpi_video_flags = 0
/usr/lib/pm-utils/sleep.d/99video suspend suspend: success.

Running hook /etc/pm/sleep.d/novatel_3g_suspend suspend suspend:
/etc/pm/sleep.d/novatel_3g_suspend suspend suspend: success.

Thu Sep 10 22:50:06 EDT 2015: performing suspend

更新2:看来此问题可能会扩展到Ubuntu以外。我不确定如何开始调试它。有什么想法吗??

https://forums.gentoo.org/viewtopic-p-7772846.html?sid=7ab6dd35c3dfc7a38a2c1b02edb15044

https://bbs.archlinux.org/viewtopic.php?id=199388


1
这听起来像Mac的硬件具有与Ubuntu所提供的ACPI命令不同的问题。我想知道是否还有其他人遇到这个问题,我也想知道您是如何使其工作的……
Daniel

我刚购买了相同的型号,但遇到了相同的问题。
E3L_1

同样的问题,MBP 11,5合上盖子会导致两件事:崩溃,重新打开它需要硬关机(电源按钮)才能重新启动,并且当盖子合上时,笔记本电脑变得很热。令人讨厌的是,我需要定期在两堂课之间移动笔记本电脑
Tom B

2
同样会影响具有模型11,4的15英寸视网膜(efi启动Ubuntu 15.10)
tomodachi

2
请查看正在跟踪Macbook Pro 11,5的页面。这个问题仍然没有解决,但是其他一些在最近的内核中已经解决。
Aleksandr Dubinsky

Answers:


7

事实证明,这是最新的主线linux内核中的MacbookPro 11,4和11,5的一个已记录的问题(在撰写本文时,我认为直到4.6为止)。有一种解决方法需要修补/编译自定义内核。它位于https://bugzilla.kernel.org/show_bug.cgi?id=103211的评论#172中。特别,

diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index ee72ebe..d3ec833 100644
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -2775,6 +2775,13 @@ static void quirk_hotplug_bridge(struct pci_dev *dev)

 DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_HINT, 0x0020, quirk_hotplug_bridge);

+static void quirk_hotplug_bridge_skip(struct pci_dev *dev)
+{
+       dev->is_hotplug_bridge = 0;
+}
+
+DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x8c10, quirk_hotplug_bridge_skip);
+
 /*
  * This is a quirk for the Ricoh MMC controller found as a part of
  * some mulifunction chips.

从评论中可以看出,似乎有少数人确认了它确实可以在Ubuntu 14.04和16.04中使用Linux内核的不同4.X版本。我现在在16.04上对此进行测试,如果一切正常,将接受此答案。如果其他人愿意在内核较早的版本(3.X)上在14.04上确认此补丁,请在下面发表评论。

更新:我可以确认这在带有内核v4.4.0-28-generic的Ubuntu 16.04中可以使用。我做了以下步骤:

一切似乎都按预期进行。


现在,这似乎已包含在4.4内核的较新版本中(至少从4.4.0-63-generic开始)。
Christian Fritz

我在Ubuntu 16.04上仍存在4.4.0-64的挂起问题。我猜这一定是由其他问题引起的:-(
Brad Pitcher

0

我在https://joshtronic.com/2017/03/13/getting-suspend-in-linux-working-on-a-macbook-pro/找到了一个解决方案-适用于我(在16.04LTS上)的是将以下内容添加到/etc/rc.local

#!/bin/sh -e
echo LID0 > /proc/acpi/wakeup
echo XHC1 > /proc/acpi/wakeup
exit 0

我建议您在添加到文件之前手动进行测试。这可以通过sudo -i依次运行各个行来完成。


echo LID0 > /proc/acpi/wakeup只需翻转一下是否LID0应该引起唤醒。


可悲的副作用是,打开机盖后,计算机将无法再开机

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.