Bug 252241 - MacBook Pro 8,3 17" black screen after suspend/resume
Summary: MacBook Pro 8,3 17" black screen after suspend/resume
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 12.2-RELEASE
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
Depends on:
Reported: 2020-12-28 22:51 UTC by Jason W. Bacon
Modified: 2020-12-30 20:01 UTC (History)
0 users

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Jason W. Bacon freebsd_committer 2020-12-28 22:51:09 UTC
System suspends and seems to resume fine except for the screen.  I can ssh in after resume, but the console is unresponsive and I cannot switch to a vt.

The system has two GPUs:

    vendor     = 'Intel Corporation'
    device     = '2nd Generation Core Processor Family Integrated Graphics Controller'
    class      = display
    vendor     = 'Advanced Micro Devices, Inc. [AMD/ATI]'
    device     = 'Whistler [Radeon HD 6630M/6650M/6750M/7670M/7690M]'
    class      = display

Both work fine in general.  Running auto-gpu-setup (called from desktop-installer), I first selected the modesetting driver + drm-kmod and got a full-functional desktop.

1.. For most modern Intel GPUs, use the modesetting driver which is part of
    the FreeBSD base.

    pkg install -y drm-kmod
    Add kld_list="/boot/modules/i915kms.ko" to /etc/rc.conf


After testing the Intel GPU setup, ran auto-gpu-setup again and selected option 2, ati driver + drm0kmod:

1.. For recent AMD GPUs, you can try

    pkg install -y drm-kmod xf86-video-amdgpu
    Add "kld_list=amdgpu" to /etc/rc.conf

2.. For older AMD GPUs, you can try

    pkg install -y drm-kmod xf86-video-ati
    Add "kld_list=/boot/modules/radeonkms.ko" to /etc/rc.conf


System booted into a working desktop, but using scfb rather than radeon.

Adding the following got Xorg to use the radeon driver:

<<<ROOT@beluga.acadix>>> /home/bacon 107 # cat /etc/X11/xorg.conf.d/radeon.conf  
Section "Device"
	Identifier  "Card0"
	Driver      "radeon"
	BusID       "PCI:1:0:0"

However, behavior after suspend/resume is the same with either modesetting or radeon.

I reduced the system to nothing but generic kernel + ATP driver for the touchpad and this did not help.

There are quite a few drivers auto-loaded, though.  Seems doubtful to me that any of them are causing the issue since everything seems to work after resume except the screen.

Id Refs Address                Size Name
 1  101 0xffffffff80200000  227ad00 kernel
 2    1 0xffffffff8247b000     9080 atp.ko
 3    1 0xffffffff82fdb000     1a20 fdescfs.ko
 4    1 0xffffffff82fdd000    103f0 fuse.ko
 5    1 0xffffffff82fee000   152fd0 radeonkms.ko
 6    2 0xffffffff83141000    76570 drm.ko
 7    5 0xffffffff831b8000    12d30 linuxkpi.ko
 8    4 0xffffffff831cb000    12f30 linuxkpi_gplv2.ko
 9    2 0xffffffff831de000      6d0 debugfs.ko
10    1 0xffffffff831df000     f181 ttm.ko
11    1 0xffffffff831ef000    33ee0 if_bwn.ko
12   14 0xffffffff83223000    37e48 bhnd.ko
13    2 0xffffffff8325b000     3408 gpiobus.ko
14    4 0xffffffff8325f000     a1f0 bhndb.ko
15    1 0xffffffff8326a000     3c50 bhndb_pci.ko
16    1 0xffffffff8326e000     1a58 bhnd_pci_hostb.ko
17    2 0xffffffff83270000     1b64 bhnd_pci.ko
18    1 0xffffffff83272000      598 bcma_bhndb.ko
19    1 0xffffffff83273000     4818 bcma.ko
20    1 0xffffffff83278000      ad4 siba_bhndb.ko
21    1 0xffffffff83279000     4ea8 siba.ko
22    1 0xffffffff8327e000     a160 if_lagg.ko
23    1 0xffffffff83289000     1860 uhid.ko
24    1 0xffffffff8328b000     1a40 wmt.ko
25    1 0xffffffff8328d000     2908 ums.ko
26    1 0xffffffff83290000     4260 ng_ubt.ko
27    6 0xffffffff83295000     9bd0 netgraph.ko
28    2 0xffffffff8329f000     9128 ng_hci.ko
29    3 0xffffffff832a9000      9b0 ng_bluetooth.ko
30    1 0xffffffff832aa000     29e0 wsp.ko
31    1 0xffffffff832ad000     caf0 ng_l2cap.ko
32    1 0xffffffff832ba000    1af20 ng_btsocket.ko
33    1 0xffffffff832d5000     2150 ng_socket.ko
34    1 0xffffffff832d8000     46f0 autofs.ko
35    1 0xffffffff832dd000      acf mac_ntpd.ko

On the whole, this is a perfectly usable FreeBSD laptop for my purposes.  I don't personally care about suspend/resume on this machine since I don't take it anywhere (I prefer to carry a smaller one), but I'm happy to help diagnose and fix this issue if possible.
Comment 1 Jason W. Bacon freebsd_committer 2020-12-30 20:01:05 UTC
Correction: The modesetting driver was working following a fresh install but since running freebsd-update, it's failing and the system is falling back on scfb.

Should suspend/resume work with the scfb driver?