2 * Copyright © 2006-2007 Intel Corporation
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice (including the next
12 * paragraph) shall be included in all copies or substantial portions of the
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 * DEALINGS IN THE SOFTWARE.
24 * Eric Anholt <eric@anholt.net>
27 #include <linux/dmi.h>
28 #include <linux/i2c.h>
29 #include <linux/slab.h>
33 #include "drm_crtc_helper.h"
35 #include "intel_drv.h"
39 /* Here's the desired hotplug mode */
40 #define ADPA_HOTPLUG_BITS (ADPA_CRT_HOTPLUG_PERIOD_128 | \
41 ADPA_CRT_HOTPLUG_WARMUP_10MS | \
42 ADPA_CRT_HOTPLUG_SAMPLE_4S | \
43 ADPA_CRT_HOTPLUG_VOLTAGE_50 | \
44 ADPA_CRT_HOTPLUG_VOLREF_325MV | \
45 ADPA_CRT_HOTPLUG_ENABLE)
48 struct intel_encoder base
;
49 bool force_hotplug_required
;
52 static struct intel_crt
*intel_attached_crt(struct drm_connector
*connector
)
54 return container_of(intel_attached_encoder(connector
),
55 struct intel_crt
, base
);
58 static void pch_crt_dpms(struct drm_encoder
*encoder
, int mode
)
60 struct drm_device
*dev
= encoder
->dev
;
61 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
64 temp
= I915_READ(PCH_ADPA
);
65 temp
&= ~ADPA_DAC_ENABLE
;
68 case DRM_MODE_DPMS_ON
:
69 temp
|= ADPA_DAC_ENABLE
;
71 case DRM_MODE_DPMS_STANDBY
:
72 case DRM_MODE_DPMS_SUSPEND
:
73 case DRM_MODE_DPMS_OFF
:
74 /* Just leave port enable cleared */
78 I915_WRITE(PCH_ADPA
, temp
);
81 static void gmch_crt_dpms(struct drm_encoder
*encoder
, int mode
)
83 struct drm_device
*dev
= encoder
->dev
;
84 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
87 temp
= I915_READ(ADPA
);
88 temp
&= ~(ADPA_HSYNC_CNTL_DISABLE
| ADPA_VSYNC_CNTL_DISABLE
);
89 temp
&= ~ADPA_DAC_ENABLE
;
92 case DRM_MODE_DPMS_ON
:
93 temp
|= ADPA_DAC_ENABLE
;
95 case DRM_MODE_DPMS_STANDBY
:
96 temp
|= ADPA_DAC_ENABLE
| ADPA_HSYNC_CNTL_DISABLE
;
98 case DRM_MODE_DPMS_SUSPEND
:
99 temp
|= ADPA_DAC_ENABLE
| ADPA_VSYNC_CNTL_DISABLE
;
101 case DRM_MODE_DPMS_OFF
:
102 temp
|= ADPA_HSYNC_CNTL_DISABLE
| ADPA_VSYNC_CNTL_DISABLE
;
106 I915_WRITE(ADPA
, temp
);
109 static int intel_crt_mode_valid(struct drm_connector
*connector
,
110 struct drm_display_mode
*mode
)
112 struct drm_device
*dev
= connector
->dev
;
115 if (mode
->flags
& DRM_MODE_FLAG_DBLSCAN
)
116 return MODE_NO_DBLESCAN
;
118 if (mode
->clock
< 25000)
119 return MODE_CLOCK_LOW
;
125 if (mode
->clock
> max_clock
)
126 return MODE_CLOCK_HIGH
;
131 static bool intel_crt_mode_fixup(struct drm_encoder
*encoder
,
132 struct drm_display_mode
*mode
,
133 struct drm_display_mode
*adjusted_mode
)
138 static void intel_crt_mode_set(struct drm_encoder
*encoder
,
139 struct drm_display_mode
*mode
,
140 struct drm_display_mode
*adjusted_mode
)
143 struct drm_device
*dev
= encoder
->dev
;
144 struct drm_crtc
*crtc
= encoder
->crtc
;
145 struct intel_crtc
*intel_crtc
= to_intel_crtc(crtc
);
146 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
151 dpll_md_reg
= DPLL_MD(intel_crtc
->pipe
);
153 if (HAS_PCH_SPLIT(dev
))
159 * Disable separate mode multiplier used when cloning SDVO to CRT
160 * XXX this needs to be adjusted when we really are cloning
162 if (INTEL_INFO(dev
)->gen
>= 4 && !HAS_PCH_SPLIT(dev
)) {
163 dpll_md
= I915_READ(dpll_md_reg
);
164 I915_WRITE(dpll_md_reg
,
165 dpll_md
& ~DPLL_MD_UDI_MULTIPLIER_MASK
);
168 adpa
= ADPA_HOTPLUG_BITS
;
169 if (adjusted_mode
->flags
& DRM_MODE_FLAG_PHSYNC
)
170 adpa
|= ADPA_HSYNC_ACTIVE_HIGH
;
171 if (adjusted_mode
->flags
& DRM_MODE_FLAG_PVSYNC
)
172 adpa
|= ADPA_VSYNC_ACTIVE_HIGH
;
174 /* For CPT allow 3 pipe config, for others just use A or B */
175 if (HAS_PCH_CPT(dev
))
176 adpa
|= PORT_TRANS_SEL_CPT(intel_crtc
->pipe
);
177 else if (intel_crtc
->pipe
== 0)
178 adpa
|= ADPA_PIPE_A_SELECT
;
180 adpa
|= ADPA_PIPE_B_SELECT
;
182 if (!HAS_PCH_SPLIT(dev
))
183 I915_WRITE(BCLRPAT(intel_crtc
->pipe
), 0);
185 I915_WRITE(adpa_reg
, adpa
);
188 static bool intel_ironlake_crt_detect_hotplug(struct drm_connector
*connector
)
190 struct drm_device
*dev
= connector
->dev
;
191 struct intel_crt
*crt
= intel_attached_crt(connector
);
192 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
196 /* The first time through, trigger an explicit detection cycle */
197 if (crt
->force_hotplug_required
) {
198 bool turn_off_dac
= HAS_PCH_SPLIT(dev
);
201 crt
->force_hotplug_required
= 0;
203 save_adpa
= adpa
= I915_READ(PCH_ADPA
);
204 DRM_DEBUG_KMS("trigger hotplug detect cycle: adpa=0x%x\n", adpa
);
206 adpa
|= ADPA_CRT_HOTPLUG_FORCE_TRIGGER
;
208 adpa
&= ~ADPA_DAC_ENABLE
;
210 I915_WRITE(PCH_ADPA
, adpa
);
212 if (wait_for((I915_READ(PCH_ADPA
) & ADPA_CRT_HOTPLUG_FORCE_TRIGGER
) == 0,
214 DRM_DEBUG_KMS("timed out waiting for FORCE_TRIGGER");
217 I915_WRITE(PCH_ADPA
, save_adpa
);
218 POSTING_READ(PCH_ADPA
);
222 /* Check the status to see if both blue and green are on now */
223 adpa
= I915_READ(PCH_ADPA
);
224 if ((adpa
& ADPA_CRT_HOTPLUG_MONITOR_MASK
) != 0)
228 DRM_DEBUG_KMS("ironlake hotplug adpa=0x%x, result %d\n", adpa
, ret
);
233 static bool valleyview_crt_detect_hotplug(struct drm_connector
*connector
)
235 struct drm_device
*dev
= connector
->dev
;
236 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
241 save_adpa
= adpa
= I915_READ(ADPA
);
242 DRM_DEBUG_KMS("trigger hotplug detect cycle: adpa=0x%x\n", adpa
);
244 adpa
|= ADPA_CRT_HOTPLUG_FORCE_TRIGGER
;
246 I915_WRITE(ADPA
, adpa
);
248 if (wait_for((I915_READ(ADPA
) & ADPA_CRT_HOTPLUG_FORCE_TRIGGER
) == 0,
250 DRM_DEBUG_KMS("timed out waiting for FORCE_TRIGGER");
251 I915_WRITE(ADPA
, save_adpa
);
254 /* Check the status to see if both blue and green are on now */
255 adpa
= I915_READ(ADPA
);
256 if ((adpa
& ADPA_CRT_HOTPLUG_MONITOR_MASK
) != 0)
261 DRM_DEBUG_KMS("valleyview hotplug adpa=0x%x, result %d\n", adpa
, ret
);
263 /* FIXME: debug force function and remove */
270 * Uses CRT_HOTPLUG_EN and CRT_HOTPLUG_STAT to detect CRT presence.
272 * Not for i915G/i915GM
274 * \return true if CRT is connected.
275 * \return false if CRT is disconnected.
277 static bool intel_crt_detect_hotplug(struct drm_connector
*connector
)
279 struct drm_device
*dev
= connector
->dev
;
280 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
281 u32 hotplug_en
, orig
, stat
;
285 if (HAS_PCH_SPLIT(dev
))
286 return intel_ironlake_crt_detect_hotplug(connector
);
288 if (IS_VALLEYVIEW(dev
))
289 return valleyview_crt_detect_hotplug(connector
);
292 * On 4 series desktop, CRT detect sequence need to be done twice
293 * to get a reliable result.
296 if (IS_G4X(dev
) && !IS_GM45(dev
))
300 hotplug_en
= orig
= I915_READ(PORT_HOTPLUG_EN
);
301 hotplug_en
|= CRT_HOTPLUG_FORCE_DETECT
;
303 for (i
= 0; i
< tries
; i
++) {
304 /* turn on the FORCE_DETECT */
305 I915_WRITE(PORT_HOTPLUG_EN
, hotplug_en
);
306 /* wait for FORCE_DETECT to go off */
307 if (wait_for((I915_READ(PORT_HOTPLUG_EN
) &
308 CRT_HOTPLUG_FORCE_DETECT
) == 0,
310 DRM_DEBUG_KMS("timed out waiting for FORCE_DETECT to go off");
313 stat
= I915_READ(PORT_HOTPLUG_STAT
);
314 if ((stat
& CRT_HOTPLUG_MONITOR_MASK
) != CRT_HOTPLUG_MONITOR_NONE
)
317 /* clear the interrupt we just generated, if any */
318 I915_WRITE(PORT_HOTPLUG_STAT
, CRT_HOTPLUG_INT_STATUS
);
320 /* and put the bits back */
321 I915_WRITE(PORT_HOTPLUG_EN
, orig
);
326 static bool intel_crt_detect_ddc(struct drm_connector
*connector
)
328 struct intel_crt
*crt
= intel_attached_crt(connector
);
329 struct drm_i915_private
*dev_priv
= crt
->base
.base
.dev
->dev_private
;
331 /* CRT should always be at 0, but check anyway */
332 if (crt
->base
.type
!= INTEL_OUTPUT_ANALOG
)
335 if (intel_ddc_probe(&crt
->base
, dev_priv
->crt_ddc_pin
)) {
337 bool is_digital
= false;
338 struct i2c_adapter
*i2c
;
340 i2c
= intel_gmbus_get_adapter(dev_priv
, dev_priv
->crt_ddc_pin
);
341 edid
= drm_get_edid(connector
, i2c
);
343 * This may be a DVI-I connector with a shared DDC
344 * link between analog and digital outputs, so we
345 * have to check the EDID input spec of the attached device.
347 * On the other hand, what should we do if it is a broken EDID?
350 is_digital
= edid
->input
& DRM_EDID_INPUT_DIGITAL
;
351 connector
->display_info
.raw_edid
= NULL
;
356 DRM_DEBUG_KMS("CRT detected via DDC:0x50 [EDID]\n");
359 DRM_DEBUG_KMS("CRT not detected via DDC:0x50 [EDID reports a digital panel]\n");
366 static enum drm_connector_status
367 intel_crt_load_detect(struct intel_crt
*crt
)
369 struct drm_device
*dev
= crt
->base
.base
.dev
;
370 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
371 uint32_t pipe
= to_intel_crtc(crt
->base
.base
.crtc
)->pipe
;
372 uint32_t save_bclrpat
;
373 uint32_t save_vtotal
;
374 uint32_t vtotal
, vactive
;
376 uint32_t vblank
, vblank_start
, vblank_end
;
378 uint32_t bclrpat_reg
;
382 uint32_t pipeconf_reg
;
383 uint32_t pipe_dsl_reg
;
385 enum drm_connector_status status
;
387 DRM_DEBUG_KMS("starting load-detect on CRT\n");
389 bclrpat_reg
= BCLRPAT(pipe
);
390 vtotal_reg
= VTOTAL(pipe
);
391 vblank_reg
= VBLANK(pipe
);
392 vsync_reg
= VSYNC(pipe
);
393 pipeconf_reg
= PIPECONF(pipe
);
394 pipe_dsl_reg
= PIPEDSL(pipe
);
396 save_bclrpat
= I915_READ(bclrpat_reg
);
397 save_vtotal
= I915_READ(vtotal_reg
);
398 vblank
= I915_READ(vblank_reg
);
400 vtotal
= ((save_vtotal
>> 16) & 0xfff) + 1;
401 vactive
= (save_vtotal
& 0x7ff) + 1;
403 vblank_start
= (vblank
& 0xfff) + 1;
404 vblank_end
= ((vblank
>> 16) & 0xfff) + 1;
406 /* Set the border color to purple. */
407 I915_WRITE(bclrpat_reg
, 0x500050);
410 uint32_t pipeconf
= I915_READ(pipeconf_reg
);
411 I915_WRITE(pipeconf_reg
, pipeconf
| PIPECONF_FORCE_BORDER
);
412 POSTING_READ(pipeconf_reg
);
413 /* Wait for next Vblank to substitue
414 * border color for Color info */
415 intel_wait_for_vblank(dev
, pipe
);
416 st00
= I915_READ8(VGA_MSR_WRITE
);
417 status
= ((st00
& (1 << 4)) != 0) ?
418 connector_status_connected
:
419 connector_status_disconnected
;
421 I915_WRITE(pipeconf_reg
, pipeconf
);
423 bool restore_vblank
= false;
427 * If there isn't any border, add some.
428 * Yes, this will flicker
430 if (vblank_start
<= vactive
&& vblank_end
>= vtotal
) {
431 uint32_t vsync
= I915_READ(vsync_reg
);
432 uint32_t vsync_start
= (vsync
& 0xffff) + 1;
434 vblank_start
= vsync_start
;
435 I915_WRITE(vblank_reg
,
437 ((vblank_end
- 1) << 16));
438 restore_vblank
= true;
440 /* sample in the vertical border, selecting the larger one */
441 if (vblank_start
- vactive
>= vtotal
- vblank_end
)
442 vsample
= (vblank_start
+ vactive
) >> 1;
444 vsample
= (vtotal
+ vblank_end
) >> 1;
447 * Wait for the border to be displayed
449 while (I915_READ(pipe_dsl_reg
) >= vactive
)
451 while ((dsl
= I915_READ(pipe_dsl_reg
)) <= vsample
)
454 * Watch ST00 for an entire scanline
460 /* Read the ST00 VGA status register */
461 st00
= I915_READ8(VGA_MSR_WRITE
);
464 } while ((I915_READ(pipe_dsl_reg
) == dsl
));
466 /* restore vblank if necessary */
468 I915_WRITE(vblank_reg
, vblank
);
470 * If more than 3/4 of the scanline detected a monitor,
471 * then it is assumed to be present. This works even on i830,
472 * where there isn't any way to force the border color across
475 status
= detect
* 4 > count
* 3 ?
476 connector_status_connected
:
477 connector_status_disconnected
;
480 /* Restore previous settings */
481 I915_WRITE(bclrpat_reg
, save_bclrpat
);
486 static enum drm_connector_status
487 intel_crt_detect(struct drm_connector
*connector
, bool force
)
489 struct drm_device
*dev
= connector
->dev
;
490 struct intel_crt
*crt
= intel_attached_crt(connector
);
491 enum drm_connector_status status
;
492 struct intel_load_detect_pipe tmp
;
494 if (I915_HAS_HOTPLUG(dev
)) {
495 /* We can not rely on the HPD pin always being correctly wired
496 * up, for example many KVM do not pass it through, and so
497 * only trust an assertion that the monitor is connected.
499 if (intel_crt_detect_hotplug(connector
)) {
500 DRM_DEBUG_KMS("CRT detected via hotplug\n");
501 return connector_status_connected
;
503 DRM_DEBUG_KMS("CRT not detected via hotplug\n");
506 if (intel_crt_detect_ddc(connector
))
507 return connector_status_connected
;
509 /* Load detection is broken on HPD capable machines. Whoever wants a
510 * broken monitor (without edid) to work behind a broken kvm (that fails
511 * to have the right resistors for HP detection) needs to fix this up.
512 * For now just bail out. */
513 if (I915_HAS_HOTPLUG(dev
))
514 return connector_status_disconnected
;
517 return connector
->status
;
519 /* for pre-945g platforms use load detect */
520 if (intel_get_load_detect_pipe(&crt
->base
, connector
, NULL
,
522 if (intel_crt_detect_ddc(connector
))
523 status
= connector_status_connected
;
525 status
= intel_crt_load_detect(crt
);
526 intel_release_load_detect_pipe(&crt
->base
, connector
,
529 status
= connector_status_unknown
;
534 static void intel_crt_destroy(struct drm_connector
*connector
)
536 drm_sysfs_connector_remove(connector
);
537 drm_connector_cleanup(connector
);
541 static int intel_crt_get_modes(struct drm_connector
*connector
)
543 struct drm_device
*dev
= connector
->dev
;
544 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
546 struct i2c_adapter
*i2c
;
548 i2c
= intel_gmbus_get_adapter(dev_priv
, dev_priv
->crt_ddc_pin
);
549 ret
= intel_ddc_get_modes(connector
, i2c
);
550 if (ret
|| !IS_G4X(dev
))
553 /* Try to probe digital port for output in DVI-I -> VGA mode. */
554 i2c
= intel_gmbus_get_adapter(dev_priv
, GMBUS_PORT_DPB
);
555 return intel_ddc_get_modes(connector
, i2c
);
558 static int intel_crt_set_property(struct drm_connector
*connector
,
559 struct drm_property
*property
,
565 static void intel_crt_reset(struct drm_connector
*connector
)
567 struct drm_device
*dev
= connector
->dev
;
568 struct intel_crt
*crt
= intel_attached_crt(connector
);
570 if (HAS_PCH_SPLIT(dev
))
571 crt
->force_hotplug_required
= 1;
575 * Routines for controlling stuff on the analog port
578 static const struct drm_encoder_helper_funcs pch_encoder_funcs
= {
579 .mode_fixup
= intel_crt_mode_fixup
,
580 .prepare
= intel_encoder_prepare
,
581 .commit
= intel_encoder_commit
,
582 .mode_set
= intel_crt_mode_set
,
583 .dpms
= pch_crt_dpms
,
586 static const struct drm_encoder_helper_funcs gmch_encoder_funcs
= {
587 .mode_fixup
= intel_crt_mode_fixup
,
588 .prepare
= intel_encoder_prepare
,
589 .commit
= intel_encoder_commit
,
590 .mode_set
= intel_crt_mode_set
,
591 .dpms
= gmch_crt_dpms
,
594 static const struct drm_connector_funcs intel_crt_connector_funcs
= {
595 .reset
= intel_crt_reset
,
596 .dpms
= drm_helper_connector_dpms
,
597 .detect
= intel_crt_detect
,
598 .fill_modes
= drm_helper_probe_single_connector_modes
,
599 .destroy
= intel_crt_destroy
,
600 .set_property
= intel_crt_set_property
,
603 static const struct drm_connector_helper_funcs intel_crt_connector_helper_funcs
= {
604 .mode_valid
= intel_crt_mode_valid
,
605 .get_modes
= intel_crt_get_modes
,
606 .best_encoder
= intel_best_encoder
,
609 static const struct drm_encoder_funcs intel_crt_enc_funcs
= {
610 .destroy
= intel_encoder_destroy
,
613 static int __init
intel_no_crt_dmi_callback(const struct dmi_system_id
*id
)
615 DRM_INFO("Skipping CRT initialization for %s\n", id
->ident
);
619 static const struct dmi_system_id intel_no_crt
[] = {
621 .callback
= intel_no_crt_dmi_callback
,
624 DMI_MATCH(DMI_SYS_VENDOR
, "ACER"),
625 DMI_MATCH(DMI_PRODUCT_NAME
, "ZGB"),
631 void intel_crt_init(struct drm_device
*dev
)
633 struct drm_connector
*connector
;
634 struct intel_crt
*crt
;
635 struct intel_connector
*intel_connector
;
636 struct drm_i915_private
*dev_priv
= dev
->dev_private
;
637 const struct drm_encoder_helper_funcs
*encoder_helper_funcs
;
639 /* Skip machines without VGA that falsely report hotplug events */
640 if (dmi_check_system(intel_no_crt
))
643 crt
= kzalloc(sizeof(struct intel_crt
), GFP_KERNEL
);
647 intel_connector
= kzalloc(sizeof(struct intel_connector
), GFP_KERNEL
);
648 if (!intel_connector
) {
653 connector
= &intel_connector
->base
;
654 drm_connector_init(dev
, &intel_connector
->base
,
655 &intel_crt_connector_funcs
, DRM_MODE_CONNECTOR_VGA
);
657 drm_encoder_init(dev
, &crt
->base
.base
, &intel_crt_enc_funcs
,
658 DRM_MODE_ENCODER_DAC
);
660 intel_connector_attach_encoder(intel_connector
, &crt
->base
);
662 crt
->base
.type
= INTEL_OUTPUT_ANALOG
;
663 crt
->base
.clone_mask
= (1 << INTEL_SDVO_NON_TV_CLONE_BIT
|
664 1 << INTEL_ANALOG_CLONE_BIT
|
665 1 << INTEL_SDVO_LVDS_CLONE_BIT
);
667 crt
->base
.crtc_mask
= (1 << 0);
669 crt
->base
.crtc_mask
= (1 << 0) | (1 << 1);
672 connector
->interlace_allowed
= 0;
674 connector
->interlace_allowed
= 1;
675 connector
->doublescan_allowed
= 0;
677 if (HAS_PCH_SPLIT(dev
))
678 encoder_helper_funcs
= &pch_encoder_funcs
;
680 encoder_helper_funcs
= &gmch_encoder_funcs
;
682 drm_encoder_helper_add(&crt
->base
.base
, encoder_helper_funcs
);
683 drm_connector_helper_add(connector
, &intel_crt_connector_helper_funcs
);
685 drm_sysfs_connector_add(connector
);
687 if (I915_HAS_HOTPLUG(dev
))
688 connector
->polled
= DRM_CONNECTOR_POLL_HPD
;
690 connector
->polled
= DRM_CONNECTOR_POLL_CONNECT
;
693 * Configure the automatic hotplug detection stuff
695 crt
->force_hotplug_required
= 0;
696 if (HAS_PCH_SPLIT(dev
)) {
699 adpa
= I915_READ(PCH_ADPA
);
700 adpa
&= ~ADPA_CRT_HOTPLUG_MASK
;
701 adpa
|= ADPA_HOTPLUG_BITS
;
702 I915_WRITE(PCH_ADPA
, adpa
);
703 POSTING_READ(PCH_ADPA
);
705 DRM_DEBUG_KMS("pch crt adpa set to 0x%x\n", adpa
);
706 crt
->force_hotplug_required
= 1;
709 dev_priv
->hotplug_supported_mask
|= CRT_HOTPLUG_INT_STATUS
;