patch-2.1.129 linux/drivers/video/clgenfb.c
Next file: linux/drivers/video/controlfb.c
Previous file: linux/drivers/video/chipsfb.c
Back to the patch index
Back to the overall index
- Lines: 65
- Date:
Fri Nov 13 10:10:11 1998
- Orig file:
v2.1.128/linux/drivers/video/clgenfb.c
- Orig date:
Mon Oct 5 13:13:41 1998
diff -u --recursive --new-file v2.1.128/linux/drivers/video/clgenfb.c linux/drivers/video/clgenfb.c
@@ -89,6 +89,9 @@
int btype;
int smallboard;
unsigned char SFR; /* Shadow of special function register */
+
+ unsigned long fbmem_phys;
+ unsigned long fbregs_phys;
struct clgenfb_par currentmode;
union {
@@ -333,7 +336,7 @@
memset(fix, 0, sizeof(struct fb_fix_screeninfo));
strcpy(fix->id, clgenfb_name);
- fix->smem_start = (char*)_info->fbmem;
+ fix->smem_start = (char*)_info->fbmem_phys;
/* monochrome: only 1 memory plane */
/* 8 bit and above: Use whole memory area */
@@ -346,7 +349,7 @@
fix->ypanstep = 1;
fix->ywrapstep = 0;
fix->line_length = _par->line_length;
- fix->mmio_start = (char *)_info->regs;
+ fix->mmio_start = (char *)_info->fbregs_phys;
fix->mmio_len = 0x10000;
fix->accel = FB_ACCEL_NONE;
@@ -410,7 +413,7 @@
/* use highest possible virtual resolution */
if (_par->var.xres_virtual == -1 &&
- _par->var.xres_virtual == -1)
+ _par->var.yres_virtual == -1)
{
printk("clgen: using maximum available virtual resolution\n");
for (i=0; modes[i].xres != -1; i++)
@@ -1534,8 +1537,10 @@
KERNELMAP_NOCACHE_SER, NULL);
DEBUG printk(KERN_INFO "clgen: Virtual address for board set to: $%p\n", fb_info->regs);
fb_info->regs += 0x600000;
+ fb_info->fbregs_phys = board_addr + 0x600000;
- fb_info->fbmem = kernel_map(board_addr + 16777216, 16777216,
+ fb_info->fbmem_phys = board_addr + 16777216;
+ fb_info->fbmem = kernel_map(fb_info->fbmem_phys, 16777216,
KERNELMAP_NOCACHE_SER, NULL);
DEBUG printk(KERN_INFO "clgen: (RAM start set to: $%lx)\n", fb_info->fbmem);
}
@@ -1544,6 +1549,7 @@
cd2 = zorro_get_board(key2);
printk(" REG at $%lx\n", (unsigned long)cd2->cd_BoardAddr);
+ fb_info->fbmem_phys = board_addr;
if (board_addr > 0x01000000)
fb_info->fbmem = kernel_map(board_addr, board_size,
KERNELMAP_NOCACHE_SER, NULL);
@@ -1552,6 +1558,7 @@
/* set address for REG area of board */
fb_info->regs = (unsigned char *)ZTWO_VADDR(cd2->cd_BoardAddr);
+ fb_info->fbregs_phys = (unsigned long) cd2->cd_BoardAddr;
DEBUG printk(KERN_INFO "clgen: Virtual address for board set to: $%p\n", fb_info->regs);
DEBUG printk(KERN_INFO "clgen: (RAM start set to: $%lx)\n", fb_info->fbmem);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov