<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [NVC1] HDMI audio device only visible after rescan"
href="https://bugs.freedesktop.org/show_bug.cgi?id=75985#c37">Comment # 37</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [NVC1] HDMI audio device only visible after rescan"
href="https://bugs.freedesktop.org/show_bug.cgi?id=75985">bug 75985</a>
from <span class="vcard"><a class="email" href="mailto:lukas@wunner.de" title="Lukas Wunner <lukas@wunner.de>"> <span class="fn">Lukas Wunner</span></a>
</span></b>
<pre>Related to this issue, I've just posted v2 of my patch set to use a device link
for power management of GPU-integrated HDA controllers:
<a href="https://lists.freedesktop.org/archives/dri-devel/2018-March/168012.html">https://lists.freedesktop.org/archives/dri-devel/2018-March/168012.html</a>
It would be great if more people could test it. There's a 4.15-based branch
available at:
<a href="https://github.com/l1k/linux/commits/switcheroo_devlink_v2">https://github.com/l1k/linux/commits/switcheroo_devlink_v2</a>
Crucially, this patch lets the HDA controller autosuspend at its own
descretion, rather than forcing it on whenever the GPU is on. It looks like
writing to bit 25 of config space dword 0x488 powergates the HDA controller. We
could leverage that to runtime suspend the HDA controller to D3cold. I'll see
to it that I cook up a patch.
As to the bit being cleared on boot, I think this should be done in a "header"
PCI quirk rather than in nouveau. If you look at pci_scan_slot() and next_fn()
in drivers/pci/probe.c, you'll notice that device functions are scanned from 0
upwards. So the GPU is always scanned first. Just add a PCI quirk which gets
executed for the GPU, sets the bit and then reinitializes the multifunction
flag in the GPU's struct pci_dev, that may already be sufficient. The PCI core
should do all the rest. See quirk_jmicron_ata() for an example.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>