lkml.org 
[lkml]   [1999]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] fbmem.c on 2.3.25 (had trouble with the other one)
On Wed, Nov 03, 1999 at 02:19:04PM -0500, kernel@kvack.org wrote:
> On Wed, 3 Nov 1999, Mordechai T. Abzug wrote:

> > - if (vma->vm_offset >= len) {
> > + if (vma->vm_pgoff << PAGE_SHIFT >= len) {

> This is better, but still wrong. What happens when shifting vm_pgoff
> overflows the unsigned long? This will be possible -- it's why the
> changes were done in the first place.

Ah, thanks for the explanation. In that case, why was this shifting
done elsewhere in patch-2.3.25? Ie. in linux/drivers/char/mem.c,
linux/fs/ncpfs/mmap.c, and others? linux/drivers/char/mem.c involves
an unsigned long, linux/fs/ncpfs/mmap.c involves an int. Is this a
bug in those places, or is there some reason why this was not a
problem over there?

- Morty "I am but a grasshopper"

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:2.342 / U:0.176 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site