2 *-----------------------------------------------------------------------------
3 * Filename: user_config.c
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 *-----------------------------------------------------------------------------
28 * A file that contains the initial display configuration information of the
29 * EMGD kernel module. A user can edit this file in order to affect the way
30 * that the kernel initially configures the displays. This file is compiled
31 * into the EMGD kernel module.
32 *-----------------------------------------------------------------------------
34 #include "user_config.h"
37 #warning **** This driver has NOT been configured for your system. You are
38 #warning **** building with a sample user_config.c configuration that may or
39 #warning **** may not meet your needs. It is recommended that you run CED to
40 #warning **** generate an appropriate configuration or see the User Guide
41 #warning **** for more information about driver configuration.
46 * One array of igd_display_info_t structures should exist for each port that
47 * needs to provide a DTD list. Each igd_display_info_t contains the DTD
48 * information for a given resolution/refresh-rate. This is especially needed
49 * for analog/VGA ports.
56 static igd_display_info_t dtd_config1_port4_dtdlist[] = {
60 60, /* Refresh Rate */
61 72300, /* Dot Clock */
62 1525, /* Horizontal Total (horizontal synch end) */
63 1365, /* Horizontal Blank Start (h_active-1) */
64 1525, /* Horizontal Blank End (start + h_blank) */
65 1413, /* Horizontal Sync Start (h_active+h_synch-1) */
66 1445, /* Horizontal Sync End (start + h_syncp) */
67 789, /* Vertical Total (Vertical synch end) */
68 767, /* Vertical Blank Start (v_active-1) */
69 789, /* Vertical Blank End (start + v_blank) */
70 770, /* Vertical Sync Start (v_active+v_synch-1) */
71 775, /* Vertical Sync End (start + v_synchp) */
76 NULL, /* pd extension pointer */
77 0, 0 /* mode extension pointer */
83 static igd_display_info_t dtd_config1_port4_dtdlist[] = {
87 60, /* Refresh Rate */
88 65000, /* Dot Clock (in KHz) */
89 1343, /* Horizontal Total (horizontal synch end) */
90 1023, /* Horizontal Blank Start (h_active-1) */
91 1343, /* Horizontal Blank End (start + h_blank) */
92 1047, /* Horizontal Sync Start (h_active+h_synch-1) */
93 1183, /* Horizontal Sync End (start + h_syncp) */
94 805, /* Vertical Total (Vertical synch end) */
95 767, /* Vertical Blank Start (v_active-1) */
96 805, /* Vertical Blank End (start + v_blank) */
97 770, /* Vertical Sync Start (v_active+v_synch-1) */
98 776, /* Vertical Sync End (start + v_synchp) */
103 NULL, /* pd extension pointer */
104 0, 0 /* mode extension pointer */
109 static igd_param_attr_t attrs_config1_port4[] = {
119 static emgd_drm_splash_screen_t splash_screen_data = {
120 0x000000, /* bg_color */
127 static emgd_drm_splash_video_t splash_video_data = {
129 0, /* pixel_format */
139 static igd_param_t config_params_config1 = {
140 1*256*1024, /* Page request */
141 0, /* Max frame buffer size */
142 1, /* Preserve registers */
143 0x6, /* Display flags */
144 { 4, 2, 0, 0, 0 }, /* Display port order */
145 { /* Display Params */
147 4, /* Display port number */
148 0x180, /* Parameters present */
150 0x5, /* Flags when EDID is available */
151 0x5, /* Flags when EDID is not available */
152 0, /* DDC GPIO pins */
155 0, /* I2C GPIO pins */
158 { /* Flat Panel Info */
159 0, /* Flat Panel width */
160 0, /* Flat Panel height */
161 0, /* Flat Panel power method */
162 0, /* VDD active & DVO clock/data active */
163 0, /* DVO clock/data active & backlight enable */
164 0, /* backlight disable & DVO clock/data inactive */
165 0, /* DVO clock/data inactive & VDD inactive */
166 0 /* VDD inactive & VDD active */
169 sizeof(dtd_config1_port4_dtdlist)/sizeof(igd_display_info_t), /* Number of DTDs */
170 dtd_config1_port4_dtdlist /* DTD name */
172 { /* Attribute Info */
173 sizeof(attrs_config1_port4)/sizeof(igd_param_attr_t), /* Number of attributes */
174 attrs_config1_port4 /* Attr name */
178 2, /* Display port number */
179 0x0, /* Parameters present */
181 0x5, /* Flags when EDID is available */
182 0x5, /* Flags when EDID is not available */
183 0, /* DDC GPIO pins */
186 0, /* I2C GPIO pins */
189 { /* Flat Panel Info */
190 0, /* Flat Panel width */
191 0, /* Flat Panel height */
192 0, /* Flat Panel power method */
193 0, /* VDD active & DVO clock/data active */
194 0, /* DVO clock/data active & backlight enable */
195 0, /* backlight disable & DVO clock/data inactive */
196 0, /* DVO clock/data inactive & VDD inactive */
197 0 /* VDD inactive & VDD active */
202 { /* Attribute Info */
207 0, /* 24-bit RGB color that framebuffer is cleared to */
208 1, /* Quickboot (1 = enabled) */
209 0, /* Quickboot seamless (1 = enabled) */
210 0, /* Quickboot video input (1 = enabled) */
211 0 /* Polling (1 = override interrupt support and use polling) */
214 igd_param_t *config_params = {&config_params_config1};
217 * The emgd_drm_config_t structure is the main configuration structure
218 * for the EMGD kernel module.
220 emgd_drm_config_t config_drm = {
221 0, /* Whether to initialize the display at EMGD module startup time
222 * (corresponds to the "init" module parameter)
224 1, /* The display configuration to use if initializing the display
225 * (corresponds to the "init" module parameter), where:
226 * - 1 = Single port/display
227 * - 2 = Cloned port/display (e.g. LVDS + CRT with different timings)
228 * - 4 = Twin ports/displays (e.g. LVDS + CRT with same timings)
229 * Note: Twin is NOT CURRENTLY SUPPORTED
230 * - 8 = Extended displays (e.g. LVDS + CRT displaying different images)
232 1366,/* Display width to use if initializing the display
233 * (corresponds to the "width" module parameter)
235 768,/* Display height to use if initializing the display
236 * (corresponds to the "height" module parameter)
238 60, /* Display refresh rate to use if initializing the display
239 * (corresponds to the "refresh" module parameter)
242 0, /* ovl_brightness */
243 0, /* ovl_contrast */
244 0, /* ovl_saturation */
245 0, /* ovl_gamma_red */
246 0, /* ovl_gamma_green */
247 0, /* ovl_gamma_blue */
250 &config_params /* driver parameters from above */