diff options
author | Tvrtko Ursulin <tvrtko.ursulin@intel.com> | 2018-07-24 11:29:31 +0100 |
---|---|---|
committer | Tvrtko Ursulin <tvrtko.ursulin@intel.com> | 2018-08-02 11:32:11 +0100 |
commit | b29101e5806e794615685aee51ba526ae90971f5 (patch) | |
tree | 08b6c1c4152e8da3909d482af3153376fbdeec7c /lib/igt_pm.h | |
parent | 9615bbc7259d5113f7ded9419487bd52d1e708b9 (diff) |
lib/igt_pm: Find HDA device when attempting to enable runtime PM
HDA audio device can be present at various PCI paths on different systems
which the existing code did not account for.
Furthermore the failure to enable runtime PM was silent leaving callers
in the dark.
Improve it by auto-locating the PCI path and logging a warning when
something is not as expected.
v2:
* If there is no audio hw/driver there is no failure.
v3:
* Comment.
* Skip non-symlinks.
* Free path on failure and restore.
* Simplify with asprintf. (Chris Wilson)
v4:
* Find snd_hda_intel instance tied with an Intel device.
v5:
* Fix memory leak and silence Valgrind warning.
v6:
* Fix error out logic.
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'lib/igt_pm.h')
0 files changed, 0 insertions, 0 deletions