Skip to contentSkip to conversation

Add 10-radeon.conf xorg.conf.d snippet

PATCH In review Michel Dänzer 2 participants 2 messages Jan 25, 2017 1 message not in the archive Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add 10-radeon.conf xorg.conf.d snippet

From: Michel Dänzer <[email protected]>

This instructs Xorg >= 1.16 to try loading the radeon driver for devices managed by the radeon kernel driver, even if the ati wrapper driver isn't available.

Copied from the amdgpu driver.

---
 Makefile.am         |  2 +-
 conf/10-radeon.conf |  5 +++++
 conf/Makefile.am    | 24 ++++++++++++++++++++++++
 configure.ac        | 16 ++++++++++++++++
 4 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 conf/10-radeon.conf
 create mode 100644 conf/Makefile.am
Makefile.am +1 -1
index f4f4233ed..f0e2c3cea 100644
@@ -18,7 +18,7 @@
 #  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 #  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
-SUBDIRS = src man
+SUBDIRS = src man conf
 MAINTAINERCLEANFILES = ChangeLog INSTALL
 
 .PHONY: ChangeLog INSTALL
conf/10-radeon.conf new file +5 -0
new file mode 100644
index 000000000..04217f674
@@ -0,0 +1,5 @@
+Section "OutputClass"
+	Identifier "Radeon"
+	MatchDriver "radeon"
+	Driver "radeon"
+EndSection
\ No newline at end of file
conf/Makefile.am new file +24 -0
new file mode 100644
index 000000000..fba75dac3
@@ -0,0 +1,24 @@
+#  Copyright 2017 Advanced Micro Devices, Inc.
+#
+#  Permission is hereby granted, free of charge, to any person obtaining a
+#  copy of this software and associated documentation files (the "Software"),
+#  to deal in the Software without restriction, including without limitation
+#  on the rights to use, copy, modify, merge, publish, distribute, sub
+#  license, and/or sell copies of the Software, and to permit persons to whom
+#  the Software is furnished to do so, subject to the following conditions:
+#
+#  The above copyright notice and this permission notice (including the next
+#  paragraph) shall be included in all copies or substantial portions of the
+#  Software.
+#
+#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
+#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+
+if HAS_XORG_CONF_DIR
+dist_config_DATA = 10-radeon.conf
+endif
configure.ac +16 -0
index 48281e3aa..732f7050a 100644
@@ -79,6 +79,20 @@ PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
                   HAVE_XEXTPROTO_71="no")
 AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
 
+# Section "OutputClass" is only supported as of xserver 1.16
+PKG_CHECK_EXISTS([xorg-server >= 1.16],
+		 [sysconfigdir=`$PKG_CONFIG --variable=sysconfigdir xorg-server`],
+		 [sysconfigdir=""])
+AM_CONDITIONAL(HAS_XORG_CONF_DIR, [test "x$sysconfigdir" != "x"])
+
+# Define a configure option for an alternate X Server configuration directory
+AC_ARG_WITH(xorg-conf-dir,
+            AS_HELP_STRING([--with-xorg-conf-dir=DIR],
+                           [Default xorg.conf.d directory [[default=${prefix}/share/X11/xorg.conf.d]]]),
+            [configdir="$withval"],
+            [configdir='${prefix}/share/X11/xorg.conf.d'])
+AC_SUBST(configdir)
+
 AC_ARG_ENABLE([udev],
 		AS_HELP_STRING([--disable-udev], [Disable libudev support [default=auto]]),
 		[enable_udev="$enableval"],
@@ -265,6 +279,7 @@ AC_CONFIG_FILES([
                 Makefile
                 src/Makefile
                 man/Makefile
+                conf/Makefile
 ])
 AC_OUTPUT
 
@@ -276,6 +291,7 @@ echo "        prefix:              $prefix"
 echo "        exec_prefix:         $exec_prefix"
 echo "        libdir:              $libdir"
 echo "        includedir:          $includedir"
+echo "        configdir:           $configdir"
 
 echo ""
 echo "        CFLAGS:              $CFLAGS"
Signature · 6 lines
2.11.0

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 20170125082311.28407-1-michel-otUistvHUpPR7s880joybQ@public.gmane.org

Reviewed-by
#2 lore raw
Quoted 9 lines · Michel Dänzer

From: Michel Dänzer <[email protected]>

This instructs Xorg >= 1.16 to try loading the radeon driver for devices managed by the radeon kernel driver, even if the ati wrapper driver isn't available.

Copied from the amdgpu driver.

Quoted 108 lines
---
 Makefile.am         |  2 +-
 conf/10-radeon.conf |  5 +++++
 conf/Makefile.am    | 24 ++++++++++++++++++++++++
 configure.ac        | 16 ++++++++++++++++
 4 files changed, 46 insertions(+), 1 deletion(-)
 create mode 100644 conf/10-radeon.conf
 create mode 100644 conf/Makefile.am
Makefile.am +1 -1
index f4f4233ed..f0e2c3cea 100644
@@ -18,7 +18,7 @@
 #  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 #  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
-SUBDIRS = src man
+SUBDIRS = src man conf
 MAINTAINERCLEANFILES = ChangeLog INSTALL
 
 .PHONY: ChangeLog INSTALL
conf/10-radeon.conf new file +5 -0
new file mode 100644
index 000000000..04217f674
@@ -0,0 +1,5 @@
+Section "OutputClass"
+       Identifier "Radeon"
+       MatchDriver "radeon"
+       Driver "radeon"
+EndSection
\ No newline at end of file
conf/Makefile.am new file +24 -0
new file mode 100644
index 000000000..fba75dac3
@@ -0,0 +1,24 @@
+#  Copyright 2017 Advanced Micro Devices, Inc.
+#
+#  Permission is hereby granted, free of charge, to any person obtaining a
+#  copy of this software and associated documentation files (the "Software"),
+#  to deal in the Software without restriction, including without limitation
+#  on the rights to use, copy, modify, merge, publish, distribute, sub
+#  license, and/or sell copies of the Software, and to permit persons to whom
+#  the Software is furnished to do so, subject to the following conditions:
+#
+#  The above copyright notice and this permission notice (including the next
+#  paragraph) shall be included in all copies or substantial portions of the
+#  Software.
+#
+#  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+#  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+#  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
+#  ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+#  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+#  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+
+if HAS_XORG_CONF_DIR
+dist_config_DATA = 10-radeon.conf
+endif
configure.ac +16 -1
index 48281e3aa..732f7050a 100644
@@ -79,6 +79,20 @@ PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
                   HAVE_XEXTPROTO_71="no")
 AM_CONDITIONAL(HAVE_XEXTPROTO_71, [ test "$HAVE_XEXTPROTO_71" = "yes" ])
 
+# Section "OutputClass" is only supported as of xserver 1.16
+PKG_CHECK_EXISTS([xorg-server >= 1.16],
+                [sysconfigdir=`$PKG_CONFIG --variable=sysconfigdir xorg-server`],
+                [sysconfigdir=""])
+AM_CONDITIONAL(HAS_XORG_CONF_DIR, [test "x$sysconfigdir" != "x"])
+
+# Define a configure option for an alternate X Server configuration directory
+AC_ARG_WITH(xorg-conf-dir,
+            AS_HELP_STRING([--with-xorg-conf-dir=DIR],
+                           [Default xorg.conf.d directory [[default=${prefix}/share/X11/xorg.conf.d]]]),
+            [configdir="$withval"],
+            [configdir='${prefix}/share/X11/xorg.conf.d'])
+AC_SUBST(configdir)
+
 AC_ARG_ENABLE([udev],
                AS_HELP_STRING([--disable-udev], [Disable libudev support [default=auto]]),
                [enable_udev="$enableval"],
@@ -265,6 +279,7 @@ AC_CONFIG_FILES([
                 Makefile
                 src/Makefile
                 man/Makefile
+                conf/Makefile
 ])
 AC_OUTPUT
 
@@ -276,6 +291,7 @@ echo "        prefix:              $prefix"
 echo "        exec_prefix:         $exec_prefix"
 echo "        libdir:              $libdir"
 echo "        includedir:          $includedir"
+echo "        configdir:           $configdir"
 
 echo ""
 echo "        CFLAGS:              $CFLAGS"
--

2.11.0

Quoted 4 lines

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx