diff options
author | David Vrabel <dvrabel@arcom.com> | 2005-09-09 16:04:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-09 16:57:59 -0400 |
commit | 53eed4ec8bcd8701b9135859ec46b10a0d88ba25 (patch) | |
tree | 50e3fddcc63d536be5babb6e91d54d5c3071c555 /drivers/video/geode/video_cs5530.c | |
parent | 4c7ffe0b9f7f40bd818fe3af51342f64c483908e (diff) |
[PATCH] fbdev: geode updates
Geode framebuffer driver updates:
- Local mode list (taken from modedb.c) containing only relevant modes.
This also makes the driver work as a module.
- Make it a PCI driver (from James Simmons <jsimmons@infradead.org>).
- A few other minor cosmetic bits and pieces.
Signed-off-by: David Vrabel <dvrabel@arcom.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/video/geode/video_cs5530.c')
-rw-r--r-- | drivers/video/geode/video_cs5530.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/video/geode/video_cs5530.c b/drivers/video/geode/video_cs5530.c index d3764acf8443..649c3943d431 100644 --- a/drivers/video/geode/video_cs5530.c +++ b/drivers/video/geode/video_cs5530.c | |||
@@ -69,8 +69,6 @@ static const struct cs5530_pll_entry cs5530_pll_table[] = { | |||
69 | { 4310, 0x2FB1B802, }, /* 232.0000 */ | 69 | { 4310, 0x2FB1B802, }, /* 232.0000 */ |
70 | }; | 70 | }; |
71 | 71 | ||
72 | #define NUM_CS5530_FREQUENCIES sizeof(cs5530_pll_table)/sizeof(struct cs5530_pll_entry) | ||
73 | |||
74 | static void cs5530_set_dclk_frequency(struct fb_info *info) | 72 | static void cs5530_set_dclk_frequency(struct fb_info *info) |
75 | { | 73 | { |
76 | struct geodefb_par *par = info->par; | 74 | struct geodefb_par *par = info->par; |
@@ -82,7 +80,7 @@ static void cs5530_set_dclk_frequency(struct fb_info *info) | |||
82 | value = cs5530_pll_table[0].pll_value; | 80 | value = cs5530_pll_table[0].pll_value; |
83 | min = cs5530_pll_table[0].pixclock - info->var.pixclock; | 81 | min = cs5530_pll_table[0].pixclock - info->var.pixclock; |
84 | if (min < 0) min = -min; | 82 | if (min < 0) min = -min; |
85 | for (i = 1; i < NUM_CS5530_FREQUENCIES; i++) { | 83 | for (i = 1; i < ARRAY_SIZE(cs5530_pll_table); i++) { |
86 | diff = cs5530_pll_table[i].pixclock - info->var.pixclock; | 84 | diff = cs5530_pll_table[i].pixclock - info->var.pixclock; |
87 | if (diff < 0L) diff = -diff; | 85 | if (diff < 0L) diff = -diff; |
88 | if (diff < min) { | 86 | if (diff < min) { |