alarm/xf86-video-armada to 430.e17e4d6-1

This makes sure that the driver builds with X.Org Server 1.20.
This commit is contained in:
Stefan Agner 2018-08-17 14:08:47 +00:00 committed by Kevin Mihelich
parent 80664580c0
commit f4350c4280
4 changed files with 151 additions and 33 deletions

View file

@ -0,0 +1,112 @@
From b04725198656129abd511ba4c98a57d823eb8620 Mon Sep 17 00:00:00 2001
From: Stefan Agner <stefan@agner.ch>
Date: Thu, 16 Aug 2018 16:26:30 +0000
Subject: [PATCH 1/2] Remove 24bbp support
24bbp support has been removed in X.Org Server 1.20 so
remove it from this driver as well.
Signed-off-by: Stefan Agner <stefan@agner.ch>
---
common/unaccel.c | 9 ---------
etnaviv/etnaviv.c | 26 --------------------------
vivante/vivante.c | 26 --------------------------
3 files changed, 61 deletions(-)
diff --git a/common/unaccel.c b/common/unaccel.c
index 15cc7d5..6a776ac 100644
--- a/common/unaccel.c
+++ b/common/unaccel.c
@@ -192,15 +192,6 @@ static void unaccel_fixup_tile(DrawablePtr pDraw, PixmapPtr *ppPix)
{
PixmapPtr pNew, pPixmap = *ppPix;
- if (pPixmap->drawable.bitsPerPixel != pDraw->bitsPerPixel) {
- prepare_cpu_drawable(&pPixmap->drawable, CPU_ACCESS_RO);
- pNew = fb24_32ReformatTile(pPixmap, pDraw->bitsPerPixel);
- finish_cpu_drawable(&pPixmap->drawable, CPU_ACCESS_RO);
-
- pDraw->pScreen->DestroyPixmap(pPixmap);
- *ppPix = pPixmap = pNew;
- }
-
if (FbEvenTile(pPixmap->drawable.width * pPixmap->drawable.bitsPerPixel)) {
prepare_cpu_drawable(&pPixmap->drawable, CPU_ACCESS_RW);
fbPadPixmap(pPixmap);
diff --git a/etnaviv/etnaviv.c b/etnaviv/etnaviv.c
index c7ec66b..c04477b 100644
--- a/etnaviv/etnaviv.c
+++ b/etnaviv/etnaviv.c
@@ -387,32 +387,6 @@ etnaviv_ValidateGC(GCPtr pGC, unsigned long changes, DrawablePtr pDrawable)
{
struct etnaviv *etnaviv = etnaviv_get_screen_priv(pDrawable->pScreen);
-#ifdef FB_24_32BIT
- if (changes & GCTile && fbGetRotatedPixmap(pGC)) {
- pGC->pScreen->DestroyPixmap(fbGetRotatedPixmap(pGC));
- fbGetRotatedPixmap(pGC) = NULL;
- }
- if (pGC->fillStyle == FillTiled) {
- PixmapPtr pOldTile = pGC->tile.pixmap;
- PixmapPtr pNewTile;
-
- if (pOldTile->drawable.bitsPerPixel != pDrawable->bitsPerPixel) {
- pNewTile = fbGetRotatedPixmap(pGC);
- if (!pNewTile || pNewTile->drawable.bitsPerPixel != pDrawable->bitsPerPixel) {
- if (pNewTile)
- pGC->pScreen->DestroyPixmap(pNewTile);
- prepare_cpu_drawable(&pOldTile->drawable, CPU_ACCESS_RO);
- pNewTile = fb24_32ReformatTile(pOldTile, pDrawable->bitsPerPixel);
- finish_cpu_drawable(&pOldTile->drawable, CPU_ACCESS_RO);
- }
- if (pNewTile) {
- fbGetRotatedPixmap(pGC) = pOldTile;
- pGC->tile.pixmap = pNewTile;
- changes |= GCTile;
- }
- }
- }
-#endif
if (changes & GCTile) {
if (!pGC->tileIsPixel &&
FbEvenTile(pGC->tile.pixmap->drawable.width *
diff --git a/vivante/vivante.c b/vivante/vivante.c
index 8e65c13..834bc30 100644
--- a/vivante/vivante.c
+++ b/vivante/vivante.c
@@ -253,32 +253,6 @@ static GCOps vivante_unaccel_GCOps = {
static void
vivante_ValidateGC(GCPtr pGC, unsigned long changes, DrawablePtr pDrawable)
{
-#ifdef FB_24_32BIT
- if (changes & GCTile && fbGetRotatedPixmap(pGC)) {
- pGC->pScreen->DestroyPixmap(fbGetRotatedPixmap(pGC));
- fbGetRotatedPixmap(pGC) = NULL;
- }
- if (pGC->fillStyle == FillTiled) {
- PixmapPtr pOldTile = pGC->tile.pixmap;
- PixmapPtr pNewTile;
-
- if (pOldTile->drawable.bitsPerPixel != pDrawable->bitsPerPixel) {
- pNewTile = fbGetRotatedPixmap(pGC);
- if (!pNewTile || pNewTile->drawable.bitsPerPixel != pDrawable->bitsPerPixel) {
- if (pNewTile)
- pGC->pScreen->DestroyPixmap(pNewTile);
- prepare_cpu_drawable(&pOldTile->drawable, CPU_ACCESS_RO);
- pNewTile = fb24_32ReformatTile(pOldTile, pDrawable->bitsPerPixel);
- finish_cpu_drawable(&pOldTile->drawable, CPU_ACCESS_RO);
- }
- if (pNewTile) {
- fbGetRotatedPixmap(pGC) = pOldTile;
- pGC->tile.pixmap = pNewTile;
- changes |= GCTile;
- }
- }
- }
-#endif
if (changes & GCTile) {
if (!pGC->tileIsPixel &&
FbEvenTile(pGC->tile.pixmap->drawable.width *
--
2.18.0

View file

@ -1,26 +0,0 @@
From fbc0cc200f1cc2b0fd8abc6de1dbd053d45f3321 Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Sun, 2 Apr 2017 01:10:04 -0600
Subject: [PATCH] fix drm_fourcc.h include path
Signed-off-by: Kevin Mihelich <kevin@archlinuxarm.org>
---
common/fourcc.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/fourcc.h b/common/fourcc.h
index efe2d62..74f5c6d 100644
--- a/common/fourcc.h
+++ b/common/fourcc.h
@@ -1,7 +1,7 @@
#ifndef COMMON_FOURCC_H
#define COMMON_FOURCC_H
-#include <drm/drm_fourcc.h>
+#include <drm_fourcc.h>
/* pick up on the Xorg fourcc.h. */
#include <fourcc.h>
--
2.12.0

View file

@ -0,0 +1,29 @@
From 41e1c3c0c1912e02528fca73fa21cf21abd012fb Mon Sep 17 00:00:00 2001
From: Stefan Agner <stefan@agner.ch>
Date: Thu, 16 Aug 2018 16:38:26 +0000
Subject: [PATCH 2/2] etnaviv: use different error code
The return code LDR_NOHARDWARE has been dropped in X.Org Server
1.20. Use LDR_MODSPECIFIC instead.
Signed-off-by: Stefan Agner <stefan@agner.ch>
---
etnaviv/etnadrm_module.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/etnaviv/etnadrm_module.c b/etnaviv/etnadrm_module.c
index 4307ff7..5e97cee 100644
--- a/etnaviv/etnadrm_module.c
+++ b/etnaviv/etnadrm_module.c
@@ -27,7 +27,7 @@ static pointer etnadrm_setup(pointer module, pointer opts, int *errmaj,
return (pointer) 1;
}
- *errmaj = LDR_NOHARDWARE;
+ *errmaj = LDR_MODSPECIFIC;
*errmin = 0;
return NULL;
--
2.18.0

View file

@ -4,23 +4,25 @@
buildarch=4
pkgname=xf86-video-armada
pkgver=402.04748ff
pkgrel=2
pkgver=430.e17e4d6
pkgrel=1
pkgdesc='X.org graphics driver for Marvell Armada DRM and Freescale i.MX'
arch=('armv7h')
url="http://git.arm.linux.org.uk/cgit/xf86-video-armada.git/"
license=('GPL2')
depends=('libdrm-armada')
makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=23' 'git' 'libdrm')
conflicts=('xorg-server<1.16' 'X-ABI-VIDEODRV_VERSION<23' 'X-ABI-VIDEODRV_VERSION>=24')
makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=24.0' 'git' 'libdrm')
conflicts=('xorg-server<1.16' 'X-ABI-VIDEODRV_VERSION<23')
options=('!libtool')
backup=('etc/X11/xorg.conf.d/99-armada.conf')
source=("$pkgname::git://git.arm.linux.org.uk/xf86-video-armada.git#branch=unstable-devel"
'git+https://github.com/laanwj/etna_viv.git'
'0001-fix-drm_fourcc.h-include-path.patch')
'0001-Remove-24bbp-support.patch'
'0002-etnaviv-use-different-error-code.patch')
md5sums=('SKIP'
'SKIP'
'7660a23a5204189f166e1b521eb584e7')
'450299ebce8ee54d2d02400c9e685155'
'15b1ef10e0ecda86f50af9249c0092ab')
pkgver() {
cd $pkgname
@ -29,7 +31,8 @@ pkgver() {
prepare() {
cd $pkgname
patch -p1 -i ../0001-fix-drm_fourcc.h-include-path.patch
patch -p1 -i ../0001-Remove-24bbp-support.patch
patch -p1 -i ../0002-etnaviv-use-different-error-code.patch
}
build() {