2 *-----------------------------------------------------------------------------
5 *-----------------------------------------------------------------------------
6 * Copyright (c) 2002-2010, Intel Corporation.
8 * Permission is hereby granted, free of charge, to any person obtaining a copy
9 * of this software and associated documentation files (the "Software"), to deal
10 * in the Software without restriction, including without limitation the rights
11 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12 * copies of the Software, and to permit persons to whom the Software is
13 * furnished to do so, subject to the following conditions:
15 * The above copyright notice and this permission notice shall be included in
16 * all copies or substantial portions of the Software.
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
26 *-----------------------------------------------------------------------------
29 *-----------------------------------------------------------------------------
40 #define IGD_DEVICE_ON 1
41 #define IGD_DEVICE_OFF 0
43 #define PI_FIRMWARE_EDID 0x1
44 #define PI_FIRMWARE_DISPLAYID 0x2
46 /* get_native_dtd() flags */
47 #define PI_ALL_TIMINGS 0x0001
48 #define PI_SUPPORTED_TIMINGS 0x0002
49 extern unsigned long get_native_dtd(igd_timing_info_t *timing_table,
50 unsigned long flags, pd_timing_t **native_dtd, unsigned long native_flags);
52 extern igd_timing_info_t crt_timing_table[];
53 extern int crt_timing_table_size;
56 extern igd_timing_info_t cea_timing_table[];
57 extern int cea_timing_table_size;
58 extern type_std_t cea_std_lookup[];
59 extern int cea_std_lookup_size;
62 extern int pi_pd_register(pd_driver_t *pd_driver);
63 extern int pi_pd_register(pd_driver_t *pd_driver);
64 extern int pi_read_regs(void *callback_context, pd_reg_t *list,
65 unsigned long reg_type);
66 extern int pi_write_regs(void *callback_context, pd_reg_t *list,
67 unsigned long reg_type);
68 extern int pi_program_port_dvo(igd_display_context_t *, unsigned long);
69 extern int pi_program_port_analog(igd_display_context_t *, unsigned long);
70 extern int pi_program_port_rgba(igd_display_context_t *, unsigned long);
71 extern int pi_program_port_lvds(igd_display_context_t *, unsigned long);
73 /* Function to get attr value from port driver attr list */
74 extern int pi_pd_find_attr_and_value(igd_display_port_t *port,
75 unsigned long attr_id,
77 pd_attr_t **caller_pd_attr,
78 unsigned long * attr_value);
80 /* Function to get attr value from user provided init attribute list */
81 extern int pi_get_port_init_attr(igd_display_port_t *port,
83 unsigned long *value);
84 extern int pi_save_mode_state(igd_display_port_t *port,
85 reg_state_id_t reg_state_id);