diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2010-10-24 15:18:28 +0200 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2010-11-23 13:08:21 -0500 |
commit | 06ca34fe012c0b6a55851770c47680abe548d229 (patch) | |
tree | 908ce7f86c2ecce3bbc591791534e845a81984b8 | |
parent | 32004e8d6e3fcbb98ccacd89662099d190c71f51 (diff) |
Do not trap access to timer and keyboard
Disable timer/keyboard trapping on GNU/Hurd for now
Trapping disabled for now, as some VBIOSes (mga-g450 notably) use these
ports, and the int10 wrapper is not emulating them.
It's effectively what happens in the Linux variant too, as iopl() is used there,
making the ioperm() meaningless.
Signed-off-by: Olaf Buddenhagen <antrik@users.sf.net>
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit a6c64d96456d794b2f3ce40915922a3fba636b95)
-rw-r--r-- | hw/xfree86/os-support/hurd/hurd_video.c | 9 | ||||
-rw-r--r-- | hw/xfree86/os-support/linux/lnx_video.c | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/hw/xfree86/os-support/hurd/hurd_video.c b/hw/xfree86/os-support/hurd/hurd_video.c index 3d7af404d..39f353bd3 100644 --- a/hw/xfree86/os-support/hurd/hurd_video.c +++ b/hw/xfree86/os-support/hurd/hurd_video.c @@ -124,8 +124,17 @@ xf86EnableIO() FatalError("xf86EnableIO: ioperm() failed (%s)\n", strerror(errno)); return FALSE; } +#if 0 + /* + * Trapping disabled for now, as some VBIOSes (mga-g450 notably) use these + * ports, and the int10 wrapper is not emulating them. (Note that it's + * effectively what happens in the Linux variant too, as iopl() is used + * there, making the ioperm() meaningless.) + * + * Reenable this when int10 gets fixed. */ ioperm(0x40,4,0); /* trap access to the timer chip */ ioperm(0x60,4,0); /* trap access to the keyboard controller */ +#endif return TRUE; } diff --git a/hw/xfree86/os-support/linux/lnx_video.c b/hw/xfree86/os-support/linux/lnx_video.c index bdd2639ba..1c40a1b75 100644 --- a/hw/xfree86/os-support/linux/lnx_video.c +++ b/hw/xfree86/os-support/linux/lnx_video.c @@ -529,6 +529,8 @@ xf86EnableIO(void) return FALSE; } # if !defined(__alpha__) + /* XXX: this is actually not trapping anything because of iopl(3) + * above */ ioperm(0x40,4,0); /* trap access to the timer chip */ ioperm(0x60,4,0); /* trap access to the keyboard controller */ # endif |