File u_Revert-Remove-call-to-iopl-.-It-s-not-portable-and-i.patch of Package xf86-input-vmmouse.542

From f8724406aa027d4be2425da155784ef582fe7932 Mon Sep 17 00:00:00 2001
From: Takashi Iwai <tiwai@suse.de>
Date: Thu, 13 Feb 2014 11:34:26 +0100
Subject: [PATCH] Revert "Remove call to iopl(). It's not portable and isn't
 necessary."
References: bnc#863750

This reverts commit bcdec3d0cd4434770cd841c33c030e0d7203881f.

The commit breaks the detection vmmouse on QEMU/KVM.

Signed-off-by: Takashi Iwai <tiwai@suse.de>

---
 tools/vmmouse_detect.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tools/vmmouse_detect.c b/tools/vmmouse_detect.c
index 7939ff86d449..b83bec1f28e2 100644
--- a/tools/vmmouse_detect.c
+++ b/tools/vmmouse_detect.c
@@ -53,6 +53,11 @@ main(void)
    signal(SIGSEGV, segvCB);
 
 #if defined __i386__ || defined __x86_64__ 
+   /*
+    * To access i/o ports above 0x3ff, we need to be in iopl(3).
+    */
+
+   iopl(3);
    if (VMMouseClient_Enable()) {
       VMMouseClient_Disable();
       return 0;
-- 
1.8.5.2

openSUSE Build Service is sponsored by