Commit 5b36b1f9 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] tgafb iomem annotations

Signed-off-by: default avatarAl Viro <viro@parcelfarce.linux.theplanet.co.uk>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent af765221
...@@ -562,7 +562,8 @@ tgafb_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -562,7 +562,8 @@ tgafb_imageblit(struct fb_info *info, const struct fb_image *image)
unsigned long rincr, line_length, shift, pos, is8bpp; unsigned long rincr, line_length, shift, pos, is8bpp;
unsigned long i, j; unsigned long i, j;
const unsigned char *data; const unsigned char *data;
void *regs_base, *fb_base; void __iomem *regs_base;
void __iomem *fb_base;
dx = image->dx; dx = image->dx;
dy = image->dy; dy = image->dy;
...@@ -785,7 +786,8 @@ tgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect) ...@@ -785,7 +786,8 @@ tgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect)
int is8bpp = info->var.bits_per_pixel == 8; int is8bpp = info->var.bits_per_pixel == 8;
u32 dx, dy, width, height, vxres, vyres, color; u32 dx, dy, width, height, vxres, vyres, color;
unsigned long pos, align, line_length, i, j; unsigned long pos, align, line_length, i, j;
void *regs_base, *fb_base; void __iomem *regs_base;
void __iomem *fb_base;
dx = rect->dx; dx = rect->dx;
dy = rect->dy; dy = rect->dy;
...@@ -912,7 +914,7 @@ copyarea_line_8bpp(struct fb_info *info, u32 dy, u32 sy, ...@@ -912,7 +914,7 @@ copyarea_line_8bpp(struct fb_info *info, u32 dy, u32 sy,
u32 height, u32 width) u32 height, u32 width)
{ {
struct tga_par *par = (struct tga_par *) info->par; struct tga_par *par = (struct tga_par *) info->par;
void *tga_regs = par->tga_regs_base; void __iomem *tga_regs = par->tga_regs_base;
unsigned long dpos, spos, i, n64; unsigned long dpos, spos, i, n64;
/* Set up the MODE and PIXELSHIFT registers. */ /* Set up the MODE and PIXELSHIFT registers. */
...@@ -957,9 +959,10 @@ copyarea_line_32bpp(struct fb_info *info, u32 dy, u32 sy, ...@@ -957,9 +959,10 @@ copyarea_line_32bpp(struct fb_info *info, u32 dy, u32 sy,
u32 height, u32 width) u32 height, u32 width)
{ {
struct tga_par *par = (struct tga_par *) info->par; struct tga_par *par = (struct tga_par *) info->par;
void *tga_regs = par->tga_regs_base; void __iomem *tga_regs = par->tga_regs_base;
void *tga_fb = par->tga_fb_base; void __iomem *tga_fb = par->tga_fb_base;
void *src, *dst; void __iomem *src;
void __iomem *dst;
unsigned long i, n16; unsigned long i, n16;
/* Set up the MODE and PIXELSHIFT registers. */ /* Set up the MODE and PIXELSHIFT registers. */
...@@ -1010,7 +1013,8 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy, ...@@ -1010,7 +1013,8 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
u32 smask_first, dmask_first, dmask_last; u32 smask_first, dmask_first, dmask_last;
int pixel_shift, need_prime, need_second; int pixel_shift, need_prime, need_second;
unsigned long n64, n32, xincr_first; unsigned long n64, n32, xincr_first;
void *tga_regs, *tga_fb; void __iomem *tga_regs;
void __iomem *tga_fb;
yincr = line_length; yincr = line_length;
if (dy > sy) { if (dy > sy) {
...@@ -1098,7 +1102,8 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy, ...@@ -1098,7 +1102,8 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
for (i = 0; i < height; ++i) { for (i = 0; i < height; ++i) {
unsigned long j; unsigned long j;
void *sfb, *dfb; void __iomem *sfb;
void __iomem *dfb;
sfb = tga_fb + spos; sfb = tga_fb + spos;
dfb = tga_fb + dpos; dfb = tga_fb + dpos;
...@@ -1120,7 +1125,7 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy, ...@@ -1120,7 +1125,7 @@ copyarea_foreward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
dfb += 32; dfb += 32;
} }
if (n64 && (((long)sfb | (long)dfb) & 63)) if (n64 && (((unsigned long)sfb | (unsigned long)dfb) & 63))
printk(KERN_ERR printk(KERN_ERR
"tgafb: misaligned copy64 (s:%p, d:%p)\n", "tgafb: misaligned copy64 (s:%p, d:%p)\n",
sfb, dfb); sfb, dfb);
...@@ -1169,7 +1174,8 @@ copyarea_backward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy, ...@@ -1169,7 +1174,8 @@ copyarea_backward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
unsigned long depos, sepos, dealign, sealign; unsigned long depos, sepos, dealign, sealign;
u32 mask_first, mask_last; u32 mask_first, mask_last;
unsigned long n32; unsigned long n32;
void *tga_regs, *tga_fb; void __iomem *tga_regs;
void __iomem *tga_fb;
yincr = line_length; yincr = line_length;
if (dy > sy) { if (dy > sy) {
...@@ -1223,7 +1229,8 @@ copyarea_backward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy, ...@@ -1223,7 +1229,8 @@ copyarea_backward_8bpp(struct fb_info *info, u32 dx, u32 dy, u32 sx, u32 sy,
for (i = 0; i < height; ++i) { for (i = 0; i < height; ++i) {
unsigned long j; unsigned long j;
void *sfb, *dfb; void __iomem *sfb;
void __iomem *dfb;
sfb = tga_fb + sepos; sfb = tga_fb + sepos;
dfb = tga_fb + depos; dfb = tga_fb + depos;
...@@ -1380,7 +1387,7 @@ tgafb_pci_register(struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -1380,7 +1387,7 @@ tgafb_pci_register(struct pci_dev *pdev, const struct pci_device_id *ent)
u32 pseudo_palette[16]; u32 pseudo_palette[16];
} *all; } *all;
void *mem_base; void __iomem *mem_base;
unsigned long bar0_start, bar0_len; unsigned long bar0_start, bar0_len;
u8 tga_type; u8 tga_type;
int ret; int ret;
...@@ -1429,7 +1436,7 @@ tgafb_pci_register(struct pci_dev *pdev, const struct pci_device_id *ent) ...@@ -1429,7 +1436,7 @@ tgafb_pci_register(struct pci_dev *pdev, const struct pci_device_id *ent)
all->info.flags = FBINFO_DEFAULT | FBINFO_HWACCEL_COPYAREA | all->info.flags = FBINFO_DEFAULT | FBINFO_HWACCEL_COPYAREA |
FBINFO_HWACCEL_IMAGEBLIT | FBINFO_HWACCEL_FILLRECT; FBINFO_HWACCEL_IMAGEBLIT | FBINFO_HWACCEL_FILLRECT;
all->info.fbops = &tgafb_ops; all->info.fbops = &tgafb_ops;
all->info.screen_base = (char *) all->par.tga_fb_base; all->info.screen_base = all->par.tga_fb_base;
all->info.par = &all->par; all->info.par = &all->par;
all->info.pseudo_palette = all->pseudo_palette; all->info.pseudo_palette = all->pseudo_palette;
......
...@@ -176,9 +176,9 @@ struct tga_par { ...@@ -176,9 +176,9 @@ struct tga_par {
struct pci_dev *pdev; struct pci_dev *pdev;
/* Device dependent information. */ /* Device dependent information. */
void *tga_mem_base; void __iomem *tga_mem_base;
void *tga_fb_base; void __iomem *tga_fb_base;
void *tga_regs_base; void __iomem *tga_regs_base;
u8 tga_type; /* TGA_TYPE_XXX */ u8 tga_type; /* TGA_TYPE_XXX */
u8 tga_chip_rev; /* dc21030 revision */ u8 tga_chip_rev; /* dc21030 revision */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment