From e1481d713f3fbcf21065c7a26825e5a231f6a983087e1d93631b1ead367f634c Mon Sep 17 00:00:00 2001 From: OBS User buildservice-autocommit Date: Wed, 1 Jun 2011 07:21:44 +0000 Subject: [PATCH 1/2] Updating link to change in openSUSE:Factory/xorg-x11-server revision 215.0 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/xorg-x11-server?expand=0&rev=d2e20a82925235d198be38b312a5da6b --- xorg-x11-server.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xorg-x11-server.spec b/xorg-x11-server.spec index e4c7fed..b1447dc 100644 --- a/xorg-x11-server.spec +++ b/xorg-x11-server.spec @@ -32,7 +32,7 @@ BuildRequires: libjpeg-devel %endif Url: http://xorg.freedesktop.org/ Version: 7.6_%{dirsuffix} -Release: 27 +Release: 29 License: GPLv2+ ; MIT License (or similar) BuildRoot: %{_tmppath}/%{name}-%{version}-build Group: System/X11/Servers/XF86_4 From 548e4d5cc8d71bed21d540b33b1eec1c7218324ca9ae4cf495ca02b51de32e43 Mon Sep 17 00:00:00 2001 From: Stefan Dirsch Date: Mon, 11 Jul 2011 10:25:51 +0000 Subject: [PATCH 2/2] Accepting request 76024 from home:eeich:branches:X11:XOrg - update: * randr1_1-sig11.diff removed accidentally forgotten debugging code. * u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch made socket non-blocking. Idea taken from a pach for SLES11. - don't look for 10-evdev.conf for anything older than 11.3 (this includes SLE-11). - remove use-last-screen.patch: This patch has been rejected upstream. We will try to resolve this issue differently by not providing any screen, monitor or device section. - remove disable-fbblt-opt.diff: We are unable to reproduce this issue any more. So let's remove the workaround and start from scratch when issue resurfaces and find a proper fix. - fixed bug-197858_dpms.diff: removed pieces that have been solved differently today. - remove moblin-use_preferred_mode_for_all_outputs.diff: remove moblin specific patches. - rename edit_data_sanity_check.diff -> edid_data_sanity_check.diff - remove p_xkills_wrong_client.diff: made obsolete by commit b7f3618f. OBS-URL: https://build.opensuse.org/request/show/76024 OBS-URL: https://build.opensuse.org/package/show/X11:XOrg/xorg-x11-server?expand=0&rev=347 --- CVE-2010-2240-address_space_limit.patch | 121 -------- CVE-2010-2240-tree_depth_limit.patch | 73 ----- bitmap_always_unscaled.diff | 31 -- bug-197858_dpms.diff | 36 --- disable-fbblt-opt.diff | 24 -- ..._check.diff => edid_data_sanity_check.diff | 0 fpic.diff | 11 - libdrm.diff | 18 -- missing_font_paths.diff | 19 -- ...in-use_preferred_mode_for_all_outputs.diff | 19 -- mouse.diff | 15 - p_bug96328.diff | 52 ---- p_xkills_wrong_client.diff | 13 - p_xorg_acpi.diff | 121 -------- pixman.diff | 13 - ...nect-to-acpid-when-it-gets-restarted.patch | 290 ++++++++++++++++++ use-last-screen.patch | 56 ---- xephyr.diff | 21 -- xorg-docs.diff | 29 -- xorg-server-1.8.0.diff | 11 - xorg-server-nohwaccess.diff | 52 ---- xorg-server-option_libxf86config.diff | 122 -------- xorg-x11-nonroot-vesa.patch | 14 - xorg-x11-server.changes | 137 +++++++++ xorg-x11-server.spec | 80 ++--- xserver-1.6.1-nouveau.patch | 67 ---- zap_warning_xserver.diff | 2 +- 27 files changed, 454 insertions(+), 993 deletions(-) delete mode 100644 CVE-2010-2240-address_space_limit.patch delete mode 100644 CVE-2010-2240-tree_depth_limit.patch delete mode 100644 bitmap_always_unscaled.diff delete mode 100644 disable-fbblt-opt.diff rename edit_data_sanity_check.diff => edid_data_sanity_check.diff (100%) delete mode 100644 fpic.diff delete mode 100644 libdrm.diff delete mode 100644 missing_font_paths.diff delete mode 100644 moblin-use_preferred_mode_for_all_outputs.diff delete mode 100644 mouse.diff delete mode 100644 p_bug96328.diff delete mode 100644 p_xkills_wrong_client.diff delete mode 100644 p_xorg_acpi.diff delete mode 100644 pixman.diff create mode 100644 u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch delete mode 100644 use-last-screen.patch delete mode 100644 xephyr.diff delete mode 100644 xorg-docs.diff delete mode 100644 xorg-server-1.8.0.diff delete mode 100644 xorg-server-nohwaccess.diff delete mode 100644 xorg-server-option_libxf86config.diff delete mode 100644 xorg-x11-nonroot-vesa.patch delete mode 100644 xserver-1.6.1-nouveau.patch diff --git a/CVE-2010-2240-address_space_limit.patch b/CVE-2010-2240-address_space_limit.patch deleted file mode 100644 index 69718a9..0000000 --- a/CVE-2010-2240-address_space_limit.patch +++ /dev/null @@ -1,121 +0,0 @@ ->From fedf91eeabcfdd6d26b52529a16a64f744aa42ad Mon Sep 17 00:00:00 2001 -From: Matthieu Herrb -Date: Mon, 28 Jun 2010 23:54:13 +0200 -Subject: [PATCH] Workaround for CVE-2010-2240. - -By limiting the address space that the X server can use, -it prevents stack and mmap()ed areas to become so close that -the stack will grow over a mmaped area. - -Credits: Rafal Wojtczuk ---- - doc/Xserver.man.pre | 7 +++++++ - include/opaque.h | 3 +++ - os/osinit.c | 24 ++++++++++++++++++++++++ - os/utils.c | 16 ++++++++++++++++ - 4 files changed, 50 insertions(+), 0 deletions(-) - -diff --git a/doc/Xserver.man.pre b/doc/Xserver.man.pre -index ce3b3a1..91c595f 100644 ---- a/doc/Xserver.man.pre -+++ b/doc/Xserver.man.pre -@@ -285,6 +285,13 @@ sets the stack space limit of the server to the specified number of kilobytes. - A value of zero makes the stack size as large as possible. The default value - of \-1 leaves the stack space limit unchanged. - .TP 8 -+.B \-la \fIkilobytes\fP -+sets the address space limit of the server to the specified number of -+kilobytes. -+A value of zero makes address space as large as possible. -+The default value is 1572864 (1.5GB) on 32 bit architectures and -+10485760 (10GB) on 64 bit architectures. -+.TP 8 - .B \-logo - turns on the X Window System logo display in the screen-saver. - There is currently no way to change this from a client. -diff --git a/include/opaque.h b/include/opaque.h -index b3c7c70..4208d03 100644 ---- a/include/opaque.h -+++ b/include/opaque.h -@@ -67,6 +67,9 @@ extern _X_EXPORT int limitStackSpace; - #ifdef RLIMIT_NOFILE - extern _X_EXPORT int limitNoFile; - #endif -+#ifdef RLIMIT_AS -+extern _X_EXPORT int limitAddressSpace; -+#endif - extern _X_EXPORT Bool defeatAccessControl; - extern _X_EXPORT long maxBigRequestSize; - extern _X_EXPORT Bool party_like_its_1989; -diff --git a/os/osinit.c b/os/osinit.c -index 32747df..723fb14 100644 ---- a/os/osinit.c -+++ b/os/osinit.c -@@ -96,6 +96,14 @@ int limitStackSpace = -1; - #ifdef RLIMIT_NOFILE - int limitNoFile = -1; - #endif -+#ifdef RLIMIT_AS -+#ifdef _XSERVER64 -+#define XORG_AS_LIMIT 10737418240LL -+#else -+#define XORG_AS_LIMIT 1610612736 -+#endif -+long limitAddressSpace = XORG_AS_LIMIT; -+#endif - - static OsSigWrapperPtr OsSigWrapper = NULL; - -@@ -301,6 +309,22 @@ OsInit(void) - } - } - #endif -+#ifdef RLIMIT_AS -+ if (limitAddressSpace >= 0) -+ { -+ struct rlimit rlim; -+ -+ if (!getrlimit(RLIMIT_AS, &rlim)) -+ { -+ if ((limitAddressSpace > 0) -+ && (limitAddressSpace < rlim.rlim_max)) -+ rlim.rlim_cur = limitAddressSpace; -+ else -+ rlim.rlim_cur = rlim.rlim_max; -+ (void)setrlimit(RLIMIT_AS, &rlim); -+ } -+ } -+#endif - LockServer(); - been_here = TRUE; - } -diff --git a/os/utils.c b/os/utils.c -index 51455cc..4af0cb3 100644 ---- a/os/utils.c -+++ b/os/utils.c -@@ -745,6 +745,22 @@ ProcessCommandLine(int argc, char *argv[]) - UseMsg(); - } - #endif -+#ifdef RLIMIT_AS -+ else if ( strcmp( argv[i], "-la") == 0) -+ { -+ if (getuid() != geteuid()) { -+ FatalError("The '-la' option can only be used by root.\n"); -+ } -+ if(++i < argc) -+ { -+ limitAddressSpace = atol(argv[i]); -+ if (limitAddressSpace > 0) -+ limitAddressSpace *= 1024; -+ } -+ else -+ UseMsg(); -+ } -+#endif - else if ( strcmp ( argv[i], "-nolock") == 0) - { - #if !defined(WIN32) && !defined(__CYGWIN__) --- -1.7.0.5 - diff --git a/CVE-2010-2240-tree_depth_limit.patch b/CVE-2010-2240-tree_depth_limit.patch deleted file mode 100644 index f1d98c3..0000000 --- a/CVE-2010-2240-tree_depth_limit.patch +++ /dev/null @@ -1,73 +0,0 @@ ---- xorg-server-1.9.0/dix/window.c.orig 2010-08-23 16:07:24.000000000 +0200 -+++ xorg-server-1.9.0/dix/window.c 2010-08-23 16:14:09.000000000 +0200 -@@ -535,6 +535,48 @@ RealChildHead(WindowPtr pWin) - return NullWindow; - } - -+static int -+TreeDepth(WindowPtr pWin) -+{ -+ int depth = 1; -+ int max_depth = 1; -+ WindowPtr pChild; -+ -+ if (!(pChild = pWin)) -+ return 0; -+ while (1) -+ { -+ if (pChild->firstChild) -+ { -+ ++depth; -+ pChild = pChild->firstChild; -+ continue; -+ } else if (depth > max_depth) -+ max_depth = depth; -+ while (!pChild->nextSib && (pChild != pWin)) { -+ --depth; -+ pChild = pChild->parent; -+ } -+ if (pChild == pWin) -+ break; -+ pChild = pChild->nextSib; -+ } -+ return max_depth; -+} -+ -+static int -+WindowDepth(WindowPtr pWin) -+{ -+ int depth = 0; -+ while (pWin) { -+ ++depth; -+ pWin = pWin->parent; -+ } -+ return depth; -+} -+ -+#define MAX_TREE_DEPTH 256 -+ - /***** - * CreateWindow - * Makes a window in response to client request -@@ -555,6 +597,11 @@ CreateWindow(Window wid, WindowPtr pPare - PixmapFormatRec *format; - WindowOptPtr ancwopt; - -+ if (WindowDepth(pParent) >= MAX_TREE_DEPTH - 1) { -+ *error = BadAlloc; -+ return NullWindow; -+ } -+ - if (class == CopyFromParent) - class = pParent->drawable.class; - -@@ -2434,6 +2481,9 @@ ReparentWindow(WindowPtr pWin, WindowPtr - int bw = wBorderWidth (pWin); - ScreenPtr pScreen; - -+ if (WindowDepth(pParent) + TreeDepth(pWin) >= MAX_TREE_DEPTH) -+ return BadAlloc; -+ - pScreen = pWin->drawable.pScreen; - if (TraverseTree(pWin, CompareWIDs, (pointer)&pParent->drawable.id) == WT_STOPWALKING) - return BadMatch; diff --git a/bitmap_always_unscaled.diff b/bitmap_always_unscaled.diff deleted file mode 100644 index 60a5c71..0000000 --- a/bitmap_always_unscaled.diff +++ /dev/null @@ -1,31 +0,0 @@ -From 107688407c7ebc71323dc1203ed5b92276026e1e Mon Sep 17 00:00:00 2001 -From: Luc Verhaegen -Date: Wed, 2 Apr 2008 20:09:26 +0200 -Subject: [PATCH] Default bitmap fonts should typically be set as unscaled. - -It is generally not desired to have bitmap fonts scale. Even so -DEFAULT_FONT_PATH had the misc, 100dpi and 75dpi paths without the -:unscaled specifier. - -Now the default font path has this per default, xorgconfig and ---configure will only use these as :unscaled too. - -Since SUSE has been specifying :unscaled for its bitmap fonts for -about a decade or so, and since adding the default font path to the -.conf fontpath was only introduced a year ago, this lack of scaled -bitmap fonts will not have any new side-effects. - -Reported by Mike Fabian, debugged and fixed with the help of Mike -Fabian and Stefan Dirsch. -================================================================================ ---- xorg-server-1.7.99/configure.ac -+++ xorg-server-1.7.99/configure.ac -@@ -509,7 +509,7 @@ - dnl Uses --default-font-path if set, otherwise checks for /etc/X11/fontpath.d, - dnl otherwise uses standard subdirectories of FONTROOTDIR. When cross - dnl compiling, assume default font path uses standard FONTROOTDIR directories. --DEFAULT_FONT_PATH="${FONTMISCDIR}/,${FONTTTFDIR}/,${FONTOTFDIR}/,${FONTTYPE1DIR}/,${FONT100DPIDIR}/,${FONT75DPIDIR}/" -+DEFAULT_FONT_PATH="${FONTMISCDIR}:unscaled,${FONTTTFDIR}/,${FONTOTFDIR}/,${FONTTYPE1DIR}/,${FONT100DPIDIR}/,${FONT75DPIDIR}/" - if test "$cross_compiling" != yes; then - AC_CHECK_FILE([${sysconfdir}/X11/fontpath.d], - [DEFAULT_FONT_PATH='catalogue:${sysconfdir}/X11/fontpath.d'], diff --git a/bug-197858_dpms.diff b/bug-197858_dpms.diff index e0c4570..7840f03 100644 --- a/bug-197858_dpms.diff +++ b/bug-197858_dpms.diff @@ -67,39 +67,3 @@ Index: hw/xfree86/common/xf86Events.c return ih; } ---- os/WaitFor.c -+++ os/WaitFor.c -@@ -142,6 +142,7 @@ - * For more info on ClientsWithInput, see ReadRequestFromClient(). - * pClientsReady is an array to store ready client->index values into. - *****************/ -+volatile fd_set tmp_set; - - int - WaitForSomething(int *pClientsReady) -@@ -279,10 +280,9 @@ - if (expired) - return 0; - } -- } -+ } - else -- { -- fd_set tmp_set; -+ { - - if (*checkForInput[0] == *checkForInput[1]) { - if (timers) -@@ -317,6 +317,12 @@ - QueueWorkProc(EstablishNewConnections, NULL, - (pointer)&LastSelectMask); - -+#ifdef DPMSExtension -+ XFD_ANDSET(&tmp_set, &devicesReadable, &EnabledDevices); -+ if (XFD_ANYSET (&tmp_set) && (DPMSPowerLevel != DPMSModeOn)) -+ DPMSSet(serverClient, DPMSModeOn); -+#endif -+ - if (XFD_ANYSET (&devicesReadable) || XFD_ANYSET (&clientsReadable)) - break; - /* check here for DDXes that queue events during Block/Wakeup */ diff --git a/disable-fbblt-opt.diff b/disable-fbblt-opt.diff deleted file mode 100644 index 7a6d8b9..0000000 --- a/disable-fbblt-opt.diff +++ /dev/null @@ -1,24 +0,0 @@ -Index: fb/fbblt.c -================================================================================ ---- fb/fbblt.c -+++ fb/fbblt.c -@@ -76,6 +76,11 @@ - } - #endif - -+/* -+ * Disable optimization (introduced by ajax) due to a general vesa -+ * driver crash later in memcpy -+*/ -+#if 0 - if (alu == GXcopy && pm == FB_ALLONES && !reverse && - !(srcX & 7) && !(dstX & 7) && !(width & 7)) { - int i; -@@ -97,6 +102,7 @@ - - return; - } -+#endif - - FbInitializeMergeRop(alu, pm); - destInvarient = FbDestInvarientMergeRop(); diff --git a/edit_data_sanity_check.diff b/edid_data_sanity_check.diff similarity index 100% rename from edit_data_sanity_check.diff rename to edid_data_sanity_check.diff diff --git a/fpic.diff b/fpic.diff deleted file mode 100644 index 904676d..0000000 --- a/fpic.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- hw/xfree86/parser/Makefile.am.orig 2010-06-06 03:16:52.000000000 +0200 -+++ hw/xfree86/parser/Makefile.am 2010-08-23 14:05:50.000000000 +0200 -@@ -34,7 +34,7 @@ - $(INTERNAL_SOURCES) - libxf86config_a_CFLAGS = $(AM_CFLAGS) - --AM_CFLAGS = $(DIX_CFLAGS) $(XORG_CFLAGS) \ -+AM_CFLAGS = $(DIX_CFLAGS) $(XORG_CFLAGS) -fPIC \ - -DSYSCONFDIR=\"$(sysconfdir)\" \ - -DDATADIR=\"$(datadir)\" - diff --git a/libdrm.diff b/libdrm.diff deleted file mode 100644 index 3294f06..0000000 --- a/libdrm.diff +++ /dev/null @@ -1,18 +0,0 @@ -Index: hw/xfree86/common/xf86Helper.c -================================================================================ ---- hw/xfree86/common/xf86Helper.c -+++ hw/xfree86/common/xf86Helper.c -@@ -2183,6 +2183,13 @@ - &errmaj, &errmin); - if (!ret) - LoaderErrorMsg(pScrn->name, name, errmaj, errmin); -+ -+ /* "drm" module has been merged into "dri" module, but some drivers -+ are still trying to load it explictely and fail if it doesn't exist :-( */ -+ if (!ret && !strcmp(name,"drm")) { -+ ret = (pointer) -1; -+ } -+ - return ret; - } - diff --git a/missing_font_paths.diff b/missing_font_paths.diff deleted file mode 100644 index ec02b3f..0000000 --- a/missing_font_paths.diff +++ /dev/null @@ -1,19 +0,0 @@ ---- configure.ac -+++ configure.ac -@@ -505,11 +505,15 @@ - XORG_FONTSUBDIR(FONTTYPE1DIR, fonttype1dir, Type1) - XORG_FONTSUBDIR(FONT75DPIDIR, font75dpidir, 75dpi) - XORG_FONTSUBDIR(FONT100DPIDIR, font100dpidir, 100dpi) -+XORG_FONTSUBDIR(FONTURWDIR, fonturwdir, URW) -+XORG_FONTSUBDIR(FONTCYRILLICDIR, fontcyrillicdir, cyrillic) -+XORG_FONTSUBDIR(FONTSGIDIR, fontsgidir, misc/sgi) -+XORG_FONTSUBDIR(FONTTRUETYPEDIR, fonttruetypedir, truetype) - - dnl Uses --default-font-path if set, otherwise checks for /etc/X11/fontpath.d, - dnl otherwise uses standard subdirectories of FONTROOTDIR. When cross - dnl compiling, assume default font path uses standard FONTROOTDIR directories. --DEFAULT_FONT_PATH="${FONTMISCDIR}:unscaled,${FONTTTFDIR}/,${FONTOTFDIR}/,${FONTTYPE1DIR}/,${FONT100DPIDIR}/,${FONT75DPIDIR}/" -+DEFAULT_FONT_PATH="${FONTMISCDIR}:unscaled,${FONTTTFDIR}/,${FONTOTFDIR}/,${FONTTYPE1DIR}/,${FONT100DPIDIR}:unscaled,${FONT75DPIDIR}:unscaled,${FONTURWDIR}/,${FONTCYRILLICDIR}:unscaled,${FONTSGIDIR}:unscaled,${FONTTRUETYPEDIR}/" - if test "$cross_compiling" != yes; then - AC_CHECK_FILE([${sysconfdir}/X11/fontpath.d], - [DEFAULT_FONT_PATH='catalogue:${sysconfdir}/X11/fontpath.d'], diff --git a/moblin-use_preferred_mode_for_all_outputs.diff b/moblin-use_preferred_mode_for_all_outputs.diff deleted file mode 100644 index f872dc4..0000000 --- a/moblin-use_preferred_mode_for_all_outputs.diff +++ /dev/null @@ -1,19 +0,0 @@ -diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c -index 69f687b..5aae114 100644 ---- a/hw/xfree86/modes/xf86Crtc.c -+++ b/hw/xfree86/modes/xf86Crtc.c -@@ -2365,13 +2365,7 @@ xf86InitialConfiguration (ScrnInfoPtr scrn, Bool canGrow) - - xf86CollectEnabledOutputs(scrn, config, enabled); - -- if (xf86TargetUserpref(scrn, config, modes, enabled, width, height)) -- xf86DrvMsg(i, X_INFO, "Using user preference for initial modes\n"); -- else if (xf86TargetPreferred(scrn, config, modes, enabled, width, height)) -- xf86DrvMsg(i, X_INFO, "Using exact sizes for initial modes\n"); -- else if (xf86TargetAspect(scrn, config, modes, enabled, width, height)) -- xf86DrvMsg(i, X_INFO, "Using fuzzy aspect match for initial modes\n"); -- else if (xf86TargetFallback(scrn, config, modes, enabled, width, height)) -+ if (xf86TargetFallback(scrn, config, modes, enabled, width, height)) - xf86DrvMsg(i, X_INFO, "Using sloppy heuristic for initial modes\n"); - else - xf86DrvMsg(i, X_WARNING, "Unable to find initial modes\n"); diff --git a/mouse.diff b/mouse.diff deleted file mode 100644 index 00da937..0000000 --- a/mouse.diff +++ /dev/null @@ -1,15 +0,0 @@ -Index: hw/xfree86/common/xf86Configure.c -================================================================================ ---- hw/xfree86/common/xf86Configure.c -+++ hw/xfree86/common/xf86Configure.c -@@ -64,8 +64,8 @@ - static char *DFLT_MOUSE_DEV = "/dev/sysmouse"; - static char *DFLT_MOUSE_PROTO = "auto"; - #elif defined(linux) --static char DFLT_MOUSE_DEV[] = "/dev/input/mice"; --static char DFLT_MOUSE_PROTO[] = "auto"; -+static char* DFLT_MOUSE_DEV = "/dev/input/mice"; -+static char* DFLT_MOUSE_PROTO = "auto"; - #else - static char *DFLT_MOUSE_DEV = "/dev/mouse"; - static char *DFLT_MOUSE_PROTO = "auto"; diff --git a/p_bug96328.diff b/p_bug96328.diff deleted file mode 100644 index 8281bb0..0000000 --- a/p_bug96328.diff +++ /dev/null @@ -1,52 +0,0 @@ -Index: hw/xfree86/common/xf86Configure.c -================================================================================ ---- hw/xfree86/common/xf86Configure.c -+++ hw/xfree86/common/xf86Configure.c -@@ -250,23 +250,35 @@ - - /* Crude mechanism to auto-detect mouse (os dependent) */ - { -- int fd; -+ int fd = -1; - #ifdef WSCONS_SUPPORT -- fd = open("/dev/wsmouse", 0); -- if (fd >= 0) { -- DFLT_MOUSE_DEV = "/dev/wsmouse"; -- DFLT_MOUSE_PROTO = "wsmouse"; -- close(fd); -- } else { -- ErrorF("cannot open /dev/wsmouse\n"); -+ if (fd == -1) { -+ fd = open("/dev/wsmouse", 0); -+ if (fd != -1) { -+ DFLT_MOUSE_DEV = "/dev/wsmouse"; -+ DFLT_MOUSE_PROTO = "wsmouse"; -+ close(fd); -+ } else { -+ ErrorF("cannot open /dev/wsmouse\n"); -+ } - } - #endif - - #ifndef __SCO__ -- fd = open(DFLT_MOUSE_DEV, 0); -- if (fd != -1) { -- foundMouse = TRUE; -- close(fd); -+ if (fd == -1) { -+ fd = open(DFLT_MOUSE_DEV, 0); -+# ifdef linux -+ if (fd == -1) { -+ char *name = "/dev/input/mice"; -+ fd = open(name, 0); -+ if (fd != -1) -+ DFLT_MOUSE_DEV = name; -+ } -+# endif -+ if (fd != -1) { -+ foundMouse = TRUE; -+ close(fd); -+ } - } - #else - foundMouse = TRUE; diff --git a/p_xkills_wrong_client.diff b/p_xkills_wrong_client.diff deleted file mode 100644 index a980975..0000000 --- a/p_xkills_wrong_client.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: os/connection.c -================================================================================ ---- os/connection.c -+++ os/connection.c -@@ -999,7 +999,7 @@ - do { - r = Select (curclient + 1, &tmask, NULL, NULL, ¬ime); - } while (r < 0 && (errno == EINTR || errno == EAGAIN)); -- if (r < 0) -+ if (r < 0 && (errno == EBADF)) - if (ConnectionTranslation[curclient] > 0) - CloseDownClient(clients[ConnectionTranslation[curclient]]); - mask &= ~((fd_mask)1 << curoff); diff --git a/p_xorg_acpi.diff b/p_xorg_acpi.diff deleted file mode 100644 index c81a87a..0000000 --- a/p_xorg_acpi.diff +++ /dev/null @@ -1,121 +0,0 @@ -Index: hw/xfree86/os-support/linux/lnx_acpi.c -================================================================================ ---- hw/xfree86/os-support/linux/lnx_acpi.c -+++ hw/xfree86/os-support/linux/lnx_acpi.c -@@ -32,8 +32,10 @@ - #define ACPI_VIDEO_HEAD_INVALID (~0u - 1) - #define ACPI_VIDEO_HEAD_END (~0u) - -+static PMClose doLnxACPIOpen(void); - static void lnxCloseACPI(void); - static pointer ACPIihPtr = NULL; -+static OsTimerPtr acpiTimer = NULL; - PMClose lnxACPIOpen(void); - - /* in milliseconds */ -@@ -52,6 +54,22 @@ - - #define LINE_LENGTH 80 - -+static CARD32 -+lnxACPICheckTimer(OsTimerPtr timer, CARD32 now, pointer arg) -+{ -+#if DEBUG -+ ErrorF("ACPI: trying to reopen\n"); -+#endif -+ if (doLnxACPIOpen()) { -+#if DEBUG -+ ErrorF("ACPI: successfully reopened\n"); -+#endif -+ acpiTimer = NULL; -+ return 0; -+ } -+ return 5000; -+} -+ - static int - lnxACPIGetEventFromOs(int fd, pmEvent *events, int num) - { -@@ -127,15 +145,14 @@ - } - } - --PMClose --lnxACPIOpen(void) -+static PMClose -+doLnxACPIOpen(void) - { - int fd; - struct sockaddr_un addr; - int r = -1; - static int warned = 0; - -- DebugF("ACPI: OSPMOpen called\n"); - if (ACPIihPtr || !xf86Info.pmFlag) - return NULL; - -@@ -164,6 +181,27 @@ - return lnxCloseACPI; - } - -+PMClose -+lnxACPIPoll(void) -+{ -+ TimerSet(NULL, 0, 5000, lnxACPICheckTimer, NULL); -+ return lnxCloseACPI; -+} -+ -+PMClose -+lnxACPIOpen(void) -+{ -+ PMClose ret; -+#ifdef DEBUG -+ ErrorF("ACPI: OSPMOpen called\n"); -+#endif -+ if (!(ret = doLnxACPIOpen())) -+ xf86MsgVerb(X_WARNING,3,"Open ACPI failed (%s) (%s)\n", ACPI_SOCKET, -+ strerror(errno)); -+ -+ return ret; -+} -+ - static void - lnxCloseACPI(void) - { -@@ -175,5 +213,11 @@ - shutdown(fd, 2); - close(fd); - ACPIihPtr = NULL; -+ xf86PMGetEventFromOs = NULL; -+ xf86PMConfirmEventToOs = NULL; -+ if (acpiTimer) { -+ TimerCancel(acpiTimer); -+ acpiTimer = NULL; -+ } - } - } ---- hw/xfree86/os-support/linux/lnx_apm.c -+++ hw/xfree86/os-support/linux/lnx_apm.c -@@ -12,6 +12,7 @@ - - #ifdef HAVE_ACPI - extern PMClose lnxACPIOpen(void); -+extern PMClose lnxACPIPoll(void); - #endif - - #ifdef HAVE_APM -@@ -149,6 +150,14 @@ - ret = lnxAPMOpen(); - #endif - -+#ifdef HAVE_ACPI -+ /* if we can neither open ACPI nor APM poll for an ACPI service to -+ become available */ -+ -+ if (!ret && !xf86acpiDisableFlag) -+ ret = lnxACPIPoll(); -+#endif -+ - return ret; - } - diff --git a/pixman.diff b/pixman.diff deleted file mode 100644 index b3ea68e..0000000 --- a/pixman.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: include/miscstruct.h -================================================================================ ---- include/miscstruct.h -+++ include/miscstruct.h -@@ -50,7 +50,7 @@ - - #include "misc.h" - #include --#include -+#include - - typedef xPoint DDXPointRec; - diff --git a/u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch b/u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch new file mode 100644 index 0000000..42a3f9a --- /dev/null +++ b/u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch @@ -0,0 +1,290 @@ +From 142ba992065dd9c37a9d06dc6e96cfc9adfb6be0 Mon Sep 17 00:00:00 2001 +From: Egbert Eich +Date: Tue, 5 Jul 2011 06:56:43 +0200 +Subject: [PATCH] OS/acpi: Reconnect to acpid when it gets restarted. +Patch-mainline: To be upstreamed + +On Linux the Xserver connects to the ACPI daemon to +receive power management events. If this daemon isn't +started when the server starts or goes down the connection +is lost. +When this happens we add a timer which periodically +tries to reconnect. + +Signed-off-by: Egbert Eich +--- + hw/xfree86/os-support/linux/lnx_acpi.c | 68 ++++++++++++++++++++++++++----- + hw/xfree86/os-support/linux/lnx_apm.c | 9 ++++ + 2 files changed, 66 insertions(+), 11 deletions(-) + +diff --git a/hw/xfree86/os-support/linux/lnx_acpi.c b/hw/xfree86/os-support/linux/lnx_acpi.c +index 5fad194..8dd6881 100644 +--- a/hw/xfree86/os-support/linux/lnx_acpi.c ++++ b/hw/xfree86/os-support/linux/lnx_acpi.c +@@ -32,9 +32,12 @@ + #define ACPI_VIDEO_HEAD_INVALID (~0u - 1) + #define ACPI_VIDEO_HEAD_END (~0u) + ++static PMClose doLnxACPIOpen(void); + static void lnxCloseACPI(void); + static pointer ACPIihPtr = NULL; ++static OsTimerPtr acpiTimer = NULL; + PMClose lnxACPIOpen(void); ++PMClose lnxACPIPoll(void); + + /* in milliseconds */ + #define ACPI_REOPEN_DELAY 1000 +@@ -52,6 +55,22 @@ lnxACPIReopen(OsTimerPtr timer, CARD32 time, pointer arg) + + #define LINE_LENGTH 80 + ++static CARD32 ++lnxACPICheckTimer(OsTimerPtr timer, CARD32 now, pointer arg) ++{ ++#if DEBUG ++ ErrorF("ACPI: trying to reopen\n"); ++#endif ++ if (doLnxACPIOpen()) { ++#if DEBUG ++ ErrorF("ACPI: successfully reopened\n"); ++#endif ++ acpiTimer = NULL; ++ return 0; ++ } ++ return 10000; ++} ++ + static int + lnxACPIGetEventFromOs(int fd, pmEvent *events, int num) + { +@@ -127,33 +146,35 @@ lnxACPIConfirmEventToOs(int fd, pmEvent event) + } + } + +-PMClose +-lnxACPIOpen(void) ++static PMClose ++doLnxACPIOpen(void) + { +- int fd; ++ int fd = -1; + struct sockaddr_un addr; + int r = -1; + static int warned = 0; + +- DebugF("ACPI: OSPMOpen called\n"); + if (ACPIihPtr || !xf86Info.pmFlag) + return NULL; + + DebugF("ACPI: Opening device\n"); +- if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) > -1) { ++ fd = socket(AF_UNIX, SOCK_STREAM, 0); ++ if (fd > -1) { + memset(&addr, 0, sizeof(addr)); + addr.sun_family = AF_UNIX; + strcpy(addr.sun_path, ACPI_SOCKET); +- if ((r = connect(fd, (struct sockaddr*)&addr, sizeof(addr))) == -1) { +- if (!warned) ++ r = connect(fd, (struct sockaddr*)&addr, sizeof(addr)); ++ if (r == -1) { ++ if (errno != warned) + xf86MsgVerb(X_WARNING,3,"Open ACPI failed (%s) (%s)\n", + ACPI_SOCKET, strerror(errno)); +- warned = 1; +- shutdown(fd, 2); ++ warned = errno; ++ shutdown(fd, SHUT_RDWR); + close(fd); + return NULL; + } +- } ++ } else ++ return NULL; + + xf86PMGetEventFromOs = lnxACPIGetEventFromOs; + xf86PMConfirmEventToOs = lnxACPIConfirmEventToOs; +@@ -164,6 +185,25 @@ lnxACPIOpen(void) + return lnxCloseACPI; + } + ++PMClose ++lnxACPIPoll(void) ++{ ++ TimerSet(NULL, 0, 10000, lnxACPICheckTimer, NULL); ++ return lnxCloseACPI; ++} ++ ++PMClose ++lnxACPIOpen(void) ++{ ++ PMClose ret; ++#ifdef DEBUG ++ ErrorF("ACPI: OSPMOpen called\n"); ++#endif ++ ret = doLnxACPIOpen(); ++ ++ return ret; ++} ++ + static void + lnxCloseACPI(void) + { +@@ -172,8 +212,14 @@ lnxCloseACPI(void) + DebugF("ACPI: Closing device\n"); + if (ACPIihPtr) { + fd = xf86RemoveGeneralHandler(ACPIihPtr); +- shutdown(fd, 2); ++ shutdown(fd, SHUT_RDWR); + close(fd); + ACPIihPtr = NULL; ++ xf86PMGetEventFromOs = NULL; ++ xf86PMConfirmEventToOs = NULL; ++ if (acpiTimer) { ++ TimerCancel(acpiTimer); ++ acpiTimer = NULL; ++ } + } + } +diff --git a/hw/xfree86/os-support/linux/lnx_apm.c b/hw/xfree86/os-support/linux/lnx_apm.c +index 54c6989..c8b254f 100644 +--- a/hw/xfree86/os-support/linux/lnx_apm.c ++++ b/hw/xfree86/os-support/linux/lnx_apm.c +@@ -12,6 +12,7 @@ + + #ifdef HAVE_ACPI + extern PMClose lnxACPIOpen(void); ++extern PMClose lnxACPIPoll(void); + #endif + + #ifdef HAVE_APM +@@ -149,6 +150,14 @@ xf86OSPMOpen(void) + ret = lnxAPMOpen(); + #endif + ++#ifdef HAVE_ACPI ++ /* if we can neither open ACPI nor APM poll for an ACPI service to ++ become available */ ++ ++ if (!ret && !xf86acpiDisableFlag) ++ ret = lnxACPIPoll(); ++#endif ++ + return ret; + } + +-- +1.6.0.2 + +From 3f35d15f7c7eb202de36e2d1040f27ef7b38c1d2 Mon Sep 17 00:00:00 2001 +From: Egbert Eich +Date: Thu, 7 Jul 2011 09:01:35 +0200 +Subject: [PATCH] OS/ACPI: Make socket to read from acpid non-blocking. + +If acpid for some reason does not service a connect() this +function may hang forever stalling the Xserver. To prevent +this make the socket non-blocking. If connect returns +EINPROGRESS use select() and getsockopt() to check for +completion of the connect request. +select() gets a different timeout depending if it is called +during startup or to do a reconnect. + +Signed-off-by: Egbert Eich +--- + hw/xfree86/os-support/linux/lnx_acpi.c | 34 +++++++++++++++++++++++++++---- + 1 files changed, 29 insertions(+), 5 deletions(-) + +diff --git a/hw/xfree86/os-support/linux/lnx_acpi.c b/hw/xfree86/os-support/linux/lnx_acpi.c +index 8dd6881..f0e6eb4 100644 +--- a/hw/xfree86/os-support/linux/lnx_acpi.c ++++ b/hw/xfree86/os-support/linux/lnx_acpi.c +@@ -32,7 +32,7 @@ + #define ACPI_VIDEO_HEAD_INVALID (~0u - 1) + #define ACPI_VIDEO_HEAD_END (~0u) + +-static PMClose doLnxACPIOpen(void); ++static PMClose doLnxACPIOpen(struct timeval *); + static void lnxCloseACPI(void); + static pointer ACPIihPtr = NULL; + static OsTimerPtr acpiTimer = NULL; +@@ -58,10 +58,11 @@ lnxACPIReopen(OsTimerPtr timer, CARD32 time, pointer arg) + static CARD32 + lnxACPICheckTimer(OsTimerPtr timer, CARD32 now, pointer arg) + { ++ struct timeval timeval = { 0, 0 }; + #if DEBUG + ErrorF("ACPI: trying to reopen\n"); + #endif +- if (doLnxACPIOpen()) { ++ if (doLnxACPIOpen(&timeval)) { + #if DEBUG + ErrorF("ACPI: successfully reopened\n"); + #endif +@@ -147,7 +148,7 @@ lnxACPIConfirmEventToOs(int fd, pmEvent event) + } + + static PMClose +-doLnxACPIOpen(void) ++doLnxACPIOpen(struct timeval *tv_p) + { + int fd = -1; + struct sockaddr_un addr; +@@ -158,13 +159,34 @@ doLnxACPIOpen(void) + return NULL; + + DebugF("ACPI: Opening device\n"); +- fd = socket(AF_UNIX, SOCK_STREAM, 0); ++ fd = socket(AF_UNIX, SOCK_STREAM | SOCK_NONBLOCK, 0); + if (fd > -1) { + memset(&addr, 0, sizeof(addr)); + addr.sun_family = AF_UNIX; + strcpy(addr.sun_path, ACPI_SOCKET); + r = connect(fd, (struct sockaddr*)&addr, sizeof(addr)); + if (r == -1) { ++ int sock_errno = errno; ++ if (sock_errno == EINPROGRESS) { ++ fd_set fds; ++ int result; ++ do { ++ FD_ZERO(&fds); ++ FD_SET(fd, &fds); ++ result = select(fd + 1, NULL, &fds, NULL, tv_p); ++ } while (result < 0 && errno == EINTR); ++ if (result < 0) ++ sock_errno = errno; ++ else if (result > 0) { ++ int sock_errno; ++ socklen_t size = sizeof(sock_errno); ++ if (0 > getsockopt(fd, SOL_SOCKET, SO_ERROR, &sock_errno, ++ &size)) ++ sock_errno = errno; ++ if (!sock_errno) ++ goto success; ++ } ++ } + if (errno != warned) + xf86MsgVerb(X_WARNING,3,"Open ACPI failed (%s) (%s)\n", + ACPI_SOCKET, strerror(errno)); +@@ -176,6 +198,7 @@ doLnxACPIOpen(void) + } else + return NULL; + ++ success: + xf86PMGetEventFromOs = lnxACPIGetEventFromOs; + xf86PMConfirmEventToOs = lnxACPIConfirmEventToOs; + ACPIihPtr = xf86AddGeneralHandler(fd,xf86HandlePMEvents,NULL); +@@ -196,10 +219,11 @@ PMClose + lnxACPIOpen(void) + { + PMClose ret; ++ struct timeval timeval = { 0, 30000 }; + #ifdef DEBUG + ErrorF("ACPI: OSPMOpen called\n"); + #endif +- ret = doLnxACPIOpen(); ++ ret = doLnxACPIOpen(&timeval); + + return ret; + } +-- +1.7.3.4 + diff --git a/use-last-screen.patch b/use-last-screen.patch deleted file mode 100644 index b9c07ca..0000000 --- a/use-last-screen.patch +++ /dev/null @@ -1,56 +0,0 @@ -From ee0e658bb6cb0d1290072090f1de90ff44145365 Mon Sep 17 00:00:00 2001 -From: Dan Nicholson -Date: Thu, 16 Dec 2010 06:01:06 -0800 -Subject: [PATCH] xfree86: Use last Screen section found to prefer xorg.conf - -Allowing multiple .conf files with xorg.conf.d works well for InputClass -where any section in xorg.conf would override settings from previous -.conf files typically installed by the distro. This does not work well -with Screen sections where the first section found has been used when -the Layout doesn't specify a Screen. Instead, use the last Screen -section found to give preference to xorg.conf and match the InputScreen -semantics. - -Signed-off-by: Dan Nicholson ---- - hw/xfree86/common/xf86Config.c | 10 ++++++++-- - 1 files changed, 8 insertions(+), 2 deletions(-) - -diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c -index 5800700..b2fc8e3 100644 ---- a/hw/xfree86/common/xf86Config.c -+++ b/hw/xfree86/common/xf86Config.c -@@ -1678,7 +1678,7 @@ configLayout(serverLayoutPtr servlayoutp, XF86ConfLayoutPtr conf_layout, - } - - /* -- * No layout section, so find the first Screen section and set that up as -+ * No layout section, so find the last Screen section and set that up as - * the only active screen. - */ - static Bool -@@ -1697,7 +1697,7 @@ configImpliedLayout(serverLayoutPtr servlayoutp, XF86ConfScreenPtr conf_screen, - /* - * which screen section is the active one? - * -- * If there is a -screen option, use that one, otherwise use the first -+ * If there is a -screen option, use that one, otherwise use the last - * one. - */ - -@@ -1710,6 +1710,12 @@ configImpliedLayout(serverLayoutPtr servlayoutp, XF86ConfScreenPtr conf_screen, - } - conf_screen = s; - from = X_CMDLINE; -+ } else if (conf_screen) { -+ /* Use the last Screen in the list */ -+ s = conf_screen; -+ while (s->list.next) -+ s = s->list.next; -+ conf_screen = s; - } - - /* We have exactly one screen */ --- -1.7.2.3 - diff --git a/xephyr.diff b/xephyr.diff deleted file mode 100644 index 0eda01e..0000000 --- a/xephyr.diff +++ /dev/null @@ -1,21 +0,0 @@ -Index: hw/kdrive/Makefile.am -================================================================================ ---- hw/kdrive/Makefile.am -+++ hw/kdrive/Makefile.am -@@ -1,5 +1,5 @@ - if BUILD_KDRIVEFBDEVLIB --FBDEV_SUBDIRS = fbdev -+FBDEV_SUBDIRS = - endif - - if XFAKESERVER -@@ -16,8 +16,7 @@ - - SERVER_SUBDIRS = \ - $(FBDEV_SUBDIRS) \ -- $(XEPHYR_SUBDIRS) \ -- $(XFAKE_SUBDIRS) -+ $(XEPHYR_SUBDIRS) - - SUBDIRS = \ - src \ diff --git a/xorg-docs.diff b/xorg-docs.diff deleted file mode 100644 index ce589a6..0000000 --- a/xorg-docs.diff +++ /dev/null @@ -1,29 +0,0 @@ ---- man/Makefile.am.orig 2010-09-14 01:25:46.000000000 +0200 -+++ man/Makefile.am 2010-11-12 13:28:31.000000000 +0100 -@@ -23,12 +23,8 @@ - miscmandir = $(MISC_MAN_DIR) - - miscman_PRE = \ -- Consortium.man \ - Xsecurity.man \ -- Standards.man \ -- X.man \ -- XOrgFoundation.man \ -- XProjectTeam.man -+ X.man - - miscman_DATA = $(miscman_PRE:man=@MISC_MAN_SUFFIX@) - ---- Makefile.am.orig 2010-11-12 13:45:19.000000000 +0100 -+++ Makefile.am 2010-11-12 13:45:32.000000000 +0100 -@@ -20,9 +20,7 @@ - # - # Process this file with autoconf to create configure. - --SUBDIRS = general man specs -- --dist_doc_DATA = MAINTAINERS -+SUBDIRS = man - - MAINTAINERCLEANFILES = ChangeLog INSTALL - EXTRA_DIST = \ diff --git a/xorg-server-1.8.0.diff b/xorg-server-1.8.0.diff deleted file mode 100644 index c6b8168..0000000 --- a/xorg-server-1.8.0.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- config/Makefile.am.orig 2010-06-11 04:14:57.000000000 +0200 -+++ config/Makefile.am 2010-08-23 15:47:19.000000000 +0200 -@@ -9,7 +9,7 @@ - libconfig_la_SOURCES += udev.c - libconfig_la_LIBADD = $(UDEV_LIBS) - --xorgconfddir = $(datadir)/X11/$(XF86CONFIGDIR) -+xorgconfddir = $(sysconfdir)/X11/$(XF86CONFIGDIR) - xorgconfd_DATA = 10-evdev.conf - - else diff --git a/xorg-server-nohwaccess.diff b/xorg-server-nohwaccess.diff deleted file mode 100644 index 275f15b..0000000 --- a/xorg-server-nohwaccess.diff +++ /dev/null @@ -1,52 +0,0 @@ -Index: xorg-server-1.6.3/hw/xfree86/os-support/linux/lnx_init.c -=================================================================== -Index: xorg-server-1.6.3/hw/xfree86/os-support/linux/lnx_video.c -=================================================================== ---- xorg-server-1.6.3.orig/hw/xfree86/os-support/linux/lnx_video.c -+++ xorg-server-1.6.3/hw/xfree86/os-support/linux/lnx_video.c -@@ -51,6 +51,7 @@ - #define MAP_FAILED ((void *)-1) - #endif - -+extern Bool NoHwAccess; - static Bool ExtendedEnabled = FALSE; - - #ifdef __ia64__ -@@ -509,6 +510,9 @@ xf86EnableIO(void) - int fd; - unsigned int ioBase_phys; - #endif -+ /* Fake it... */ -+ if (NoHwAccess) -+ return TRUE; - - if (ExtendedEnabled) - return TRUE; ---- xorg-server-1.9.0/hw/xfree86/os-support/linux/lnx_init.c.orig 2010-06-10 16:07:55.000000000 +0200 -+++ xorg-server-1.9.0/hw/xfree86/os-support/linux/lnx_init.c 2010-08-23 15:38:45.000000000 +0200 -@@ -42,6 +42,7 @@ static Bool KeepTty = FALSE; - static int VTnum = -1; - static Bool VTSwitch = TRUE; - static Bool ShareVTs = FALSE; -+Bool NoHwAccess = FALSE; - static int activeVT = -1; - - static int vtPermSave[4]; -@@ -377,6 +378,11 @@ xf86ProcessArgument(int argc, char *argv - ShareVTs = TRUE; - return 1; - } -+ if (!strcmp(argv[i], "-nohwaccess")) -+ { -+ NoHwAccess = TRUE; -+ return(1); -+ } - if ((argv[i][0] == 'v') && (argv[i][1] == 't')) - { - if (sscanf(argv[i], "vt%2d", &VTnum) == 0) -@@ -398,4 +404,5 @@ xf86UseMsg(void) - ErrorF("don't detach controlling tty (for debugging only)\n"); - ErrorF("-novtswitch don't immediately switch to new VT\n"); - ErrorF("-sharevts share VTs with another X server\n"); -+ ErrorF("-nohwaccess don't access hardware ports directly\n"); - } diff --git a/xorg-server-option_libxf86config.diff b/xorg-server-option_libxf86config.diff deleted file mode 100644 index 6eb2cce..0000000 --- a/xorg-server-option_libxf86config.diff +++ /dev/null @@ -1,122 +0,0 @@ ---- hw/xfree86/parser/InputClass.c.orig 2010-08-13 07:53:48.000000000 +0200 -+++ hw/xfree86/parser/InputClass.c 2010-08-23 15:55:16.000000000 +0200 -@@ -65,6 +65,47 @@ xf86ConfigSymTabRec InputClassTab[] = - - #define TOKEN_SEP "|" - -+/* -+ * Tokenize a string into a NULL terminated array of strings. Always returns -+ * an allocated array unless an error occurs. -+ */ -+char** -+m_xstrtokenize(const char *str, const char *separators) -+{ -+ char **list, **nlist; -+ char *tok, *tmp; -+ unsigned num = 0, n; -+ -+ if (!str) -+ return NULL; -+ list = calloc(1, sizeof(*list)); -+ if (!list) -+ return NULL; -+ tmp = strdup(str); -+ if (!tmp) -+ goto error; -+ for (tok = strtok(tmp, separators); tok; tok = strtok(NULL, separators)) { -+ nlist = realloc(list, (num + 2) * sizeof(*list)); -+ if (!nlist) -+ goto error; -+ list = nlist; -+ list[num] = strdup(tok); -+ if (!list[num]) -+ goto error; -+ list[++num] = NULL; -+ } -+ free(tmp); -+ return list; -+ -+error: -+ free(tmp); -+ for (n = 0; n < num; n++) -+ free(list[n]); -+ free(list); -+ return NULL; -+} -+ -+ - static void - add_group_entry(struct list *head, char **values) - { -@@ -125,49 +166,49 @@ xf86parseInputClassSection(void) - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchProduct"); - add_group_entry(&ptr->match_product, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_VENDOR: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchVendor"); - add_group_entry(&ptr->match_vendor, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_DEVICE_PATH: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchDevicePath"); - add_group_entry(&ptr->match_device, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_OS: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchOS"); - add_group_entry(&ptr->match_os, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_PNPID: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchPnPID"); - add_group_entry(&ptr->match_pnpid, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_USBID: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchUSBID"); - add_group_entry(&ptr->match_usbid, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_DRIVER: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchDriver"); - add_group_entry(&ptr->match_driver, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_TAG: - if (xf86getSubToken(&(ptr->comment)) != STRING) - Error(QUOTE_MSG, "MatchTag"); - add_group_entry(&ptr->match_tag, -- xstrtokenize(val.str, TOKEN_SEP)); -+ m_xstrtokenize(val.str, TOKEN_SEP)); - break; - case MATCH_IS_KEYBOARD: - if (xf86getSubToken(&(ptr->comment)) != STRING) ---- hw/xfree86/parser/Layout.c -+++ hw/xfree86/parser/Layout.c -@@ -449,7 +449,10 @@ - /* add all AutoServerLayout devices to the server layout */ - while (input) - { -- if (xf86CheckBoolOption(input->inp_option_lst, "AutoServerLayout", FALSE)) -+ Bool asl_value = FALSE; -+ char *s = xf86findOptionValue(input->inp_option_lst ,"AutoServerLayout"); -+ Bool asl_found = xf86getBoolValue(&asl_value, s); -+ if (asl_found == TRUE && asl_value == TRUE) - { - XF86ConfInputrefPtr iref = layout->lay_input_lst; - diff --git a/xorg-x11-nonroot-vesa.patch b/xorg-x11-nonroot-vesa.patch deleted file mode 100644 index 9d831f1..0000000 --- a/xorg-x11-nonroot-vesa.patch +++ /dev/null @@ -1,14 +0,0 @@ -Index: xorg-server-1.6.3.901/hw/xfree86/common/xf86AutoConfig.c -================================================================================ ---- xorg-server-1.7.99/hw/xfree86/common/xf86AutoConfig.c -+++ xorg-server-1.7.99/hw/xfree86/common/xf86AutoConfig.c -@@ -535,7 +535,8 @@ - #if !defined(__linux__) && defined(__sparc__) - matches[i++] = xnfstrdup("wsfb"); - #else -- matches[i++] = xnfstrdup("vesa"); -+ if (geteuid() == 0) -+ matches[i++] = xnfstrdup("vesa"); - #endif - } - } diff --git a/xorg-x11-server.changes b/xorg-x11-server.changes index 60bf471..cf625d5 100644 --- a/xorg-x11-server.changes +++ b/xorg-x11-server.changes @@ -1,3 +1,140 @@ +------------------------------------------------------------------- +Fri Jul 8 08:20:41 UTC 2011 - eich@suse.de + +- update: + * randr1_1-sig11.diff + removed accidentally forgotten debugging code. + * u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch + made socket non-blocking. Idea taken from a pach for SLES11. + +------------------------------------------------------------------- +Thu Jul 7 16:02:13 UTC 2011 - eich@suse.de + +- don't look for 10-evdev.conf for anything older than 11.3 + (this includes SLE-11). + +------------------------------------------------------------------- +Thu Jul 7 10:10:34 UTC 2011 - eich@suse.de + +- remove use-last-screen.patch: + This patch has been rejected upstream. We will try to resolve + this issue differently by not providing any screen, monitor or + device section. + +------------------------------------------------------------------- +Thu Jul 7 10:08:05 UTC 2011 - eich@suse.de + +- remove disable-fbblt-opt.diff: + We are unable to reproduce this issue any more. + So let's remove the workaround and start from scratch + when issue resurfaces and find a proper fix. + +------------------------------------------------------------------- +Wed Jul 6 09:04:30 UTC 2011 - eich@suse.de + +- fixed bug-197858_dpms.diff: + removed pieces that have been solved differently today. + +------------------------------------------------------------------- +Wed Jul 6 07:48:17 UTC 2011 - eich@suse.de + +- remove moblin-use_preferred_mode_for_all_outputs.diff: + remove moblin specific patches. + +------------------------------------------------------------------- +Tue Jul 5 13:54:21 UTC 2011 - eich@suse.de + +- rename edit_data_sanity_check.diff -> edid_data_sanity_check.diff + +------------------------------------------------------------------- +Tue Jul 5 13:44:54 UTC 2011 - eich@suse.de + +- remove p_xkills_wrong_client.diff: + made obsolete by commit b7f3618f. + +------------------------------------------------------------------- +Tue Jul 5 12:45:46 UTC 2011 - eich@suse.de + +- remove xorg-server-1.8.0.diff: + issue is now resolved in spec file. + +------------------------------------------------------------------- +Tue Jul 5 05:11:47 UTC 2011 - eich@suse.de + +- fix zap_warning_fix.diff: + recover from noisy people. + +------------------------------------------------------------------- +Tue Jul 5 05:09:40 UTC 2011 - eich@suse.de + +- remove p_xorg_acpi.diff + add u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch + removed redundant error message. + +------------------------------------------------------------------- +Mon Jul 4 17:01:40 UTC 2011 - eich@suse.de + +- remove mouse.diff: + Never understood what this patch was good for. + +------------------------------------------------------------------- +Mon Jul 4 16:58:46 UTC 2011 - eich@suse.de + +- remove p_bug96328.diff: + /dev/input/mice is the default mouse for X -configure + on Linux for a long time already. + +------------------------------------------------------------------- +Mon Jul 4 12:19:43 UTC 2011 - eich@suse.de + +- remove xephyr.diff: + solved by configure options in spec file. + +------------------------------------------------------------------- +Mon Jul 4 12:10:14 UTC 2011 - eich@suse.de + +- remove libdrm.diff: + not needed any more, drivers seem to be fixed. + +------------------------------------------------------------------- +Mon Jul 4 11:32:31 UTC 2011 - eich@suse.de + +- remove xorg-docs.diff: + solved in spec file. + +------------------------------------------------------------------- +Mon Jul 4 10:06:49 UTC 2011 - eich@suse.de + +- remove pixman.diff: + Doesn't seem to be needed any more. + +------------------------------------------------------------------- +Mon Jul 4 05:58:11 UTC 2011 - eich@suse.de + +- remove xorg-x11-nonroot-vesa.patch, org-server-nohwaccess.diff: + There are other things missing to make those patches useful. + +------------------------------------------------------------------- +Fri Jul 1 14:18:49 UTC 2011 - eich@suse.de + +- remove: xserver-1.6.1-nouveau.patch. + This patch was only cosmetic. + +------------------------------------------------------------------- +Fri Jul 1 13:41:18 UTC 2011 - eich@suse.de + +- remove: CVE-2010-2240-address_space_limit.patch + CVE-2010-2240-tree_depth_limit.patch + These security issues have been handled in the Linux kernel in a + much more general fashion. + +------------------------------------------------------------------- +Fri Jul 1 11:37:33 UTC 2011 - eich@suse.de + +- remove: bitmap_always_unscaled.diff + missing_font_paths.diff + This has now been solved in the spec file directly. + ------------------------------------------------------------------- Thu May 26 14:47:53 UTC 2011 - mhopf@novell.com diff --git a/xorg-x11-server.spec b/xorg-x11-server.spec index b1447dc..a567efc 100644 --- a/xorg-x11-server.spec +++ b/xorg-x11-server.spec @@ -17,8 +17,6 @@ # norootforbuild -%define moblin 0 - Name: xorg-x11-server %define dirsuffix 1.9.3 %define vnc 1 @@ -55,17 +53,10 @@ Source4: xorgcfg.tar.bz2 Source5: modprobe.nvidia Source7: xorg-docs-1.6.tar.bz2 Source8: xorg-backtrace -Patch1: fpic.diff Patch2: p_default-module-path.diff Patch6: pu_fixes.diff -Patch8: p_bug96328.diff -Patch13: p_xorg_acpi.diff -Patch14: p_xkills_wrong_client.diff +Patch13: u_OS-acpi-Reconnect-to-acpid-when-it-gets-restarted.patch Patch16: p_xnest-ignore-getimage-errors.diff -Patch23: disable-fbblt-opt.diff -Patch27: mouse.diff -Patch29: xephyr.diff -Patch36: libdrm.diff %if %vnc ### Dan Nicholson #http://people.freedesktop.org/~dbn/xorg-server-xf4vnc.patch @@ -82,13 +73,10 @@ Patch50: xorg-server-xf4vnc-fixes_1_9.diff Patch51: xorg-server-xf4vnc-fix-keyboard-layout-handling.diff %endif Patch45: bug-197858_dpms.diff -Patch67: xorg-docs.diff Patch77: fbdevhw.diff -Patch79: edit_data_sanity_check.diff -Patch93: pixman.diff +Patch79: edid_data_sanity_check.diff Patch101: zap_warning_xserver.diff Patch103: confine_to_shape.diff -Patch104: bitmap_always_unscaled.diff Patch106: randr1_1-sig11.diff Patch112: fix-dpi-values.diff Patch123: vidmode-sig11.diff @@ -98,36 +86,24 @@ Patch128: pci-legacy-mem-fallback.diff Patch129: bug474071-fix1.diff Patch143: autoconfig_fallback_fbdev_first.diff Patch145: driver-autoconfig.diff -Patch147: xserver-1.6.1-nouveau.patch Patch162: cache-xkbcomp-output-for-fast-start-up.patch Patch163: xserver-bg-none-root.patch Patch164: xorg-detect-psb.patch -Patch168: xorg-server-nohwaccess.diff -Patch169: xorg-x11-nonroot-vesa.patch Patch200: bug534768-prefer_local_symbols.patch Patch202: 0001-Check-harder-for-primary-PCI-device.patch Patch203: 0001-Fix-segfault-when-killing-X-with-ctrl-alt-backspace.patch -Patch204: missing_font_paths.diff -Patch205: xorg-server-1.8.0.diff Patch206: fix_fglrx_screendepth_issue.patch -Patch207: xorg-server-option_libxf86config.diff Patch210: pio_ia64.diff Patch211: 0001-Prevent-XSync-Alarms-from-senslessly-calling-CheckTr.patch Patch213: xorg-server-xdmcp.patch -Patch217: CVE-2010-2240-address_space_limit.patch -Patch218: CVE-2010-2240-tree_depth_limit.patch Patch220: Use-external-tool-for-creating-backtraces-on-crashes.patch Patch221: commit-5c6a2f9.diff Patch222: sync-fix.patch -Patch223: use-last-screen.patch Patch224: pad-size-of-system-memory-copy-for-1x1-pixmaps Patch225: xorg-server-stop-cpu-eating.diff Patch226: record-avoid-crash-when-calling-RecordFlushReplyBuff.patch Patch227: Replace-malloc-with-calloc-to-initialize-the-buffers.patch Patch228: EXA-mixed-ModifyPixmapHeader-pitch-fixes.-bug-33929.patch -%if %moblin -Patch300: moblin-use_preferred_mode_for_all_outputs.diff -%endif %description This package contains the X.Org Server. @@ -187,17 +163,10 @@ An X Window System server for Virtual Network Computing (VNC). %prep %setup -q -n xorg-server-%{dirsuffix} -a4 -a7 -%patch1 %patch2 %patch6 -%patch8 -p0 -%patch13 -%patch14 +%patch13 -p1 %patch16 -p2 -%patch23 -%patch27 -%patch29 -%patch36 -p0 %if %vnc %patch39 -p1 %patch40 -p0 @@ -214,14 +183,11 @@ chmod 755 hw/vnc/symlink-vnc.sh %endif %patch45 -p0 pushd xorg-docs-* -%patch67 popd %patch77 %patch79 -p1 -%patch93 %patch101 -p1 %patch103 -%patch104 -p1 %patch106 -p1 %patch112 -p0 %patch123 -p0 @@ -233,37 +199,25 @@ pushd hw/xfree86/os-support/bus popd %patch143 -p0 %patch145 -p0 -%patch147 -p1 %patch162 -p1 %patch163 -p1 %patch164 -p1 -%patch168 -p1 -%patch169 -p1 %patch200 -p1 %patch202 -p1 %patch203 -p1 -%patch204 -p0 -%patch205 -p0 %patch206 -p0 -%patch207 -p0 %patch210 -p1 %patch211 -p1 %patch213 -p1 -%patch217 -p1 -%patch218 -p1 # Disable backtrace generation patch for now #%patch220 -p1 %patch221 -p1 %patch222 -p1 -%patch223 -p1 %patch224 -p1 %patch225 -p1 %patch226 -p1 %patch227 -p1 %patch228 -p1 -%if %moblin -%patch300 -p1 -%endif %build pushd xorg-docs-* @@ -285,6 +239,8 @@ autoreconf -fi --enable-kdrive \ --enable-kdrive-evdev \ --enable-xephyr \ + --disable-xfake \ + --disable-xfbdev \ --enable-record \ --enable-xcsecurity \ --with-sha1=libcrypto \ @@ -305,7 +261,12 @@ autoreconf -fi --with-os-vendor="SUSE LINUX" \ --with-fontrootdir="/usr/share/fonts" \ --with-xkb-path="/usr/share/X11/xkb" \ - --with-xkb-output="/var/lib/xkb/compiled" + --with-xkb-output="/var/lib/xkb/compiled" \ + --with-default-font-path="/usr/share/fonts/misc:unscaled,\ +/usr/share/fonts/Type1/,/usr/share/fonts/100dpi:unscaled,\ +/usr/share/fonts/75dpi:unscaled,/usr/share/fonts/URW/,\ +/usr/share/fonts/cyrillic:unscaled,\ +/usr/share/fonts/truetype/,built-ins" make %{?jobs:-j %jobs} make -C hw/kdrive %{?jobs:-j %jobs} @@ -324,6 +285,12 @@ chmod u-s $RPM_BUILD_ROOT/usr/bin/Xorg mkdir -p $RPM_BUILD_ROOT/var/lib/X11 ln -snf ../../../usr/bin/Xorg $RPM_BUILD_ROOT/var/lib/X11/X ln -snf ../../var/lib/X11/X $RPM_BUILD_ROOT/usr/bin/X +%if %suse_version > 1120 +%ifnarch s390 s390x +mkdir -p $RPM_BUILD_ROOT/etc/X11/xorg.conf.d +cp $RPM_BUILD_ROOT/%{_datadir}/X11/xorg.conf.d/10-evdev.conf $RPM_BUILD_ROOT/etc/X11/xorg.conf.d/ +%endif +%endif mkdir -p $RPM_BUILD_ROOT/usr/%{_lib}/xorg/modules/updates/{fonts,input,linux,drivers,multimedia,extensions} install -m 644 $RPM_SOURCE_DIR/README.updates $RPM_BUILD_ROOT/usr/%{_lib}/xorg/modules/updates mkdir -p $RPM_BUILD_ROOT/etc/modprobe.d @@ -394,6 +361,9 @@ exit 0 %ifnarch s390 s390x %if %suse_version > 1120 %dir /etc/X11/xorg.conf.d +%config(noreplace) /etc/X11/xorg.conf.d/10-evdev.conf +%dir %{_datadir}/X11/xorg.conf.d +%{_datadir}/X11/xorg.conf.d/10-evdev.conf %endif %dir /etc/modprobe.d %dir /var/lib/X11 @@ -403,15 +373,17 @@ exit 0 %dir /usr/%{_lib}/xorg /usr/%{_lib}/xorg/protocol.txt %{_mandir}/man1/* +%{_mandir}/man7/* +%doc %{_datadir}/doc/xorg-docs/ %exclude %{_mandir}/man1/Xdmx.1* %exclude %{_mandir}/man1/Xephyr.1* %exclude %{_mandir}/man1/Xnest.1* -%{_mandir}/man7/* +%exclude %{_mandir}/man7/Standards.7* +%exclude %{_mandir}/man7/Consortium.7* +%exclude %{_mandir}/man7/XProjectTeam.7* +%exclude %{_mandir}/man7/XOrgFoundation.7* /var/lib/xkb/compiled/README.compiled %ifnarch s390 s390x -%if %suse_version > 1120 -/etc/X11/xorg.conf.d/10-evdev.conf -%endif /etc/modprobe.d/50-nvidia.conf %verify(not mode) /usr/bin/Xorg /usr/bin/X diff --git a/xserver-1.6.1-nouveau.patch b/xserver-1.6.1-nouveau.patch deleted file mode 100644 index 154d9da..0000000 --- a/xserver-1.6.1-nouveau.patch +++ /dev/null @@ -1,67 +0,0 @@ -Also, don't treat DRI setup failure as an error for nouveau. ---- - -diff --git a/glx/glxdri.c b/glx/glxdri.c -index 21e44d1..30b820c 100644 ---- a/glx/glxdri.c -+++ b/glx/glxdri.c -@@ -968,6 +968,7 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - const __DRIconfig **driConfigs; - const __DRIextension **extensions; - int i; -+ int from = X_ERROR; - - if (!xf86LoaderCheckSymbol("DRIQueryDirectRenderingCapable") || - !DRIQueryDirectRenderingCapable(pScreen, &isCapable) || -@@ -1047,7 +1048,9 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - - screen->driver = dlopen(filename, RTLD_LAZY | RTLD_LOCAL); - if (screen->driver == NULL) { -- LogMessage(X_ERROR, "AIGLX error: dlopen of %s failed (%s)\n", -+ if (!strcmp(driverName, "nouveau")) -+ from = X_INFO; -+ LogMessage(from, "AIGLX error: dlopen of %s failed (%s)\n", - filename, dlerror()); - goto handle_error; - } -@@ -1184,7 +1187,7 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - - free(screen); - -- LogMessage(X_ERROR, "AIGLX: reverting to software rendering\n"); -+ LogMessage(from, "AIGLX: reverting to software rendering\n"); - - return NULL; - } -diff --git a/glx/glxdri2.c b/glx/glxdri2.c -index 0f998de..a244809 100644 ---- a/glx/glxdri2.c -+++ b/glx/glxdri2.c -@@ -676,6 +676,7 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - const __DRIextension **extensions; - const __DRIconfig **driConfigs; - int i; -+ int from = X_ERROR; - - screen = calloc(1, sizeof *screen); - if (screen == NULL) -@@ -702,7 +703,9 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - - screen->driver = dlopen(filename, RTLD_LAZY | RTLD_LOCAL); - if (screen->driver == NULL) { -- LogMessage(X_ERROR, "AIGLX error: dlopen of %s failed (%s)\n", -+ if (!strcmp(driverName, "nouveau")) -+ from = X_INFO; -+ LogMessage(from, "AIGLX error: dlopen of %s failed (%s)\n", - filename, dlerror()); - goto handle_error; - } -@@ -793,7 +796,7 @@ __glXDRIscreenProbe(ScreenPtr pScreen) - - free(screen); - -- LogMessage(X_ERROR, "AIGLX: reverting to software rendering\n"); -+ LogMessage(from, "AIGLX: reverting to software rendering\n"); - - return NULL; - } diff --git a/zap_warning_xserver.diff b/zap_warning_xserver.diff index 3c96b42..3093566 100644 --- a/zap_warning_xserver.diff +++ b/zap_warning_xserver.diff @@ -44,7 +44,7 @@ Index: xorg-server-1.6.3.901/hw/xfree86/common/xf86Config.c + gettimeofday(&NewZap, NULL); + + if ((NewZap.tv_sec - LastZap.tv_sec) >= 2) { -+ xf86OSRingBell(100, 1000, 500); ++ xf86OSRingBell(30, 1000, 50); + LastZap = NewZap; + break; + }