[arch-commits] Commit in xf86-video-s3/repos (6 files)

Laurent Carlier lcarlier at archlinux.org
Mon Nov 21 14:22:43 UTC 2016


    Date: Monday, November 21, 2016 @ 14:22:42
  Author: lcarlier
Revision: 281746

archrelease: copy trunk to staging-i686, staging-x86_64

Added:
  xf86-video-s3/repos/staging-i686/
  xf86-video-s3/repos/staging-i686/PKGBUILD
    (from rev 281745, xf86-video-s3/trunk/PKGBUILD)
  xf86-video-s3/repos/staging-i686/git-fixes.patch
    (from rev 281745, xf86-video-s3/trunk/git-fixes.patch)
  xf86-video-s3/repos/staging-x86_64/
  xf86-video-s3/repos/staging-x86_64/PKGBUILD
    (from rev 281745, xf86-video-s3/trunk/PKGBUILD)
  xf86-video-s3/repos/staging-x86_64/git-fixes.patch
    (from rev 281745, xf86-video-s3/trunk/git-fixes.patch)

--------------------------------+
 staging-i686/PKGBUILD          |   35 ++++++
 staging-i686/git-fixes.patch   |  204 +++++++++++++++++++++++++++++++++++++++
 staging-x86_64/PKGBUILD        |   35 ++++++
 staging-x86_64/git-fixes.patch |  204 +++++++++++++++++++++++++++++++++++++++
 4 files changed, 478 insertions(+)

Copied: xf86-video-s3/repos/staging-i686/PKGBUILD (from rev 281745, xf86-video-s3/trunk/PKGBUILD)
===================================================================
--- staging-i686/PKGBUILD	                        (rev 0)
+++ staging-i686/PKGBUILD	2016-11-21 14:22:42 UTC (rev 281746)
@@ -0,0 +1,35 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+
+pkgname=xf86-video-s3
+pkgver=0.6.5
+pkgrel=8
+pkgdesc="X.org S3 video driver"
+arch=(i686 x86_64)
+url="https://xorg.freedesktop.org/"
+license=('custom')
+depends=('glibc')
+makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=23')
+conflicts=('xorg-server<1.19' 'X-ABI-VIDEODRV_VERSION<23' 'X-ABI-VIDEODRV_VERSION>=24')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2 git-fixes.patch)
+sha256sums=('4778cd4f1d61490c3562f9be03664576f065fa3acf22fe0d0689212d7ea3ad39'
+            'c8150b49c9d84f5a418d89fedc2b7eebf1066a046d9877a5ca21bc2868dc4765')
+
+prepare() {
+  cd ${pkgname}-${pkgver}
+  patch -Np1 -i ../git-fixes.patch
+}
+
+build() {
+  cd ${pkgname}-${pkgver}
+  ./configure --prefix=/usr
+  make
+}
+
+package() {
+  cd ${pkgname}-${pkgver}
+  make DESTDIR="${pkgdir}" install
+
+  install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+  install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}

Copied: xf86-video-s3/repos/staging-i686/git-fixes.patch (from rev 281745, xf86-video-s3/trunk/git-fixes.patch)
===================================================================
--- staging-i686/git-fixes.patch	                        (rev 0)
+++ staging-i686/git-fixes.patch	2016-11-21 14:22:42 UTC (rev 281746)
@@ -0,0 +1,204 @@
+From 92d10d5d6882c3db6695a8fff83c88fbaaa27a33 Mon Sep 17 00:00:00 2001
+From: "Eric S. Raymond" <esr at thyrsus.com>
+Date: Thu, 23 Aug 2012 12:46:03 -0400
+Subject: [PATCH 1/4] Fix malformed list syntax.
+
+TP without a body shouldn't really be used for an item list. Fixing this
+makes structural translation to DocBook possible.
+
+Signed-off-by: Eric S. Raymond <esr at thyrsus.com>
+---
+ man/s3.man | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/man/s3.man b/man/s3.man
+index 9109c2a..732e4f3 100644
+--- a/man/s3.man
++++ b/man/s3.man
+@@ -50,9 +50,9 @@ driver supports PCI video cards based on the following S3 chips:
+ 
+ .PP
+ Also driver supports the following RAMDACs:
+-.TP 12
++.IP 12
+ .B IBM 524, IBM 524A, IBM 526, IBM 526DB
+-.TP 12
++.IP 12
+ .B TI ViewPoint 3025 
+ 
+ .SH DESCRIPTION
+-- 
+2.10.2
+
+
+From ed0fbfd27609e897c42d7ab316481a9504746233 Mon Sep 17 00:00:00 2001
+From: Gaetan Nadon <memsize at videotron.ca>
+Date: Tue, 7 Jan 2014 16:28:58 -0500
+Subject: [PATCH 2/4] Remove mibstore.h
+
+As it was done in numerous other drivers. Fixes compile error.
+
+Tested-by: Trevor Woerner <trevor.woerner at linaro.org>
+Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
+---
+ src/s3_driver.c | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/src/s3_driver.c b/src/s3_driver.c
+index 61242ad..85763ba 100644
+--- a/src/s3_driver.c
++++ b/src/s3_driver.c
+@@ -52,7 +52,6 @@
+ #include "compiler.h"
+ #include "mipointer.h"
+ #include "micmap.h"
+-#include "mibstore.h"
+ #include "fb.h"
+ #include "inputstr.h"
+ #include "shadowfb.h"
+@@ -822,7 +821,6 @@ static Bool S3ScreenInit(SCREEN_INIT_ARGS_DECL)
+ 	fbPictureInit (pScreen, 0, 0);
+ 	S3DGAInit(pScreen);
+ 
+-        miInitializeBackingStore(pScreen);
+         xf86SetBackingStore(pScreen);
+ 
+ 	/* framebuffer manager setup */
+-- 
+2.10.2
+
+
+From 7b454358082fc07985878fc92b902d7534144cae Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <alan.coopersmith at oracle.com>
+Date: Sat, 12 Mar 2016 10:54:22 -0800
+Subject: [PATCH 3/4] When checking malloc for success, it helps to use ==
+ NULL, instead of =
+
+Fixes gcc 5.3 compiler warning:
+s3_bios.c: In function 'find_bios_string':
+s3_bios.c:49:2: warning: suggest parentheses around assignment used as
+    truth value [-Wparentheses]
+  if (bios = NULL)
+    ^
+
+[Tested by compiling only, as I have no S3 hardware, but clearly no one
+ else has tested this code since commit c41a1188ce53 in 2009, as it would
+ be segfaulting if run.]
+
+Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
+---
+ src/s3_bios.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/s3_bios.c b/src/s3_bios.c
+index 323e2ce..1c7c5fe 100644
+--- a/src/s3_bios.c
++++ b/src/s3_bios.c
+@@ -46,7 +46,7 @@ static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
+ 	S3Ptr pS3 = S3PTR(pScrn);
+ 
+ 	bios = malloc(BIOS_BSIZE);
+-	if (bios = NULL)
++	if (bios == NULL)
+ 		return NULL;
+ 
+ 	if (!init) {
+-- 
+2.10.2
+
+
+From 82bd67a255fb45847d8a10811641bc0b203ba864 Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <alan.coopersmith at oracle.com>
+Date: Thu, 17 Mar 2016 10:27:51 -0700
+Subject: [PATCH 4/4] s3_bios.c: Simplify code for choosing between 16000 &
+ 16000 for RefClock
+
+Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
+---
+ src/s3_bios.c | 68 +----------------------------------------------------------
+ 1 file changed, 1 insertion(+), 67 deletions(-)
+
+diff --git a/src/s3_bios.c b/src/s3_bios.c
+index 1c7c5fe..262d40a 100644
+--- a/src/s3_bios.c
++++ b/src/s3_bios.c
+@@ -29,75 +29,9 @@
+ #include "config.h"
+ #endif
+ 
+-#include "xf86.h"
+-#include "xf86_OSproc.h"
+-#include "compiler.h"
+-
+ #include "s3.h"
+ 
+-
+-static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
+-				       char *match1, char *match2)
+-{
+-	static unsigned char *bios;
+-	static int init=0;
+-	int i, j, l1, l2, ret;
+-
+-	S3Ptr pS3 = S3PTR(pScrn);
+-
+-	bios = malloc(BIOS_BSIZE);
+-	if (bios == NULL)
+-		return NULL;
+-
+-	if (!init) {
+-		init = 1;
+-#ifndef XSERVER_LIBPCIACCESS
+-		if (xf86ReadDomainMemory(pS3->PciTag, BIOSbase, BIOS_BSIZE, bios) != BIOS_BSIZE)
+-			goto error;
+-#else
+-		ret = pci_device_read_rom(pS3->PciInfo, bios);
+-		if (ret) {
+-			xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+-				"libpciaccess failed to read video BIOS: %s\n",
+-				strerror(-ret));
+-		        goto error;
+-		}
+-#endif
+-		if ((bios[0] != 0x55) || (bios[1] != 0xaa))
+-			goto error;
+-	}
+-	if (match1 == NULL)
+-		goto error;
+-
+-	l1 = strlen(match1);
+-	if (match2 != NULL)
+-		l2 = strlen(match2);
+-	else
+-		l2 = 0;
+-
+-	for (i=0; i<BIOS_BSIZE; i++)
+-		if (bios[i] == match1[0] && !memcmp(&bios[i], match1, l1)) {
+-			if (match2 == NULL)
+-				return &bios[i+l1];
+-			else
+-				for(j=i+l1; (j<BIOS_BSIZE-l2) && bios[j]; j++)
+-					if (bios[j] == match2[0] &&
+-					    !memcmp(&bios[j], match2, l2))
+-						return &bios[j+l2];
+-		}
+-error:
+-	free(bios);
+-	return NULL;
+-}
+-
+-
+ int S3GetRefClock(ScrnInfoPtr pScrn)
+ {
+-	int RefClock = 16000;	/* default */
+-
+-	if (find_bios_string(pScrn, BIOS_BASE, "Number Nine Visual Technology",
+-					"Motion 771") != NULL)
+-		RefClock = 16000;
+-
+-	return RefClock;
++	return 16000;
+ }
+-- 
+2.10.2
+

Copied: xf86-video-s3/repos/staging-x86_64/PKGBUILD (from rev 281745, xf86-video-s3/trunk/PKGBUILD)
===================================================================
--- staging-x86_64/PKGBUILD	                        (rev 0)
+++ staging-x86_64/PKGBUILD	2016-11-21 14:22:42 UTC (rev 281746)
@@ -0,0 +1,35 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+
+pkgname=xf86-video-s3
+pkgver=0.6.5
+pkgrel=8
+pkgdesc="X.org S3 video driver"
+arch=(i686 x86_64)
+url="https://xorg.freedesktop.org/"
+license=('custom')
+depends=('glibc')
+makedepends=('xorg-server-devel' 'X-ABI-VIDEODRV_VERSION=23')
+conflicts=('xorg-server<1.19' 'X-ABI-VIDEODRV_VERSION<23' 'X-ABI-VIDEODRV_VERSION>=24')
+source=(${url}/releases/individual/driver/${pkgname}-${pkgver}.tar.bz2 git-fixes.patch)
+sha256sums=('4778cd4f1d61490c3562f9be03664576f065fa3acf22fe0d0689212d7ea3ad39'
+            'c8150b49c9d84f5a418d89fedc2b7eebf1066a046d9877a5ca21bc2868dc4765')
+
+prepare() {
+  cd ${pkgname}-${pkgver}
+  patch -Np1 -i ../git-fixes.patch
+}
+
+build() {
+  cd ${pkgname}-${pkgver}
+  ./configure --prefix=/usr
+  make
+}
+
+package() {
+  cd ${pkgname}-${pkgver}
+  make DESTDIR="${pkgdir}" install
+
+  install -m755 -d "${pkgdir}/usr/share/licenses/${pkgname}"
+  install -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/"
+}

Copied: xf86-video-s3/repos/staging-x86_64/git-fixes.patch (from rev 281745, xf86-video-s3/trunk/git-fixes.patch)
===================================================================
--- staging-x86_64/git-fixes.patch	                        (rev 0)
+++ staging-x86_64/git-fixes.patch	2016-11-21 14:22:42 UTC (rev 281746)
@@ -0,0 +1,204 @@
+From 92d10d5d6882c3db6695a8fff83c88fbaaa27a33 Mon Sep 17 00:00:00 2001
+From: "Eric S. Raymond" <esr at thyrsus.com>
+Date: Thu, 23 Aug 2012 12:46:03 -0400
+Subject: [PATCH 1/4] Fix malformed list syntax.
+
+TP without a body shouldn't really be used for an item list. Fixing this
+makes structural translation to DocBook possible.
+
+Signed-off-by: Eric S. Raymond <esr at thyrsus.com>
+---
+ man/s3.man | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/man/s3.man b/man/s3.man
+index 9109c2a..732e4f3 100644
+--- a/man/s3.man
++++ b/man/s3.man
+@@ -50,9 +50,9 @@ driver supports PCI video cards based on the following S3 chips:
+ 
+ .PP
+ Also driver supports the following RAMDACs:
+-.TP 12
++.IP 12
+ .B IBM 524, IBM 524A, IBM 526, IBM 526DB
+-.TP 12
++.IP 12
+ .B TI ViewPoint 3025 
+ 
+ .SH DESCRIPTION
+-- 
+2.10.2
+
+
+From ed0fbfd27609e897c42d7ab316481a9504746233 Mon Sep 17 00:00:00 2001
+From: Gaetan Nadon <memsize at videotron.ca>
+Date: Tue, 7 Jan 2014 16:28:58 -0500
+Subject: [PATCH 2/4] Remove mibstore.h
+
+As it was done in numerous other drivers. Fixes compile error.
+
+Tested-by: Trevor Woerner <trevor.woerner at linaro.org>
+Signed-off-by: Gaetan Nadon <memsize at videotron.ca>
+---
+ src/s3_driver.c | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/src/s3_driver.c b/src/s3_driver.c
+index 61242ad..85763ba 100644
+--- a/src/s3_driver.c
++++ b/src/s3_driver.c
+@@ -52,7 +52,6 @@
+ #include "compiler.h"
+ #include "mipointer.h"
+ #include "micmap.h"
+-#include "mibstore.h"
+ #include "fb.h"
+ #include "inputstr.h"
+ #include "shadowfb.h"
+@@ -822,7 +821,6 @@ static Bool S3ScreenInit(SCREEN_INIT_ARGS_DECL)
+ 	fbPictureInit (pScreen, 0, 0);
+ 	S3DGAInit(pScreen);
+ 
+-        miInitializeBackingStore(pScreen);
+         xf86SetBackingStore(pScreen);
+ 
+ 	/* framebuffer manager setup */
+-- 
+2.10.2
+
+
+From 7b454358082fc07985878fc92b902d7534144cae Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <alan.coopersmith at oracle.com>
+Date: Sat, 12 Mar 2016 10:54:22 -0800
+Subject: [PATCH 3/4] When checking malloc for success, it helps to use ==
+ NULL, instead of =
+
+Fixes gcc 5.3 compiler warning:
+s3_bios.c: In function 'find_bios_string':
+s3_bios.c:49:2: warning: suggest parentheses around assignment used as
+    truth value [-Wparentheses]
+  if (bios = NULL)
+    ^
+
+[Tested by compiling only, as I have no S3 hardware, but clearly no one
+ else has tested this code since commit c41a1188ce53 in 2009, as it would
+ be segfaulting if run.]
+
+Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
+---
+ src/s3_bios.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/s3_bios.c b/src/s3_bios.c
+index 323e2ce..1c7c5fe 100644
+--- a/src/s3_bios.c
++++ b/src/s3_bios.c
+@@ -46,7 +46,7 @@ static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
+ 	S3Ptr pS3 = S3PTR(pScrn);
+ 
+ 	bios = malloc(BIOS_BSIZE);
+-	if (bios = NULL)
++	if (bios == NULL)
+ 		return NULL;
+ 
+ 	if (!init) {
+-- 
+2.10.2
+
+
+From 82bd67a255fb45847d8a10811641bc0b203ba864 Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <alan.coopersmith at oracle.com>
+Date: Thu, 17 Mar 2016 10:27:51 -0700
+Subject: [PATCH 4/4] s3_bios.c: Simplify code for choosing between 16000 &
+ 16000 for RefClock
+
+Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
+---
+ src/s3_bios.c | 68 +----------------------------------------------------------
+ 1 file changed, 1 insertion(+), 67 deletions(-)
+
+diff --git a/src/s3_bios.c b/src/s3_bios.c
+index 1c7c5fe..262d40a 100644
+--- a/src/s3_bios.c
++++ b/src/s3_bios.c
+@@ -29,75 +29,9 @@
+ #include "config.h"
+ #endif
+ 
+-#include "xf86.h"
+-#include "xf86_OSproc.h"
+-#include "compiler.h"
+-
+ #include "s3.h"
+ 
+-
+-static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
+-				       char *match1, char *match2)
+-{
+-	static unsigned char *bios;
+-	static int init=0;
+-	int i, j, l1, l2, ret;
+-
+-	S3Ptr pS3 = S3PTR(pScrn);
+-
+-	bios = malloc(BIOS_BSIZE);
+-	if (bios == NULL)
+-		return NULL;
+-
+-	if (!init) {
+-		init = 1;
+-#ifndef XSERVER_LIBPCIACCESS
+-		if (xf86ReadDomainMemory(pS3->PciTag, BIOSbase, BIOS_BSIZE, bios) != BIOS_BSIZE)
+-			goto error;
+-#else
+-		ret = pci_device_read_rom(pS3->PciInfo, bios);
+-		if (ret) {
+-			xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
+-				"libpciaccess failed to read video BIOS: %s\n",
+-				strerror(-ret));
+-		        goto error;
+-		}
+-#endif
+-		if ((bios[0] != 0x55) || (bios[1] != 0xaa))
+-			goto error;
+-	}
+-	if (match1 == NULL)
+-		goto error;
+-
+-	l1 = strlen(match1);
+-	if (match2 != NULL)
+-		l2 = strlen(match2);
+-	else
+-		l2 = 0;
+-
+-	for (i=0; i<BIOS_BSIZE; i++)
+-		if (bios[i] == match1[0] && !memcmp(&bios[i], match1, l1)) {
+-			if (match2 == NULL)
+-				return &bios[i+l1];
+-			else
+-				for(j=i+l1; (j<BIOS_BSIZE-l2) && bios[j]; j++)
+-					if (bios[j] == match2[0] &&
+-					    !memcmp(&bios[j], match2, l2))
+-						return &bios[j+l2];
+-		}
+-error:
+-	free(bios);
+-	return NULL;
+-}
+-
+-
+ int S3GetRefClock(ScrnInfoPtr pScrn)
+ {
+-	int RefClock = 16000;	/* default */
+-
+-	if (find_bios_string(pScrn, BIOS_BASE, "Number Nine Visual Technology",
+-					"Motion 771") != NULL)
+-		RefClock = 16000;
+-
+-	return RefClock;
++	return 16000;
+ }
+-- 
+2.10.2
+



More information about the arch-commits mailing list