]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
vm_page_is_valid() wasn't expecting a large offset argument, it's
authorPeter Wemm <peter@FreeBSD.org>
Fri, 1 May 1998 15:10:59 +0000 (15:10 +0000)
committerPeter Wemm <peter@FreeBSD.org>
Fri, 1 May 1998 15:10:59 +0000 (15:10 +0000)
commitb1951f402864c5ed187dee4bc5fc92a7f548f78a
tree3c5520bffb8a86e1060f267065b8e159dddfc8ad
parentf806d5a25707e4d6c8405b2c9dcc99b0b10801e0
vm_page_is_valid() wasn't expecting a large offset argument, it's
expecting a sub-page offset.  We were passing the file position,
and vm_page_bits() could do some interesting things when base was
larger PAGE_SIZE.
if (size > PAGE_SIZE - base)
size = PAGE_SIZE - base;
is interesting when (PAGE_SIZE - base) is negative.  I could imagine that
this could have interesting consequences for memory page -> device block
bit validation.
sys/kern/vfs_bio.c