From 722c8035dcf3ae0b18841066fe4ee030277274bc Mon Sep 17 00:00:00 2001 From: Adam Jackson Date: Mon, 20 Nov 2017 15:43:03 -0500 Subject: [PATCH] xfree86: Remove xf86InterceptSigIll This was added in ~2004 for the sis driver, to detect whether it could use SSE for memcpy. Charmingly, the code to check whether that feature exists in the server is: #if XORG_VERSION_CURRENT >= XORG_VERSION_NUMERIC(6,8,99,13,0) #define SISCHECKOSSSE /* Automatic check OS for SSE; requires SigIll facility */ #endif Which means it has never worked in any modular server release. A less gross way to do this is to check for SSE support with getauxval() or /proc/cpuinfo or similar. Since no driver is using the existing intercept mechanism, drop it. Signed-off-by: Adam Jackson Reviewed-by: Olivier Fourdan Reviewed-by: Dave Airlie --- hw/xfree86/common/xf86.h | 1 - hw/xfree86/common/xf86Events.c | 13 ------------- 2 files changed, 14 deletions(-) diff --git a/hw/xfree86/common/xf86.h b/hw/xfree86/common/xf86.h index 674e83cb1..db6e299b3 100644 --- a/hw/xfree86/common/xf86.h +++ b/hw/xfree86/common/xf86.h @@ -216,7 +216,6 @@ extern _X_EXPORT void xf86EnableGeneralHandler(void *handler); extern _X_EXPORT InputHandlerProc xf86SetConsoleHandler(InputHandlerProc handler, void *data); extern _X_EXPORT void xf86InterceptSignals(int *signo); -extern _X_EXPORT void xf86InterceptSigIll(void (*sigillhandler) (void)); extern _X_EXPORT void xf86ProcessActionEvent(ActionEvent action, void *arg); extern _X_EXPORT void xf86PrintBacktrace(void); extern _X_EXPORT Bool xf86VTOwner(void); diff --git a/hw/xfree86/common/xf86Events.c b/hw/xfree86/common/xf86Events.c index 53ec74f26..e2e6ca769 100644 --- a/hw/xfree86/common/xf86Events.c +++ b/hw/xfree86/common/xf86Events.c @@ -276,14 +276,6 @@ xf86InterceptSignals(int *signo) *signo = -1; } -static void (*xf86SigIllHandler) (void) = NULL; - -void -xf86InterceptSigIll(void (*sigillhandler) (void)) -{ - xf86SigIllHandler = sigillhandler; -} - /* * xf86SigWrapper -- * Catch unexpected signals and exit or continue cleanly. @@ -291,11 +283,6 @@ xf86InterceptSigIll(void (*sigillhandler) (void)) int xf86SigWrapper(int signo) { - if ((signo == SIGILL) && xf86SigIllHandler) { - (*xf86SigIllHandler) (); - return 0; /* continue */ - } - if (xf86SignalIntercept && (*xf86SignalIntercept < 0)) { *xf86SignalIntercept = signo; return 0; /* continue */