xserver: Branch 'master' - 3 commits

Daniel Stone daniels at kemper.freedesktop.org
Mon Aug 31 18:25:54 PDT 2009


 Xi/exevents.c                          |    1 +
 Xi/extinit.c                           |    5 +++++
 hw/xfree86/os-support/linux/lnx_init.c |    8 ++++----
 3 files changed, 10 insertions(+), 4 deletions(-)

New commits:
commit 1c37be80982151a5acd74fe4b960695f604f22ca
Author: Michael Witrant <mike at lepton.fr>
Date:   Tue Sep 1 10:46:50 2009 +1000

    XFree86: Linux: Fix 100% CPU usage with ShareVTs and kbd
    
    Leave consoleFd open over the course of the server, even though any use
    of it in this context is likely to be disastrous.
    
    Signed-off-by: Michael Witrant <mike at lepton.fr>
    Reviewed-by: Daniel Stone <daniel at fooishbar.org>

diff --git a/hw/xfree86/os-support/linux/lnx_init.c b/hw/xfree86/os-support/linux/lnx_init.c
index 6403007..5a6db80 100644
--- a/hw/xfree86/os-support/linux/lnx_init.c
+++ b/hw/xfree86/os-support/linux/lnx_init.c
@@ -286,9 +286,6 @@ xf86OpenConsole(void)
 
 	    /* we really should have a InitOSInputDevices() function instead
 	     * of Init?$#*&Device(). So I just place it here */
-	
-        } else { /* ShareVTs */
-            close(xf86Info.consoleFd);
         }
     } else { 	/* serverGeneration != 1 */
         if (!ShareVTs && VTSwitch)
@@ -317,7 +314,10 @@ xf86CloseConsole(void)
     int vtno = -1;
 #endif
 
-    if (ShareVTs) return;
+    if (ShareVTs) {
+        close(xf86Info.consoleFd);
+        return;
+    }
 
     if (console_handler) {
 	xf86RemoveGeneralHandler(console_handler);
commit 65183dc3153232943dff3cfbaacab141e7ed0e9c
Author: Daniel Stone <daniel at fooishbar.org>
Date:   Sun Jul 5 19:53:55 2009 +0300

    Input: Mark Xi input events as critical
    
    Note that the Xi events are critical and should thus cause a flush to
    the client when an input event is pending.
    
    Signed-off-by: Daniel Stone <daniel at fooishbar.org>

diff --git a/Xi/extinit.c b/Xi/extinit.c
index d91de8f..84b999c 100644
--- a/Xi/extinit.c
+++ b/Xi/extinit.c
@@ -1018,15 +1018,19 @@ FixExtensionEvents(ExtensionEntry * extEntry)
 
     SetMaskForExtEvent(DeviceKeyPressMask, DeviceKeyPress);
     AllowPropagateSuppress(DeviceKeyPressMask);
+    SetCriticalEvent(DeviceKeyPress);
 
     SetMaskForExtEvent(DeviceKeyReleaseMask, DeviceKeyRelease);
     AllowPropagateSuppress(DeviceKeyReleaseMask);
+    SetCriticalEvent(DeviceKeyRelease);
 
     SetMaskForExtEvent(DeviceButtonPressMask, DeviceButtonPress);
     AllowPropagateSuppress(DeviceButtonPressMask);
+    SetCriticalEvent(DeviceButtonPress);
 
     SetMaskForExtEvent(DeviceButtonReleaseMask, DeviceButtonRelease);
     AllowPropagateSuppress(DeviceButtonReleaseMask);
+    SetCriticalEvent(DeviceButtonRelease);
 
     SetMaskForExtEvent(DeviceProximityMask, ProximityIn);
     SetMaskForExtEvent(DeviceProximityMask, ProximityOut);
@@ -1035,6 +1039,7 @@ FixExtensionEvents(ExtensionEntry * extEntry)
 
     SetMaskForExtEvent(DevicePointerMotionMask, DeviceMotionNotify);
     AllowPropagateSuppress(DevicePointerMotionMask);
+    SetCriticalEvent(DeviceMotionNotify);
 
     SetEventInfo(DevicePointerMotionHintMask, _devicePointerMotionHint);
     SetEventInfo(DeviceButton1MotionMask, _deviceButton1Motion);
commit a4e614d301cfa2577de1ee6a15abf023590586d1
Author: Daniel Stone <daniel at fooishbar.org>
Date:   Sat Apr 25 16:46:10 2009 +1000

    Xi: Fix harmless ButtonPress/ButtonRelease confusion
    
    A missing break meant that ButtonPress would fall through into
    ButtonRelease, but luckily it appears to have been completely harmless.
    
    Signed-off-by: Daniel Stone <daniel at fooishbar.org>

diff --git a/Xi/exevents.c b/Xi/exevents.c
index 0065619..2173f35 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -1070,6 +1070,7 @@ ProcessOtherEvent(InternalEvent *ev, DeviceIntPtr device)
                  * already */
                 return;
             }
+            break;
         case ET_ButtonRelease:
             event->detail.button = b->map[key];
             if (!event->detail.button) { /* there's no button 0 */


More information about the xorg-commit mailing list