Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Feb 2017 01:40:29 +0000 (UTC)
From:      Johannes M Dieterich <jmd@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r433830 - in head/x11-drivers: . xf86-video-amdgpu xf86-video-amdgpu/files
Message-ID:  <201702110140.v1B1eTFh075472@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jmd
Date: Sat Feb 11 01:40:29 2017
New Revision: 433830
URL: https://svnweb.freebsd.org/changeset/ports/433830

Log:
  x11-drivers/xf86-video-amdgpu: Add the amdgpu driver for Xorg. Currently and temporarily requires FreeBSDDesktop kernel fork of 12-CURRENT.
  
  Reviewed by:	rene (mentor), swills (mentor), kwm (x11@)
  Approved by:	rene (mentor), swills (mentor)
  Differential Revision:	https://reviews.freebsd.org/D9377

Added:
  head/x11-drivers/xf86-video-amdgpu/
  head/x11-drivers/xf86-video-amdgpu/Makefile   (contents, props changed)
  head/x11-drivers/xf86-video-amdgpu/distinfo   (contents, props changed)
  head/x11-drivers/xf86-video-amdgpu/files/
  head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__drm__queue.c   (contents, props changed)
  head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__kms.c   (contents, props changed)
  head/x11-drivers/xf86-video-amdgpu/pkg-descr   (contents, props changed)
Modified:
  head/x11-drivers/Makefile

Modified: head/x11-drivers/Makefile
==============================================================================
--- head/x11-drivers/Makefile	Sat Feb 11 01:11:58 2017	(r433829)
+++ head/x11-drivers/Makefile	Sat Feb 11 01:40:29 2017	(r433830)
@@ -18,6 +18,7 @@
     SUBDIR += xf86-input-vmmouse
     SUBDIR += xf86-input-void
     SUBDIR += xf86-input-wacom
+    SUBDIR += xf86-video-amdgpu
     SUBDIR += xf86-video-apm
     SUBDIR += xf86-video-ark
     SUBDIR += xf86-video-ast

Added: head/x11-drivers/xf86-video-amdgpu/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-drivers/xf86-video-amdgpu/Makefile	Sat Feb 11 01:40:29 2017	(r433830)
@@ -0,0 +1,35 @@
+# $FreeBSD$
+
+# this port is for future amdgpu kernel support testing.
+
+PORTNAME=	xf86-video-amdgpu
+PORTVERSION=	1.2.0
+CATEGORIES=	x11-drivers
+
+MAINTAINER=	x11@FreeBSD.org
+COMMENT=	X.Org amdgpu display driver
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/COPYING
+
+LIB_DEPENDS=	libdrm_amdgpu.so:graphics/libdrm
+
+USE_GL=		gbm
+XORG_CAT=	driver
+INSTALL_TARGET=	install-strip
+# No amdgpu kernel driver on non-x86 and PC98.
+ONLY_FOR_ARCHS=	i386 amd64
+
+CONFIGURE_ARGS+=--disable-udev
+
+.include <bsd.port.options.mk>
+
+.if (${OSVERSION} < 1200019)
+IGNORE=		not support on 11.x or older, no kernel support
+.endif
+
+PLIST_FILES=	lib/xorg/modules/drivers/amdgpu_drv.so \
+		man/man4/amdgpu.4x.gz \
+		share/X11/xorg.conf.d/10-amdgpu.conf
+
+.include <bsd.port.mk>

Added: head/x11-drivers/xf86-video-amdgpu/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-drivers/xf86-video-amdgpu/distinfo	Sat Feb 11 01:40:29 2017	(r433830)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1479963082
+SHA256 (xorg/driver/xf86-video-amdgpu-1.2.0.tar.bz2) = 275b1aac5f127f55ba3d7480a1df89eace1d02650e24e46908067fc875e76c8f
+SIZE (xorg/driver/xf86-video-amdgpu-1.2.0.tar.bz2) = 388108

Added: head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__drm__queue.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__drm__queue.c	Sat Feb 11 01:40:29 2017	(r433830)
@@ -0,0 +1,47 @@
+--- src/amdgpu_drm_queue.c.orig	2016-09-20 08:19:15 UTC
++++ src/amdgpu_drm_queue.c
+@@ -61,7 +61,7 @@ amdgpu_drm_queue_handler(int fd, unsigne
+ 			 unsigned int usec, void *user_ptr)
+ {
+ 	uintptr_t seq = (uintptr_t)user_ptr;
+-	struct amdgpu_drm_queue_entry *e, *tmp;
++	struct amdgpu_drm_queue_entry *e = NULL, *tmp;
+ 
+ 	xorg_list_for_each_entry_safe(e, tmp, &amdgpu_drm_queue, list) {
+ 		if (e->seq == seq) {
+@@ -133,7 +133,7 @@ amdgpu_drm_abort_one(struct amdgpu_drm_q
+ void
+ amdgpu_drm_abort_client(ClientPtr client)
+ {
+-	struct amdgpu_drm_queue_entry *e;
++	struct amdgpu_drm_queue_entry *e = NULL;
+ 
+ 	xorg_list_for_each_entry(e, &amdgpu_drm_queue, list) {
+ 		if (e->client == client)
+@@ -147,7 +147,7 @@ amdgpu_drm_abort_client(ClientPtr client
+ void
+ amdgpu_drm_abort_entry(uintptr_t seq)
+ {
+-	struct amdgpu_drm_queue_entry *e, *tmp;
++	struct amdgpu_drm_queue_entry *e = NULL, *tmp;
+ 
+ 	xorg_list_for_each_entry_safe(e, tmp, &amdgpu_drm_queue, list) {
+ 		if (e->seq == seq) {
+@@ -163,7 +163,7 @@ amdgpu_drm_abort_entry(uintptr_t seq)
+ void
+ amdgpu_drm_abort_id(uint64_t id)
+ {
+-	struct amdgpu_drm_queue_entry *e, *tmp;
++	struct amdgpu_drm_queue_entry *e = NULL, *tmp;
+ 
+ 	xorg_list_for_each_entry_safe(e, tmp, &amdgpu_drm_queue, list) {
+ 		if (e->id == id) {
+@@ -191,7 +191,7 @@ amdgpu_drm_queue_init()
+ void
+ amdgpu_drm_queue_close(ScrnInfoPtr scrn)
+ {
+-	struct amdgpu_drm_queue_entry *e, *tmp;
++	struct amdgpu_drm_queue_entry *e = NULL, *tmp;
+ 
+ 	xorg_list_for_each_entry_safe(e, tmp, &amdgpu_drm_queue, list) {
+ 		if (e->crtc->scrn == scrn)

Added: head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__kms.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-drivers/xf86-video-amdgpu/files/patch-src_amdgpu__kms.c	Sat Feb 11 01:40:29 2017	(r433830)
@@ -0,0 +1,11 @@
+--- src/amdgpu_kms.c.orig	2016-11-17 06:07:48 UTC
++++ src/amdgpu_kms.c
+@@ -723,7 +723,7 @@ amdgpu_dirty_update(ScrnInfoPtr scrn)
+ {
+ 	AMDGPUInfoPtr info = AMDGPUPTR(scrn);
+ 	ScreenPtr screen = scrn->pScreen;
+-	PixmapDirtyUpdatePtr ent;
++	PixmapDirtyUpdatePtr ent = NULL;
+ 	RegionPtr region;
+ 
+ 	xorg_list_for_each_entry(ent, &screen->pixmap_dirty_list, ent) {

Added: head/x11-drivers/xf86-video-amdgpu/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-drivers/xf86-video-amdgpu/pkg-descr	Sat Feb 11 01:40:29 2017	(r433830)
@@ -0,0 +1,9 @@
+This package contains the X.Org xf86-video-amdgpu driver.
+
+The amdgpu driver supports AMD Radeon chipsets: OLAND, HAINAN, TAHITI, PITCAIRN,
+VERDE, BONAIRE, KABINI, MULLINS, KAVERI, HAWAII, TOPAZ, TONGA, CARRIZO, FIJI,
+STONEY, POLARIS11, POLARIS10 
+This driver relies on amdgpu KMS functionality currently only provided by the
+FreeBSDDesktop kernel fork. Once support is stable, it will be merged to HEAD.
+
+WWW: https://www.x.org/wiki/RadeonFeature/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201702110140.v1B1eTFh075472>