summaryrefslogtreecommitdiffstats
path: root/sys/amd64/amd64/mem.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2002-08-03 00:59:15 +0000
committerpeter <peter@FreeBSD.org>2002-08-03 00:59:15 +0000
commitd468bdf569109a05fcc47c18e0da1e754e5b2a32 (patch)
treeaac4b29b0382493687f993ee07b046f6ed473ef5 /sys/amd64/amd64/mem.c
parent3545d79431025fac9992df9aacac0fc061e6c811 (diff)
downloadFreeBSD-src-d468bdf569109a05fcc47c18e0da1e754e5b2a32.zip
FreeBSD-src-d468bdf569109a05fcc47c18e0da1e754e5b2a32.tar.gz
Take a shot at fixing a nasty bug in the pmap changes that I did. I
missed the pmap_kenter/kremove in this file, which leads to read()/write() of /dev/mem using stale TLB entries. (gah!) Fortunately, mmap of /dev/mem wasn't affected, so it wasn't as bad as it could have been. This throws some light on the 'X server affects stability' thread.... Pointed out by: bde
Diffstat (limited to 'sys/amd64/amd64/mem.c')
-rw-r--r--sys/amd64/amd64/mem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/amd64/amd64/mem.c b/sys/amd64/amd64/mem.c
index 220bad3..313e6c5 100644
--- a/sys/amd64/amd64/mem.c
+++ b/sys/amd64/amd64/mem.c
@@ -167,7 +167,7 @@ mmrw(dev_t dev, struct uio *uio, int flags)
c = min(c, (u_int)(PAGE_SIZE - o));
c = min(c, (u_int)iov->iov_len);
error = uiomove((caddr_t)&ptvmmap[o], (int)c, uio);
- pmap_kremove((vm_offset_t)ptvmmap);
+ pmap_qremove((vm_offset_t)ptvmmap, 1);
continue;
/* minor device 1 is kernel memory */
OpenPOWER on IntegriCloud