diff options
author | Florian Tobias Schandinat <FlorianSchandinat@gmx.de> | 2011-05-22 19:40:46 -0400 |
---|---|---|
committer | Florian Tobias Schandinat <FlorianSchandinat@gmx.de> | 2011-08-05 08:47:06 -0400 |
commit | c174e3a3cd0594958c9afc6cdb8fbe20780d9c76 (patch) | |
tree | 0243ebcaf9884dedd4fab8152ffc42c9bf3594b4 /drivers/video/via | |
parent | f18e3e0ce0dacca497e3f1547095b3f9b111b0f7 (diff) |
viafb: remove superfluous register unlocking/locking
The locking is done within the viafb_set_*_timing functions so there
is no need to do it here. Move a missing hardware reset into the
modesetting function.
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Diffstat (limited to 'drivers/video/via')
-rw-r--r-- | drivers/video/via/hw.c | 7 | ||||
-rw-r--r-- | drivers/video/via/via_modesetting.c | 4 |
2 files changed, 4 insertions, 7 deletions
diff --git a/drivers/video/via/hw.c b/drivers/video/via/hw.c index 52d41f011d85..8b4bdf53b95e 100644 --- a/drivers/video/via/hw.c +++ b/drivers/video/via/hw.c | |||
@@ -1507,18 +1507,11 @@ void viafb_fill_crtc_timing(struct crt_mode_table *crt_table, | |||
1507 | crt_reg.ver_sync_end += crt_reg.ver_sync_start; | 1507 | crt_reg.ver_sync_end += crt_reg.ver_sync_start; |
1508 | h_addr = crt_reg.hor_addr; | 1508 | h_addr = crt_reg.hor_addr; |
1509 | v_addr = crt_reg.ver_addr; | 1509 | v_addr = crt_reg.ver_addr; |
1510 | if (set_iga == IGA1) { | ||
1511 | viafb_unlock_crt(); | ||
1512 | viafb_write_reg_mask(CR17, VIACR, 0x00, BIT7); | ||
1513 | } | ||
1514 | |||
1515 | if (set_iga == IGA1) | 1510 | if (set_iga == IGA1) |
1516 | via_set_primary_timing(&crt_reg); | 1511 | via_set_primary_timing(&crt_reg); |
1517 | else if (set_iga == IGA2) | 1512 | else if (set_iga == IGA2) |
1518 | via_set_secondary_timing(&crt_reg); | 1513 | via_set_secondary_timing(&crt_reg); |
1519 | 1514 | ||
1520 | viafb_lock_crt(); | ||
1521 | viafb_write_reg_mask(CR17, VIACR, 0x80, BIT7); | ||
1522 | viafb_load_fetch_count_reg(h_addr, bpp_byte, set_iga); | 1515 | viafb_load_fetch_count_reg(h_addr, bpp_byte, set_iga); |
1523 | 1516 | ||
1524 | /* load FIFO */ | 1517 | /* load FIFO */ |
diff --git a/drivers/video/via/via_modesetting.c b/drivers/video/via/via_modesetting.c index 016d457b6681..0e431aee17bb 100644 --- a/drivers/video/via/via_modesetting.c +++ b/drivers/video/via/via_modesetting.c | |||
@@ -82,6 +82,10 @@ void via_set_primary_timing(const struct display_timing *timing) | |||
82 | 82 | ||
83 | /* lock timing registers */ | 83 | /* lock timing registers */ |
84 | via_write_reg_mask(VIACR, 0x11, 0x80, 0x80); | 84 | via_write_reg_mask(VIACR, 0x11, 0x80, 0x80); |
85 | |||
86 | /* reset timing control */ | ||
87 | via_write_reg_mask(VIACR, 0x17, 0x00, 0x80); | ||
88 | via_write_reg_mask(VIACR, 0x17, 0x80, 0x80); | ||
85 | } | 89 | } |
86 | 90 | ||
87 | void via_set_secondary_timing(const struct display_timing *timing) | 91 | void via_set_secondary_timing(const struct display_timing *timing) |