2 * Copyright (C) 2005-2006 Erik Waling
3 * Copyright (C) 2006 Stephane Marchesin
4 * Copyright (C) 2007-2008 Stuart Bennett
5 * Copyright (C) 2008 Maarten Maathuis.
8 * Permission is hereby granted, free of charge, to any person obtaining
9 * a copy of this software and associated documentation files (the
10 * "Software"), to deal in the Software without restriction, including
11 * without limitation the rights to use, copy, modify, merge, publish,
12 * distribute, sublicense, and/or sell copies of the Software, and to
13 * permit persons to whom the Software is furnished to do so, subject to
14 * the following conditions:
16 * The above copyright notice and this permission notice (including the
17 * next paragraph) shall be included in all copies or substantial
18 * portions of the Software.
20 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
21 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23 * IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
24 * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
25 * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
26 * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
30 #ifndef __NOUVEAU_BIOS_H__
31 #define __NOUVEAU_BIOS_H__
38 enum dcb_output_type {/* matches DCB types */
40 DCB_OUTPUT_ANALOG = 0,
51 uint8_t major_version, chip_version;
54 uint32_t fmaxvco, fminvco;
58 uint16_t init_script_tbls_ptr;
59 uint16_t extra_init_script_tbl_ptr;
60 uint16_t macro_index_tbl_ptr;
61 uint16_t macro_tbl_ptr;
62 uint16_t condition_tbl_ptr;
63 uint16_t io_condition_tbl_ptr;
64 uint16_t io_flag_condition_tbl_ptr;
65 uint16_t init_function_tbl_ptr;
67 uint16_t pll_limit_tbl_ptr;
68 uint16_t ram_restrict_tbl_ptr;
71 struct nouveau_hw_mode *native_mode;
73 uint16_t lvdsmanufacturerpointer;
74 uint16_t xlated_entry;
75 bool power_off_for_reset;
76 bool reset_after_pclk_change;
78 bool link_c_increment;
81 int duallink_transition_clk;
82 /* lower nibble stores PEXTDEV_BOOT_0 strap
83 * upper nibble stores xlated display strap */
88 uint16_t output0_script_ptr;
89 uint16_t output1_script_ptr;
93 uint16_t mem_init_tbl_ptr;
94 uint16_t sdr_seq_tbl_ptr;
95 uint16_t ddr_seq_tbl_ptr;
98 uint8_t crt, tv, panel;
111 bool duallink_possible;
114 bool use_straps_for_mode;
115 bool use_power_scripts;
120 /* changing these requires matching changes to reg tables in nv_get_clock */
121 #define MAX_PLL_TYPES 4
143 uint8_t max_log2p_bias;
148 bool get_pll_limits(struct drm_device *dev, uint32_t limit_match, struct pll_lims *pll_lim);
149 int nouveau_parse_bios(struct drm_device *dev);
151 #endif /* __NOUVEAU_BIOS_H__ */