[Nouveau] Bug Report on A1286 (Macbook Pro Mid 2012)

Lukas Wunner lukas at wunner.de
Tue Nov 29 23:31:03 UTC 2016


On Tue, Nov 29, 2016 at 05:42:51PM -0500, Evan Foss wrote:
> On Sun, Nov 27, 2016 at 4:13 AM, Lukas Wunner <lukas at wunner.de> wrote:
> > On Sat, Nov 26, 2016 at 06:09:34AM +0000, Evan Foss wrote:
> >> I did some other bug reports here a while back. I am back again
> >> because I updated my kernel from 3.19.1 to linux-4.8.10-gentoo (if you
> >> want I can test the mainline too). On boot all my GPU's turn on. If I
> >> turn them off via
> >> echo "OFF"> /sys/kernel/debug/vgaswitcheroo/switch
> >> I can't turn them back on. They also do not turn on if I try to change
> >> GPU's. Trying to stop xdm locks the machine so I can't even turn it
> >> off. Suspend/resume still works. None of these problems existed in
> >> 3.19.1. I know you will need more info to track down the problem but I
> >> wanted to open with this.
> >
> > I have the same machine and it works for me.  System sleep is only
> > supposed to work if both GPUs or ON upon suspend.  Are you issuing
> > OFF while X11 is running?  Does it work if X11 is stopped?
> 
> 1. Boot with the intel GPU driving the screen.
> 2. In mate desktop turn off the nvidia gpu via echo "OFF" >
> /sys/kernel/.../switch
> 3. Try to do any of the following and the machine locks up turn on the
> nvidia GPU, suspend the machine, try to change gpus, stop X (via
> /etc/init.d/xdm stop)
> 
> Yes I issue OFF while it is running and it works perfectly to turn off
> the GPU's. I can tell because the machine gets a lot cooler.

On my machine issuing ON or OFF or switching always works but I only
issue the commands on the console, without X11 running.  Does that
work for you as well?

Manual power control via ON and OFF is a hack, it powers the GPU
up and down behind the PM core's back.  It's a stopgap until
runtime PM works for muxed machines.  That's the reason at least
for the lockup on resume, I know what causes this.  (The PCI core
invalidates the saved_state of the device.)  I don't know why
turning on the GPU or stopping X causes a lockup, presumably on
stopping X the card is accessed even though it's powered down.

There are some half-baked patches for runtime PM on this branch:
https://github.com/l1k/linux/commits/mbp_switcheroo_runpm_wip

Alas, a rework of vga_switcheroo audio handling is necessary to
bring up runtime PM for muxed machines properly:
https://www.mail-archive.com/nouveau@lists.freedesktop.org/msg24997.html

Rafael Wysocki's functional dependencies patches, which are a
prerequisite for this rework, are now queued for 4.10.  I'll
probably look into this in December/January.

Switching while X is running won't work anytime soon, I'm not
working on it and Dave Airlie has basically said that it has no
priority for him:
https://www.mail-archive.com/intel-gfx@lists.freedesktop.org/msg81981.html

On the bright side, you got Thunderbolt when you updated to 4.8 and
in 4.11 it'll even power itself down when nothing is plugged in and
save you 1.7 Watts. ;-)

Best regards,

Lukas


More information about the Nouveau mailing list