patch-2.3.41 linux/drivers/video/fbmem.c
Next file: linux/drivers/video/fm2fb.c
Previous file: linux/drivers/video/fbgen.c
Back to the patch index
Back to the overall index
- Lines: 20
- Date:
Thu Jan 27 09:01:58 2000
- Orig file:
v2.3.40/linux/drivers/video/fbmem.c
- Orig date:
Fri Jan 7 19:13:22 2000
diff -u --recursive --new-file v2.3.40/linux/drivers/video/fbmem.c linux/drivers/video/fbmem.c
@@ -432,8 +432,7 @@
/* frame buffer memory */
start = fix.smem_start;
- len = (start & ~PAGE_MASK)+fix.smem_len;
- len = (len+~PAGE_MASK) & PAGE_MASK; /* someone's on crack. */
+ len = PAGE_ALIGN((start & ~PAGE_MASK)+fix.smem_len);
if (off >= len) {
/* memory mapped io */
off -= len;
@@ -441,8 +440,7 @@
if (var.accel_flags)
return -EINVAL;
start = fix.mmio_start;
- len = (start & ~PAGE_MASK)+fix.mmio_len;
- len = (len+~PAGE_MASK) & PAGE_MASK;
+ len = PAGE_ALIGN((start & ~PAGE_MASK)+fix.mmio_len);
}
start &= PAGE_MASK;
if ((vma->vm_end - vma->vm_start + off) > len)
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)