xref: /netbsd-src/sys/external/bsd/drm2/dist/drm/i915/display/intel_hotplug.h (revision 41ec02673d281bbb3d38e6c78504ce6e30c228c1)
1 /*	$NetBSD: intel_hotplug.h,v 1.2 2021/12/18 23:45:30 riastradh Exp $	*/
2 
3 /* SPDX-License-Identifier: MIT */
4 /*
5  * Copyright © 2019 Intel Corporation
6  */
7 
8 #ifndef __INTEL_HOTPLUG_H__
9 #define __INTEL_HOTPLUG_H__
10 
11 #include <linux/types.h>
12 
13 #include <drm/i915_drm.h>
14 
15 struct drm_i915_private;
16 struct intel_connector;
17 struct intel_encoder;
18 enum port;
19 
20 void intel_hpd_poll_init(struct drm_i915_private *dev_priv);
21 enum intel_hotplug_state intel_encoder_hotplug(struct intel_encoder *encoder,
22 					       struct intel_connector *connector,
23 					       bool irq_received);
24 void intel_hpd_irq_handler(struct drm_i915_private *dev_priv,
25 			   u32 pin_mask, u32 long_mask);
26 void intel_hpd_init(struct drm_i915_private *dev_priv);
27 void intel_hpd_init_work(struct drm_i915_private *dev_priv);
28 void intel_hpd_cancel_work(struct drm_i915_private *dev_priv);
29 enum hpd_pin intel_hpd_pin_default(struct drm_i915_private *dev_priv,
30 				   enum port port);
31 bool intel_hpd_disable(struct drm_i915_private *dev_priv, enum hpd_pin pin);
32 void intel_hpd_enable(struct drm_i915_private *dev_priv, enum hpd_pin pin);
33 
34 #endif /* __INTEL_HOTPLUG_H__ */
35