summarylogtreecommitdiffstats
path: root/xserver-autobind-hotplug.patch
diff options
context:
space:
mode:
authorkyak2018-05-17 19:55:17 +0300
committerkyak2018-05-17 19:55:17 +0300
commitdff38ca1121c23d5ee928a65e7e503f2d161ea9f (patch)
tree4f37a54418bda3ed381e0e752afae310e8ce719f /xserver-autobind-hotplug.patch
parentde729dd5a2b2936a37eec22349c34fc4907c1fcc (diff)
downloadaur-dff38ca1121c23d5ee928a65e7e503f2d161ea9f.tar.gz
upgpkg: xorg-server 1.20.0-2
Diffstat (limited to 'xserver-autobind-hotplug.patch')
-rw-r--r--xserver-autobind-hotplug.patch83
1 files changed, 37 insertions, 46 deletions
diff --git a/xserver-autobind-hotplug.patch b/xserver-autobind-hotplug.patch
index 8025cbd87be9..86b96a23e4bf 100644
--- a/xserver-autobind-hotplug.patch
+++ b/xserver-autobind-hotplug.patch
@@ -1,7 +1,7 @@
-From 4471df41ea6e94834a2b10643ca7fcd69682d276 Mon Sep 17 00:00:00 2001
+From 471289fa1dc359555ceed6302f7d9605ab6be3ea Mon Sep 17 00:00:00 2001
From: Dave Airlie <airlied@redhat.com>
-Date: Fri, 17 Aug 2012 09:49:24 +1000
-Subject: [PATCH xserver v3] autobind GPUs to the screen
+Date: Mon, 2 Apr 2018 16:49:02 -0400
+Subject: [PATCH] autobind GPUs to the screen
This is a modified version of a patch we've been carry-ing in Fedora and
RHEL for years now. This patch automatically adds secondary GPUs to the
@@ -35,15 +35,6 @@ Signed-off-by: Dave Airlie <airlied@gmail.com>
[hdegoede@redhat.com: Make configurable, fix with nvidia, submit upstream]
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
-Changes in v2:
--Make the default enabled instead of installing a xorg.conf
- snippet which enables it unconditionally
-Changes in v3:
--Handle GPUScreen autoconfig in randr/rrprovider.c, looking at
- rrScrPriv->provider, rather then in hw/xfree86/modes/xf86Crtc.c
- looking at xf86CrtcConfig->provider. This fixes the autoconfig not
- working with the nvidia binary driver
----
hw/xfree86/common/xf86Config.c | 19 +++++++++++++++++++
hw/xfree86/common/xf86Globals.c | 2 ++
hw/xfree86/common/xf86Init.c | 20 ++++++++++++++++++++
@@ -57,18 +48,18 @@ Changes in v3:
10 files changed, 85 insertions(+)
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
-index 21daf1a..df3ca50 100644
+index 2c1d335..d7d7c2e 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
-@@ -719,6 +719,7 @@ typedef enum {
+@@ -643,6 +643,7 @@ typedef enum {
FLAG_DRI2,
FLAG_USE_SIGIO,
FLAG_AUTO_ADD_GPU,
+ FLAG_AUTO_BIND_GPU,
FLAG_MAX_CLIENTS,
FLAG_IGLX,
- } FlagValues;
-@@ -778,6 +779,8 @@ static OptionInfoRec FlagOptions[] = {
+ FLAG_DEBUG,
+@@ -699,6 +700,8 @@ static OptionInfoRec FlagOptions[] = {
{0}, FALSE},
{FLAG_AUTO_ADD_GPU, "AutoAddGPU", OPTV_BOOLEAN,
{0}, FALSE},
@@ -77,7 +68,7 @@ index 21daf1a..df3ca50 100644
{FLAG_MAX_CLIENTS, "MaxClients", OPTV_INTEGER,
{0}, FALSE },
{FLAG_IGLX, "IndirectGLX", OPTV_BOOLEAN,
-@@ -857,6 +860,22 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
+@@ -779,6 +782,22 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
}
xf86Msg(from, "%sutomatically adding GPU devices\n",
xf86Info.autoAddGPU ? "A" : "Not a");
@@ -101,10 +92,10 @@ index 21daf1a..df3ca50 100644
* Set things up based on the config file information. Some of these
* settings may be overridden later when the command line options are
diff --git a/hw/xfree86/common/xf86Globals.c b/hw/xfree86/common/xf86Globals.c
-index e962b75..0d1e31b 100644
+index e890f05..7b27b4c 100644
--- a/hw/xfree86/common/xf86Globals.c
+++ b/hw/xfree86/common/xf86Globals.c
-@@ -136,6 +136,7 @@ xf86InfoRec xf86Info = {
+@@ -131,6 +131,7 @@ xf86InfoRec xf86Info = {
#else
.autoAddGPU = FALSE,
#endif
@@ -112,7 +103,7 @@ index e962b75..0d1e31b 100644
};
const char *xf86ConfigFile = NULL;
-@@ -197,6 +198,7 @@ Bool xf86FlipPixels = FALSE;
+@@ -191,6 +192,7 @@ Bool xf86FlipPixels = FALSE;
Gamma xf86Gamma = { 0.0, 0.0, 0.0 };
Bool xf86AllowMouseOpenFail = FALSE;
@@ -121,7 +112,7 @@ index e962b75..0d1e31b 100644
#ifdef XF86VIDMODE
Bool xf86VidModeDisabled = FALSE;
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
-index a544b65..b0cba3d 100644
+index ea42ec9..ec255b6 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -76,6 +76,7 @@
@@ -130,12 +121,13 @@ index a544b65..b0cba3d 100644
#include "xf86InPriv.h"
+#include "xf86Crtc.h"
#include "picturestr.h"
-
- #include "xf86Bus.h"
-@@ -298,6 +299,19 @@ xf86PrivsElevated(void)
+ #include "randrstr.h"
+ #include "glxvndabi.h"
+@@ -237,6 +238,19 @@ xf86PrivsElevated(void)
+ return PrivsElevated();
}
- static void
++static void
+xf86AutoConfigOutputDevices(void)
+{
+ int i;
@@ -148,11 +140,10 @@ index a544b65..b0cba3d 100644
+ xf86ScrnToScreen(xf86Screens[0]));
+}
+
-+static void
- InstallSignalHandlers(void)
+ static void
+ TrapSignals(void)
{
- /*
-@@ -871,6 +885,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
+@@ -770,6 +784,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
for (i = 0; i < xf86NumGPUScreens; i++)
AttachUnboundGPU(xf86Screens[0]->pScreen, xf86GPUScreens[i]->pScreen);
@@ -161,7 +152,7 @@ index a544b65..b0cba3d 100644
xf86VGAarbiterWrapFunctions();
if (sigio_blocked)
input_unlock();
-@@ -1389,6 +1405,10 @@ ddxProcessArgument(int argc, char **argv, int i)
+@@ -1278,6 +1294,10 @@ ddxProcessArgument(int argc, char **argv, int i)
xf86Info.iglxFrom = X_CMDLINE;
return 0;
}
@@ -173,7 +164,7 @@ index a544b65..b0cba3d 100644
/* OS-specific processing */
return xf86ProcessArgument(argc, argv, i);
diff --git a/hw/xfree86/common/xf86Priv.h b/hw/xfree86/common/xf86Priv.h
-index c1f8a18..9a3d0df 100644
+index 4fe2b5f..6566622 100644
--- a/hw/xfree86/common/xf86Priv.h
+++ b/hw/xfree86/common/xf86Priv.h
@@ -46,6 +46,7 @@
@@ -185,22 +176,22 @@ index c1f8a18..9a3d0df 100644
#ifdef XF86VIDMODE
extern _X_EXPORT Bool xf86VidModeDisabled;
diff --git a/hw/xfree86/common/xf86Privstr.h b/hw/xfree86/common/xf86Privstr.h
-index c29b3cc..4c5f54b 100644
+index 21c2e1f..6c71863 100644
--- a/hw/xfree86/common/xf86Privstr.h
+++ b/hw/xfree86/common/xf86Privstr.h
-@@ -102,6 +102,7 @@ typedef struct {
- MessageType dri2From;
+@@ -98,6 +98,7 @@ typedef struct {
Bool autoAddGPU;
+ const char *debug;
+ Bool autoBindGPU;
} xf86InfoRec, *xf86InfoPtr;
- #ifdef DPMSExtension
+ /* ISC's cc can't handle ~ of UL constants, so explicitly type cast them. */
diff --git a/hw/xfree86/common/xf86platformBus.c b/hw/xfree86/common/xf86platformBus.c
-index 063e81c..42789ca 100644
+index cef47da..913a324 100644
--- a/hw/xfree86/common/xf86platformBus.c
+++ b/hw/xfree86/common/xf86platformBus.c
-@@ -48,6 +48,7 @@
+@@ -49,6 +49,7 @@
#include "Pci.h"
#include "xf86platformBus.h"
#include "xf86Config.h"
@@ -208,7 +199,7 @@ index 063e81c..42789ca 100644
#include "randrstr.h"
int platformSlotClaimed;
-@@ -579,6 +580,9 @@ xf86platformAddDevice(int index)
+@@ -665,6 +666,9 @@ xf86platformAddDevice(int index)
}
/* attach unbound to 0 protocol screen */
AttachUnboundGPU(xf86Screens[0]->pScreen, xf86GPUScreens[i]->pScreen);
@@ -219,7 +210,7 @@ index 063e81c..42789ca 100644
RRResourcesChanged(xf86Screens[0]->pScreen);
RRTellChanged(xf86Screens[0]->pScreen);
diff --git a/hw/xfree86/man/Xorg.man b/hw/xfree86/man/Xorg.man
-index def9bfc..8df6b7d 100644
+index 13a9dc3..745f986 100644
--- a/hw/xfree86/man/Xorg.man
+++ b/hw/xfree86/man/Xorg.man
@@ -283,6 +283,13 @@ is a comma separated list of directories to search for
@@ -237,10 +228,10 @@ index def9bfc..8df6b7d 100644
Disable Silken Mouse support.
.TP 8
diff --git a/hw/xfree86/man/xorg.conf.man b/hw/xfree86/man/xorg.conf.man
-index 7d0c524..3e596e4 100644
+index 9589262..8d51e06 100644
--- a/hw/xfree86/man/xorg.conf.man
+++ b/hw/xfree86/man/xorg.conf.man
-@@ -673,6 +673,12 @@ Enabled by default.
+@@ -672,6 +672,12 @@ Enabled by default.
If this option is disabled, then no GPU devices will be added from the udev
backend. Enabled by default. (May need to be disabled to setup Xinerama).
.TP 7
@@ -254,10 +245,10 @@ index 7d0c524..3e596e4 100644
This option controls whether the log is flushed and/or synced to disk after
each message.
diff --git a/randr/randrstr.h b/randr/randrstr.h
-index 706e9a7..66999d5 100644
+index f94174b..092d726 100644
--- a/randr/randrstr.h
+++ b/randr/randrstr.h
-@@ -976,6 +976,9 @@ RRProviderLookup(XID id, RRProviderPtr *provider_p);
+@@ -1039,6 +1039,9 @@ RRProviderLookup(XID id, RRProviderPtr *provider_p);
extern _X_EXPORT void
RRDeliverProviderEvent(ClientPtr client, WindowPtr pWin, RRProviderPtr provider);
@@ -268,10 +259,10 @@ index 706e9a7..66999d5 100644
extern _X_EXPORT void
diff --git a/randr/rrprovider.c b/randr/rrprovider.c
-index f9df67e..abc5685 100644
+index e4bc2bf..e04c18f 100644
--- a/randr/rrprovider.c
+++ b/randr/rrprovider.c
-@@ -482,3 +482,25 @@ RRDeliverProviderEvent(ClientPtr client, WindowPtr pWin, RRProviderPtr provider)
+@@ -485,3 +485,25 @@ RRDeliverProviderEvent(ClientPtr client, WindowPtr pWin, RRProviderPtr provider)
WriteEventsToClient(client, 1, (xEvent *) &pe);
}
@@ -298,5 +289,5 @@ index f9df67e..abc5685 100644
+ pScrPriv->rrProviderSetOffloadSink(pScreen, provider, master_provider);
+}
--
-2.9.3
+2.16.2