summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/display/intel_tc.c
diff options
context:
space:
mode:
authorJani Nikula <jani.nikula@intel.com>2019-08-06 14:37:00 +0300
committerJani Nikula <jani.nikula@intel.com>2019-08-07 12:02:02 +0300
commitd0d392a8deed8442191bdf5b2d6bb17e04c928b6 (patch)
treeb64a4e226ba19cad811c55e7e875b3096d7069b8 /drivers/gpu/drm/i915/display/intel_tc.c
parente15fd1bee2a998bffce776dd312108a2676bee57 (diff)
drm/i915/tc: un-inline intel_tc_port_ref_held()
Avoid including the intel_drv.h mega header from other header files to make further header cleanup easier. v2: restore the over-eagerly dropped <linux/types.h> (Imre) Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20190806113700.18816-1-jani.nikula@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_tc.c')
-rw-r--r--drivers/gpu/drm/i915/display/intel_tc.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_tc.c b/drivers/gpu/drm/i915/display/intel_tc.c
index c96a81c2416c..a4d3d2d541c4 100644
--- a/drivers/gpu/drm/i915/display/intel_tc.c
+++ b/drivers/gpu/drm/i915/display/intel_tc.c
@@ -7,6 +7,7 @@
#include "intel_display.h"
#include "intel_dp_mst.h"
#include "intel_tc.h"
+#include "intel_drv.h"
static const char *tc_port_mode_name(enum tc_port_mode mode)
{
@@ -503,6 +504,12 @@ void intel_tc_port_unlock(struct intel_digital_port *dig_port)
wakeref);
}
+bool intel_tc_port_ref_held(struct intel_digital_port *dig_port)
+{
+ return mutex_is_locked(&dig_port->tc_lock) ||
+ dig_port->tc_link_refcount;
+}
+
void intel_tc_port_get_link(struct intel_digital_port *dig_port,
int required_lanes)
{