mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2024-12-30 15:38:06 +01:00
Don't allow mmapping the page after last video page.
Obtained from: syscons.c (bug obtained from original pccons.c)
This commit is contained in:
parent
cb759a257f
commit
278b94817a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=11465
@ -741,7 +741,7 @@ do_standard:
|
|||||||
int
|
int
|
||||||
pcmmap(Dev_t dev, int offset, int nprot)
|
pcmmap(Dev_t dev, int offset, int nprot)
|
||||||
{
|
{
|
||||||
if (offset > 0x20000)
|
if (offset > 0x20000 - PAGE_SIZE)
|
||||||
return -1;
|
return -1;
|
||||||
return i386_btop((0xa0000 + offset));
|
return i386_btop((0xa0000 + offset));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user