1494N/A * Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved. 1494N/A * Copyright (c) 2006-2007, 2013, Intel Corporation 1494N/A * Permission is hereby granted, free of charge, to any person obtaining a 1494N/A * copy of this software and associated documentation files (the "Software"), 1494N/A * to deal in the Software without restriction, including without limitation 1494N/A * the rights to use, copy, modify, merge, publish, distribute, sublicense, 1494N/A * and/or sell copies of the Software, and to permit persons to whom the 1494N/A * Software is furnished to do so, subject to the following conditions: 1494N/A * The above copyright notice and this permission notice (including the next 1494N/A * paragraph) shall be included in all copies or substantial portions of the 1494N/A * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 1494N/A * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 1494N/A * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 1494N/A * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 1494N/A * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 1494N/A * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 1494N/A * DEALINGS IN THE SOFTWARE. 1494N/A * Eric Anholt <eric@anholt.net> 1494N/A/* Here's the desired hotplug mode */ 1494N/A /* DPMS state is stored in the connector, which we need in the 1494N/A/* Note: The caller is required to filter out dpms modes not supported by the 1494N/A /* Only need to change hw state when actually enabled */ 1494N/A /* We need the pipe to run for anything but OFF. */ 1494N/A /* We call connector dpms manually below in case pipe dpms doesn't 1494N/A * change due to cloning. */ 1494N/A /* From off to on, enable the pipe first. */ 1494N/A /* The FDI receiver on LPT only supports 8bpc and only has 2 lanes. */ 1494N/A /* LPT FDI RX only supports 8bpc. */ 1494N/A /* For CPT allow 3 pipe config, for others just use A or B */ 1494N/A ;
/* Those bits don't exist here */ 1494N/A /* The first time through, trigger an explicit detection cycle */ 1494N/A /* Check the status to see if both blue and green are on now */ 1494N/A /* Check the status to see if both blue and green are on now */ 1494N/A /* FIXME: debug force function and remove */ 1494N/A * Uses CRT_HOTPLUG_EN and CRT_HOTPLUG_STAT to detect CRT presence. 1494N/A * \return true if CRT is connected. 1494N/A * \return false if CRT is disconnected. 1494N/A * On 4 series desktop, CRT detect sequence need to be done twice 1494N/A * to get a reliable result. 1494N/A /* turn on the FORCE_DETECT */ 1494N/A /* wait for FORCE_DETECT to go off */ 1494N/A /* clear the interrupt we just generated, if any */ 1494N/A /* and put the bits back */ 1494N/A/* local version of intel_ddc_get_modes() to use intel_crt_get_edid() */ 1494N/A * This may be a DVI-I connector with a shared DDC 1494N/A * link between analog and digital outputs, so we 1494N/A * have to check the EDID input spec of the attached device. 1494N/A /* Set the border color to purple. */ 1494N/A /* Wait for next Vblank to substitue 1494N/A * border color for Color info */ 1494N/A * If there isn't any border, add some. 1494N/A /* sample in the vertical border, selecting the larger one */ 1494N/A * Wait for the border to be displayed 1494N/A * Watch ST00 for an entire scanline 1494N/A /* Read the ST00 VGA status register */ 1494N/A /* restore vblank if necessary */ 1494N/A * If more than 3/4 of the scanline detected a monitor, 1494N/A * then it is assumed to be present. This works even on i830, 1494N/A * where there isn't any way to force the border color across 1494N/A /* Restore previous settings */ 1494N/A /* We can not rely on the HPD pin always being correctly wired 1494N/A * up, for example many KVM do not pass it through, and so 1494N/A * only trust an assertion that the monitor is connected. 1494N/A /* Load detection is broken on HPD capable machines. Whoever wants a 1494N/A * broken monitor (without edid) to work behind a broken kvm (that fails 1494N/A * to have the right resistors for HP detection) needs to fix this up. 1494N/A * For now just bail out. */ 1494N/A /* for pre-945g platforms use load detect */ 1494N/A /* OSOL_i915: drm_sysfs_connector_remove(connector); */ 1494N/A /* Try to probe digital port for output in DVI-I -> VGA mode. */ 1494N/A * Routines for controlling stuff on the analog port 1494N/A /* Skip machines without VGA that falsely report hotplug events */ 1494N/A /* OSOL_i915: drm_sysfs_connector_add(connector); */ 1494N/A * Configure the automatic hotplug detection stuff 1494N/A * TODO: find a proper way to discover whether we need to set the the 1494N/A * polarity and link reversal bits or not, instead of relying on the