aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/via
diff options
context:
space:
mode:
authorFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2009-09-22 19:47:12 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-23 10:39:51 -0400
commit3915a927aaed8d158cba5ad6466e237ae0d84aab (patch)
tree6a6636ac6bb8520b202d82e897207181e8c95f9a /drivers/video/via
parent0e3ca33ac7aa88ac2f28d4ec99f0bfeaf2a2318d (diff)
viafb: remove temporary start address setting
Currently the start address is set to an initial value every time viafb_setmode is called. This is not done consistently along graphic cores and not even the whole address but often only parts of it. On top of that it seems useless as the real/final address will be set by viafb_set_start_addr a few lines later. Remove this superfluous initalization to shrink register initalization and as a start to decouple primary and secondary display. Code cleanup, no notable runtime change expected. Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de> Cc: Scott Fang <ScottFang@viatech.com.cn> Cc: Joseph Chan <JosephChan@via.com.tw> Cc: Harald Welte <laforge@gnumonks.org> Cc: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/via')
-rw-r--r--drivers/video/via/viamode.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/drivers/video/via/viamode.c b/drivers/video/via/viamode.c
index e799b2d0ef32..7abd65dacb60 100644
--- a/drivers/video/via/viamode.c
+++ b/drivers/video/via/viamode.c
@@ -100,12 +100,8 @@ struct io_reg CN400_ModeXregs[] = { {VIASR, SR10, 0xFF, 0x01},
100{VIACR, CR0F, 0xFF, 0x00}, /* Cursor Localtion Low */ 100{VIACR, CR0F, 0xFF, 0x00}, /* Cursor Localtion Low */
101{VIACR, CR32, 0xFF, 0x00}, 101{VIACR, CR32, 0xFF, 0x00},
102{VIACR, CR33, 0xFF, 0x00}, 102{VIACR, CR33, 0xFF, 0x00},
103{VIACR, CR34, 0xFF, 0x00},
104{VIACR, CR35, 0xFF, 0x00}, 103{VIACR, CR35, 0xFF, 0x00},
105{VIACR, CR36, 0x08, 0x00}, 104{VIACR, CR36, 0x08, 0x00},
106{VIACR, CR62, 0xFF, 0x00}, /* Secondary Display Starting Address */
107{VIACR, CR63, 0xFF, 0x00}, /* Secondary Display Starting Address */
108{VIACR, CR64, 0xFF, 0x00}, /* Secondary Display Starting Address */
109{VIACR, CR69, 0xFF, 0x00}, 105{VIACR, CR69, 0xFF, 0x00},
110{VIACR, CR6A, 0xFF, 0x40}, 106{VIACR, CR6A, 0xFF, 0x40},
111{VIACR, CR6B, 0xFF, 0x00}, 107{VIACR, CR6B, 0xFF, 0x00},
@@ -159,16 +155,12 @@ struct io_reg CN700_ModeXregs[] = { {VIASR, SR10, 0xFF, 0x01},
159{VIASR, CR30, 0xFF, 0x04}, 155{VIASR, CR30, 0xFF, 0x04},
160{VIACR, CR32, 0xFF, 0x00}, 156{VIACR, CR32, 0xFF, 0x00},
161{VIACR, CR33, 0x7F, 0x00}, 157{VIACR, CR33, 0x7F, 0x00},
162{VIACR, CR34, 0xFF, 0x00},
163{VIACR, CR35, 0xFF, 0x00}, 158{VIACR, CR35, 0xFF, 0x00},
164{VIACR, CR36, 0xFF, 0x31}, 159{VIACR, CR36, 0xFF, 0x31},
165{VIACR, CR41, 0xFF, 0x80}, 160{VIACR, CR41, 0xFF, 0x80},
166{VIACR, CR42, 0xFF, 0x00}, 161{VIACR, CR42, 0xFF, 0x00},
167{VIACR, CR55, 0x80, 0x00}, 162{VIACR, CR55, 0x80, 0x00},
168{VIACR, CR5D, 0x80, 0x00}, /*Horizontal Retrace Start bit[11] should be 0*/ 163{VIACR, CR5D, 0x80, 0x00}, /*Horizontal Retrace Start bit[11] should be 0*/
169{VIACR, CR62, 0xFF, 0x00}, /* Secondary Display Starting Address */
170{VIACR, CR63, 0xFF, 0x00}, /* Secondary Display Starting Address */
171{VIACR, CR64, 0xFF, 0x00}, /* Secondary Display Starting Address */
172{VIACR, CR68, 0xFF, 0x67}, /* Default FIFO For IGA2 */ 164{VIACR, CR68, 0xFF, 0x67}, /* Default FIFO For IGA2 */
173{VIACR, CR69, 0xFF, 0x00}, 165{VIACR, CR69, 0xFF, 0x00},
174{VIACR, CR6A, 0xFD, 0x40}, 166{VIACR, CR6A, 0xFD, 0x40},
@@ -233,9 +225,6 @@ struct io_reg KM400_ModeXregs[] = {
233 {VIACR, CR55, 0x80, 0x00}, 225 {VIACR, CR55, 0x80, 0x00},
234 {VIACR, CR5D, 0x80, 0x00}, 226 {VIACR, CR5D, 0x80, 0x00},
235 {VIACR, CR36, 0xFF, 0x01}, /* Power Mangement 3 */ 227 {VIACR, CR36, 0xFF, 0x01}, /* Power Mangement 3 */
236 {VIACR, CR62, 0xFF, 0x00}, /* Secondary Display Starting Address */
237 {VIACR, CR63, 0xFF, 0x00}, /* Secondary Display Starting Address */
238 {VIACR, CR64, 0xFF, 0x00}, /* Secondary Display Starting Address */
239 {VIACR, CR68, 0xFF, 0x67}, /* Default FIFO For IGA2 */ 228 {VIACR, CR68, 0xFF, 0x67}, /* Default FIFO For IGA2 */
240 {VIACR, CR6A, 0x20, 0x20}, /* Extended FIFO On */ 229 {VIACR, CR6A, 0x20, 0x20}, /* Extended FIFO On */
241 {VIACR, CR7A, 0xFF, 0x01}, /* LCD Scaling Parameter 1 */ 230 {VIACR, CR7A, 0xFF, 0x01}, /* LCD Scaling Parameter 1 */
@@ -285,14 +274,9 @@ struct io_reg CX700_ModeXregs[] = { {VIASR, SR10, 0xFF, 0x01},
285{VIACR, CR0F, 0xFF, 0x00}, /* Cursor Localtion Low */ 274{VIACR, CR0F, 0xFF, 0x00}, /* Cursor Localtion Low */
286{VIACR, CR32, 0xFF, 0x00}, 275{VIACR, CR32, 0xFF, 0x00},
287{VIACR, CR33, 0xFF, 0x00}, 276{VIACR, CR33, 0xFF, 0x00},
288{VIACR, CR34, 0xFF, 0x00},
289{VIACR, CR35, 0xFF, 0x00}, 277{VIACR, CR35, 0xFF, 0x00},
290{VIACR, CR36, 0x08, 0x00}, 278{VIACR, CR36, 0x08, 0x00},
291{VIACR, CR47, 0xC8, 0x00}, /* Clear VCK Plus. */ 279{VIACR, CR47, 0xC8, 0x00}, /* Clear VCK Plus. */
292{VIACR, CR62, 0xFF, 0x00}, /* Secondary Display Starting Address */
293{VIACR, CR63, 0xFF, 0x00}, /* Secondary Display Starting Address */
294{VIACR, CR64, 0xFF, 0x00}, /* Secondary Display Starting Address */
295{VIACR, CRA3, 0xFF, 0x00}, /* Secondary Display Starting Address */
296{VIACR, CR69, 0xFF, 0x00}, 280{VIACR, CR69, 0xFF, 0x00},
297{VIACR, CR6A, 0xFF, 0x40}, 281{VIACR, CR6A, 0xFF, 0x40},
298{VIACR, CR6B, 0xFF, 0x00}, 282{VIACR, CR6B, 0xFF, 0x00},
@@ -340,7 +324,6 @@ struct io_reg CLE266_ModeXregs[] = { {VIASR, SR1E, 0xF0, 0x00},
340{VIASR, SR1A, 0xFB, 0x08}, 324{VIASR, SR1A, 0xFB, 0x08},
341 325
342{VIACR, CR32, 0xFF, 0x00}, 326{VIACR, CR32, 0xFF, 0x00},
343{VIACR, CR34, 0xFF, 0x00},
344{VIACR, CR35, 0xFF, 0x00}, 327{VIACR, CR35, 0xFF, 0x00},
345{VIACR, CR36, 0x08, 0x00}, 328{VIACR, CR36, 0x08, 0x00},
346{VIACR, CR6A, 0xFF, 0x80}, 329{VIACR, CR6A, 0xFF, 0x80},