diff options
author | David Miller <davem@davemloft.net> | 2011-01-11 18:52:11 -0500 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2011-03-22 02:47:18 -0400 |
commit | 55db092388455457791cf00216b6b3965a8071f8 (patch) | |
tree | 753b175ccb2b1667d6412e0b950e3ff5ad3a7198 | |
parent | 9c96394bb90f855d265116f37897294fa1bdb072 (diff) |
svga: Make svga_tilecursor() take an iomem regbase pointer.
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
-rw-r--r-- | drivers/video/arkfb.c | 9 | ||||
-rw-r--r-- | drivers/video/s3fb.c | 11 | ||||
-rw-r--r-- | drivers/video/svgalib.c | 12 | ||||
-rw-r--r-- | drivers/video/vt8623fb.c | 8 | ||||
-rw-r--r-- | include/linux/svga.h | 2 |
5 files changed, 31 insertions, 11 deletions
diff --git a/drivers/video/arkfb.c b/drivers/video/arkfb.c index 658fff45332c..a4cfcf99ceb6 100644 --- a/drivers/video/arkfb.c +++ b/drivers/video/arkfb.c | |||
@@ -158,12 +158,19 @@ static void arkfb_settile(struct fb_info *info, struct fb_tilemap *map) | |||
158 | } | 158 | } |
159 | } | 159 | } |
160 | 160 | ||
161 | static void arkfb_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | ||
162 | { | ||
163 | struct arkfb_info *par = info->par; | ||
164 | |||
165 | svga_tilecursor(par->state.vgabase, info, cursor); | ||
166 | } | ||
167 | |||
161 | static struct fb_tile_ops arkfb_tile_ops = { | 168 | static struct fb_tile_ops arkfb_tile_ops = { |
162 | .fb_settile = arkfb_settile, | 169 | .fb_settile = arkfb_settile, |
163 | .fb_tilecopy = svga_tilecopy, | 170 | .fb_tilecopy = svga_tilecopy, |
164 | .fb_tilefill = svga_tilefill, | 171 | .fb_tilefill = svga_tilefill, |
165 | .fb_tileblit = svga_tileblit, | 172 | .fb_tileblit = svga_tileblit, |
166 | .fb_tilecursor = svga_tilecursor, | 173 | .fb_tilecursor = arkfb_tilecursor, |
167 | .fb_get_tilemax = svga_get_tilemax, | 174 | .fb_get_tilemax = svga_get_tilemax, |
168 | }; | 175 | }; |
169 | 176 | ||
diff --git a/drivers/video/s3fb.c b/drivers/video/s3fb.c index 017219565800..be3802e8108a 100644 --- a/drivers/video/s3fb.c +++ b/drivers/video/s3fb.c | |||
@@ -188,12 +188,19 @@ static void s3fb_settile_fast(struct fb_info *info, struct fb_tilemap *map) | |||
188 | } | 188 | } |
189 | } | 189 | } |
190 | 190 | ||
191 | static void s3fb_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | ||
192 | { | ||
193 | struct s3fb_info *par = info->par; | ||
194 | |||
195 | svga_tilecursor(par->state.vgabase, info, cursor); | ||
196 | } | ||
197 | |||
191 | static struct fb_tile_ops s3fb_tile_ops = { | 198 | static struct fb_tile_ops s3fb_tile_ops = { |
192 | .fb_settile = svga_settile, | 199 | .fb_settile = svga_settile, |
193 | .fb_tilecopy = svga_tilecopy, | 200 | .fb_tilecopy = svga_tilecopy, |
194 | .fb_tilefill = svga_tilefill, | 201 | .fb_tilefill = svga_tilefill, |
195 | .fb_tileblit = svga_tileblit, | 202 | .fb_tileblit = svga_tileblit, |
196 | .fb_tilecursor = svga_tilecursor, | 203 | .fb_tilecursor = s3fb_tilecursor, |
197 | .fb_get_tilemax = svga_get_tilemax, | 204 | .fb_get_tilemax = svga_get_tilemax, |
198 | }; | 205 | }; |
199 | 206 | ||
@@ -202,7 +209,7 @@ static struct fb_tile_ops s3fb_fast_tile_ops = { | |||
202 | .fb_tilecopy = svga_tilecopy, | 209 | .fb_tilecopy = svga_tilecopy, |
203 | .fb_tilefill = svga_tilefill, | 210 | .fb_tilefill = svga_tilefill, |
204 | .fb_tileblit = svga_tileblit, | 211 | .fb_tileblit = svga_tileblit, |
205 | .fb_tilecursor = svga_tilecursor, | 212 | .fb_tilecursor = s3fb_tilecursor, |
206 | .fb_get_tilemax = svga_get_tilemax, | 213 | .fb_get_tilemax = svga_get_tilemax, |
207 | }; | 214 | }; |
208 | 215 | ||
diff --git a/drivers/video/svgalib.c b/drivers/video/svgalib.c index ecda90ec4056..4876be85ecfd 100644 --- a/drivers/video/svgalib.c +++ b/drivers/video/svgalib.c | |||
@@ -299,7 +299,7 @@ void svga_tileblit(struct fb_info *info, struct fb_tileblit *blit) | |||
299 | } | 299 | } |
300 | 300 | ||
301 | /* Set cursor in text (tileblit) mode */ | 301 | /* Set cursor in text (tileblit) mode */ |
302 | void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | 302 | void svga_tilecursor(void __iomem *regbase, struct fb_info *info, struct fb_tilecursor *cursor) |
303 | { | 303 | { |
304 | u8 cs = 0x0d; | 304 | u8 cs = 0x0d; |
305 | u8 ce = 0x0e; | 305 | u8 ce = 0x0e; |
@@ -310,7 +310,7 @@ void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | |||
310 | if (! cursor -> mode) | 310 | if (! cursor -> mode) |
311 | return; | 311 | return; |
312 | 312 | ||
313 | svga_wcrt_mask(NULL, 0x0A, 0x20, 0x20); /* disable cursor */ | 313 | svga_wcrt_mask(regbase, 0x0A, 0x20, 0x20); /* disable cursor */ |
314 | 314 | ||
315 | if (cursor -> shape == FB_TILE_CURSOR_NONE) | 315 | if (cursor -> shape == FB_TILE_CURSOR_NONE) |
316 | return; | 316 | return; |
@@ -334,11 +334,11 @@ void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | |||
334 | } | 334 | } |
335 | 335 | ||
336 | /* set cursor position */ | 336 | /* set cursor position */ |
337 | vga_wcrt(NULL, 0x0E, pos >> 8); | 337 | vga_wcrt(regbase, 0x0E, pos >> 8); |
338 | vga_wcrt(NULL, 0x0F, pos & 0xFF); | 338 | vga_wcrt(regbase, 0x0F, pos & 0xFF); |
339 | 339 | ||
340 | vga_wcrt(NULL, 0x0B, ce); /* set cursor end */ | 340 | vga_wcrt(regbase, 0x0B, ce); /* set cursor end */ |
341 | vga_wcrt(NULL, 0x0A, cs); /* set cursor start and enable it */ | 341 | vga_wcrt(regbase, 0x0A, cs); /* set cursor start and enable it */ |
342 | } | 342 | } |
343 | 343 | ||
344 | int svga_get_tilemax(struct fb_info *info) | 344 | int svga_get_tilemax(struct fb_info *info) |
diff --git a/drivers/video/vt8623fb.c b/drivers/video/vt8623fb.c index e3bb7c5b1bd5..cedac002fa4b 100644 --- a/drivers/video/vt8623fb.c +++ b/drivers/video/vt8623fb.c | |||
@@ -121,13 +121,19 @@ MODULE_PARM_DESC(mtrr, "Enable write-combining with MTRR (1=enable, 0=disable, d | |||
121 | 121 | ||
122 | /* ------------------------------------------------------------------------- */ | 122 | /* ------------------------------------------------------------------------- */ |
123 | 123 | ||
124 | static void vt8623fb_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor) | ||
125 | { | ||
126 | struct vt8623fb_info *par = info->par; | ||
127 | |||
128 | svga_tilecursor(par->state.vgabase, info, cursor); | ||
129 | } | ||
124 | 130 | ||
125 | static struct fb_tile_ops vt8623fb_tile_ops = { | 131 | static struct fb_tile_ops vt8623fb_tile_ops = { |
126 | .fb_settile = svga_settile, | 132 | .fb_settile = svga_settile, |
127 | .fb_tilecopy = svga_tilecopy, | 133 | .fb_tilecopy = svga_tilecopy, |
128 | .fb_tilefill = svga_tilefill, | 134 | .fb_tilefill = svga_tilefill, |
129 | .fb_tileblit = svga_tileblit, | 135 | .fb_tileblit = svga_tileblit, |
130 | .fb_tilecursor = svga_tilecursor, | 136 | .fb_tilecursor = vt8623fb_tilecursor, |
131 | .fb_get_tilemax = svga_get_tilemax, | 137 | .fb_get_tilemax = svga_get_tilemax, |
132 | }; | 138 | }; |
133 | 139 | ||
diff --git a/include/linux/svga.h b/include/linux/svga.h index 767937d362d1..87879500f75b 100644 --- a/include/linux/svga.h +++ b/include/linux/svga.h | |||
@@ -109,7 +109,7 @@ void svga_settile(struct fb_info *info, struct fb_tilemap *map); | |||
109 | void svga_tilecopy(struct fb_info *info, struct fb_tilearea *area); | 109 | void svga_tilecopy(struct fb_info *info, struct fb_tilearea *area); |
110 | void svga_tilefill(struct fb_info *info, struct fb_tilerect *rect); | 110 | void svga_tilefill(struct fb_info *info, struct fb_tilerect *rect); |
111 | void svga_tileblit(struct fb_info *info, struct fb_tileblit *blit); | 111 | void svga_tileblit(struct fb_info *info, struct fb_tileblit *blit); |
112 | void svga_tilecursor(struct fb_info *info, struct fb_tilecursor *cursor); | 112 | void svga_tilecursor(void __iomem *regbase, struct fb_info *info, struct fb_tilecursor *cursor); |
113 | int svga_get_tilemax(struct fb_info *info); | 113 | int svga_get_tilemax(struct fb_info *info); |
114 | void svga_get_caps(struct fb_info *info, struct fb_blit_caps *caps, | 114 | void svga_get_caps(struct fb_info *info, struct fb_blit_caps *caps, |
115 | struct fb_var_screeninfo *var); | 115 | struct fb_var_screeninfo *var); |