blob: 46f8ff41e3d77d81004e62740b2007d787fd10e5 [file] [log] [blame]
Ronald G. Minnich4f78b182013-04-17 16:57:30 -07001/*
2* This file is part of the coreboot project.
3*
4* Copyright 2013 Google Inc.
5*
6* This program is free software; you can redistribute it and/or modify
7* it under the terms of the GNU General Public License as published by
8* the Free Software Foundation; version 2 of the License.
9*
10* This program is distributed in the hope that it will be useful,
11* but WITHOUT ANY WARRANTY; without even the implied warranty of
12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13* GNU General Public License for more details.
Ronald G. Minnich4f78b182013-04-17 16:57:30 -070014*/
15/* this file was for the most part machine generated, and in future
16 * will be all machine generated. Avoid editing.
17 */
18#include <console/console.h>
Stefan Reinauerf69a27b2015-01-06 13:08:23 -080019#include <drivers/intel/gma/i915.h>
Ronald G. Minnich4f78b182013-04-17 16:57:30 -070020
21void graphics_register_reset(u32 aux_ctl, u32 aux_data, int verbose)
22{
23
24 io_i915_write32(0x80000000,0x45400);
25 io_i915_write32(0x00000000,_CURACNTR);
Elyes HAOUAS531b87a2016-09-19 09:46:33 -060026 io_i915_write32((/* PIPEA */0x0 << 24)|0x00000000,_DSPACNTR);
Ronald G. Minnich4f78b182013-04-17 16:57:30 -070027 io_i915_write32(0x00000000,_DSPBCNTR);
28 io_i915_write32(0x80000000,CPU_VGACNTRL);
29 io_i915_write32(0x00000000,_DSPASIZE+0xc);
30 io_i915_write32(0x00000000,_DSPBSURF);
31 io_i915_write32(0x00000000,0x4f050);
32 io_i915_write32( DP_LINK_TRAIN_PAT_1 | DP_LINK_TRAIN_PAT_1_CPT |
33 DP_VOLTAGE_0_4 | DP_PRE_EMPHASIS_0 | DP_PORT_WIDTH_1 |
34 DP_PLL_FREQ_270MHZ | DP_SCRAMBLING_DISABLE_IRONLAKE |
35 DP_SYNC_VS_HIGH |0x00000091,DP_A);
36 io_i915_write32(0x00200090,_FDI_RXA_MISC);
37 io_i915_write32(0x0a000000,_FDI_RXA_MISC);
38 /* not yet documented anywhere that we can find. */
39 io_i915_write32(0x00000070,0x46408);
40 io_i915_write32(0x04000000,0x42090);
41 io_i915_write32(0x40000000,0x4f050);
42 io_i915_write32(0x00000000,0x9840);
43 io_i915_write32(0xa4000000,0x42090);
44 io_i915_write32(0x00004000,0x42080);
45 io_i915_write32(0x00ffffff,0x64f80);
46 io_i915_write32(0x0007000e,0x64f84);
47 io_i915_write32(0x00d75fff,0x64f88);
48 io_i915_write32(0x000f000a,0x64f8c);
49 io_i915_write32(0x00c30fff,0x64f90);
50 io_i915_write32(0x00060006,0x64f94);
51 io_i915_write32(0x00aaafff,0x64f98);
52 io_i915_write32(0x001e0000,0x64f9c);
53 io_i915_write32(0x00ffffff,0x64fa0);
54 io_i915_write32(0x000f000a,0x64fa4);
55 io_i915_write32(0x00d75fff,0x64fa8);
56 io_i915_write32(0x00160004,0x64fac);
57 io_i915_write32(0x00c30fff,0x64fb0);
58 io_i915_write32(0x001e0000,0x64fb4);
59 io_i915_write32(0x00ffffff,0x64fb8);
60 io_i915_write32(0x00060006,0x64fbc);
61 io_i915_write32(0x00d75fff,0x64fc0);
62 io_i915_write32(0x001e0000,0x64fc4);
63 io_i915_write32(0x00ffffff,0x64e00);
64 io_i915_write32(0x0006000e,0x64e04);
65 io_i915_write32(0x00d75fff,0x64e08);
66 io_i915_write32(0x0005000a,0x64e0c);
67 io_i915_write32(0x00c30fff,0x64e10);
68 io_i915_write32(0x00040006,0x64e14);
69 io_i915_write32(0x80aaafff,0x64e18);
70 io_i915_write32(0x000b0000,0x64e1c);
71 io_i915_write32(0x00ffffff,0x64e20);
72 io_i915_write32(0x0005000a,0x64e24);
73 io_i915_write32(0x00d75fff,0x64e28);
74 io_i915_write32(0x000c0004,0x64e2c);
75 io_i915_write32(0x80c30fff,0x64e30);
76 io_i915_write32(0x000b0000,0x64e34);
77 io_i915_write32(0x00ffffff,0x64e38);
78 io_i915_write32(0x00040006,0x64e3c);
79 io_i915_write32(0x80d75fff,0x64e40);
80 io_i915_write32(0x000b0000,0x64e44);
81 /* end not yet documented. */
82 io_i915_write32(0x10000000,SDEISR+0x30);
83}