drm/i915: split out i915_switcheroo.[ch] from i915_drv.c
authorJani Nikula <jani.nikula@intel.com>
Fri, 4 Oct 2019 12:20:18 +0000 (15:20 +0300)
committerJani Nikula <jani.nikula@intel.com>
Sun, 6 Oct 2019 08:25:00 +0000 (11:25 +0300)
commit63bf8301aac492d4c5fdf7b0ec42b142c05080e3
treeb95cf6714499cfef7e6db1a4c371e0526316bd11
parent7fd296024c3cd06773a1df712b2c50932aeea60b
drm/i915: split out i915_switcheroo.[ch] from i915_drv.c

Split out code related to vga switcheroo register/unregister and state
handling from i915_drv.c into new i915_switcheroo.[ch] files.

It's a bit difficult to draw the line how much to move to the new file
from i915_drv.c, but it seemed to me keeping i915_suspend_switcheroo()
and i915_resume_switcheroo() in place was the cleanest.

No functional changes.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191004122019.12009-2-jani.nikula@intel.com
drivers/gpu/drm/i915/Makefile
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_switcheroo.c [new file with mode: 0644]
drivers/gpu/drm/i915/i915_switcheroo.h [new file with mode: 0644]