aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/via
diff options
context:
space:
mode:
authorFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2011-06-02 10:03:53 -0400
committerFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>2011-08-05 08:47:27 -0400
commit92746c3c82135b13d7fb1bbdebbabb0faedd8433 (patch)
treead6e284e645208053d7a25668cd16a1e00d20dcd /drivers/video/via
parent9ee3ec49e268c7a01217d7865c53562fae1edf33 (diff)
viafb: simplify viafb_fill_crtc_timing
As the first argument is just part of the structure passed as the second argument there is no need for it at all. Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Diffstat (limited to 'drivers/video/via')
-rw-r--r--drivers/video/via/dvi.c6
-rw-r--r--drivers/video/via/hw.c12
-rw-r--r--drivers/video/via/hw.h4
3 files changed, 10 insertions, 12 deletions
diff --git a/drivers/video/via/dvi.c b/drivers/video/via/dvi.c
index b1f364745ca0..c7ff5c0e9c7e 100644
--- a/drivers/video/via/dvi.c
+++ b/drivers/video/via/dvi.c
@@ -190,12 +190,10 @@ void viafb_dvi_set_mode(struct VideoModeTable *mode, int mode_bpp,
190 if ((maxPixelClock != 0) && (desirePixelClock > maxPixelClock)) { 190 if ((maxPixelClock != 0) && (desirePixelClock > maxPixelClock)) {
191 rb_mode = viafb_get_rb_mode(mode->crtc[0].crtc.hor_addr, 191 rb_mode = viafb_get_rb_mode(mode->crtc[0].crtc.hor_addr,
192 mode->crtc[0].crtc.ver_addr); 192 mode->crtc[0].crtc.ver_addr);
193 if (rb_mode) { 193 if (rb_mode)
194 mode = rb_mode; 194 mode = rb_mode;
195 pDviTiming = rb_mode->crtc;
196 }
197 } 195 }
198 viafb_fill_crtc_timing(pDviTiming, mode, mode_bpp / 8, set_iga); 196 viafb_fill_crtc_timing(mode, mode_bpp / 8, set_iga);
199} 197}
200 198
201/* Sense DVI Connector */ 199/* Sense DVI Connector */
diff --git a/drivers/video/via/hw.c b/drivers/video/via/hw.c
index 8b4bdf53b95e..2050fb81ef6e 100644
--- a/drivers/video/via/hw.c
+++ b/drivers/video/via/hw.c
@@ -1467,9 +1467,10 @@ void viafb_set_vclock(u32 clk, int set_iga)
1467 via_write_misc_reg_mask(0x0C, 0x0C); /* select external clock */ 1467 via_write_misc_reg_mask(0x0C, 0x0C); /* select external clock */
1468} 1468}
1469 1469
1470void viafb_fill_crtc_timing(struct crt_mode_table *crt_table, 1470void viafb_fill_crtc_timing(struct VideoModeTable *video_mode, int bpp_byte,
1471 struct VideoModeTable *video_mode, int bpp_byte, int set_iga) 1471 int set_iga)
1472{ 1472{
1473 struct crt_mode_table *crt_table = video_mode->crtc;
1473 struct display_timing crt_reg; 1474 struct display_timing crt_reg;
1474 int i; 1475 int i;
1475 int index = 0; 1476 int index = 0;
@@ -1911,11 +1912,10 @@ int viafb_setmode(struct VideoModeTable *vmode_tbl, int video_bpp,
1911 if (viafb_CRT_ON) { 1912 if (viafb_CRT_ON) {
1912 if (viafb_SAMM_ON && 1913 if (viafb_SAMM_ON &&
1913 viaparinfo->shared->iga2_devices & VIA_CRT) { 1914 viaparinfo->shared->iga2_devices & VIA_CRT) {
1914 viafb_fill_crtc_timing(crt_timing1, vmode_tbl1, 1915 viafb_fill_crtc_timing(vmode_tbl1, video_bpp1 / 8,
1915 video_bpp1 / 8, IGA2); 1916 IGA2);
1916 } else { 1917 } else {
1917 viafb_fill_crtc_timing(crt_timing, vmode_tbl, 1918 viafb_fill_crtc_timing(vmode_tbl, video_bpp / 8,
1918 video_bpp / 8,
1919 (viaparinfo->shared->iga1_devices & VIA_CRT) 1919 (viaparinfo->shared->iga1_devices & VIA_CRT)
1920 ? IGA1 : IGA2); 1920 ? IGA1 : IGA2);
1921 } 1921 }
diff --git a/drivers/video/via/hw.h b/drivers/video/via/hw.h
index 267c669be736..1fd8d98f7395 100644
--- a/drivers/video/via/hw.h
+++ b/drivers/video/via/hw.h
@@ -637,8 +637,8 @@ extern int viafb_LCD_ON;
637extern int viafb_DVI_ON; 637extern int viafb_DVI_ON;
638extern int viafb_hotplug; 638extern int viafb_hotplug;
639 639
640void viafb_fill_crtc_timing(struct crt_mode_table *crt_table, 640void viafb_fill_crtc_timing(struct VideoModeTable *video_mode, int bpp_byte,
641 struct VideoModeTable *video_mode, int bpp_byte, int set_iga); 641 int set_iga);
642 642
643void viafb_set_vclock(u32 CLK, int set_iga); 643void viafb_set_vclock(u32 CLK, int set_iga);
644void viafb_load_reg(int timing_value, int viafb_load_reg_num, 644void viafb_load_reg(int timing_value, int viafb_load_reg_num,