diff options
author | kib <kib@FreeBSD.org> | 2014-03-28 15:38:38 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2014-03-28 15:38:38 +0000 |
commit | ef58943ab3d439a34a1586ccd4abc8c5266f7d01 (patch) | |
tree | 00116dbbc03ded27ce1b50cf87bab72dcf6ed6ac /sys/amd64/include | |
parent | 31717f7c2c10a59b1c3baf95958b322e632d756c (diff) | |
download | FreeBSD-src-ef58943ab3d439a34a1586ccd4abc8c5266f7d01.zip FreeBSD-src-ef58943ab3d439a34a1586ccd4abc8c5266f7d01.tar.gz |
MFC r263475:
Fix two issues with /dev/mem access on amd64, both causing kernel page
faults.
First, for accesses to direct map region should check for the limit by
which direct map is instantiated.
Second, for accesses to the kernel map, use a new thread private flag
TDP_DEVMEMIO, which instructs vm_fault() to return error when fault
happens on the MAP_ENTRY_NOFAULT entry, instead of panicing.
MFC r263498:
Add change forgotten in r263475. Make dmaplimit accessible outside
amd64/pmap.c.
Diffstat (limited to 'sys/amd64/include')
-rw-r--r-- | sys/amd64/include/pmap.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/amd64/include/pmap.h b/sys/amd64/include/pmap.h index 01de629..1b5f6a0 100644 --- a/sys/amd64/include/pmap.h +++ b/sys/amd64/include/pmap.h @@ -368,6 +368,7 @@ extern vm_paddr_t phys_avail[]; extern vm_paddr_t dump_avail[]; extern vm_offset_t virtual_avail; extern vm_offset_t virtual_end; +extern vm_paddr_t dmaplimit; #define pmap_page_get_memattr(m) ((vm_memattr_t)(m)->md.pat_mode) #define pmap_page_is_write_mapped(m) (((m)->aflags & PGA_WRITEABLE) != 0) |