View | Details | Raw Unified | Return to bug 216289
Collapse All | Expand All

(-)x11-drivers/xf86-video-s3/Makefile (-1 / +1 lines)
Lines 2-8 Link Here
2
2
3
PORTNAME=	xf86-video-s3
3
PORTNAME=	xf86-video-s3
4
PORTVERSION=	0.6.5
4
PORTVERSION=	0.6.5
5
PORTREVISION=	6
5
PORTREVISION=	7
6
CATEGORIES=	x11-drivers
6
CATEGORIES=	x11-drivers
7
7
8
MAINTAINER=	x11@FreeBSD.org
8
MAINTAINER=	x11@FreeBSD.org
(-)x11-drivers/xf86-video-s3/files/patch-git_01_92d10d5 (+29 lines)
Line 0 Link Here
1
From 92d10d5d6882c3db6695a8fff83c88fbaaa27a33 Mon Sep 17 00:00:00 2001
2
From: "Eric S. Raymond" <esr@thyrsus.com>
3
Date: Thu, 23 Aug 2012 12:46:03 -0400
4
Subject: Fix malformed list syntax.
5
6
TP without a body shouldn't really be used for an item list. Fixing this
7
makes structural translation to DocBook possible.
8
9
Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
10
11
diff --git a/man/s3.man b/man/s3.man
12
index 9109c2a..732e4f3 100644
13
--- man/s3.man
14
+++ man/s3.man
15
@@ -50,9 +50,9 @@ driver supports PCI video cards based on the following S3 chips:
16
 
17
 .PP
18
 Also driver supports the following RAMDACs:
19
-.TP 12
20
+.IP 12
21
 .B IBM 524, IBM 524A, IBM 526, IBM 526DB
22
-.TP 12
23
+.IP 12
24
 .B TI ViewPoint 3025 
25
 
26
 .SH DESCRIPTION
27
-- 
28
cgit v0.10.2
29
(-)x11-drivers/xf86-video-s3/files/patch-git_02_ed0fbfd (+33 lines)
Line 0 Link Here
1
From ed0fbfd27609e897c42d7ab316481a9504746233 Mon Sep 17 00:00:00 2001
2
From: Gaetan Nadon <memsize@videotron.ca>
3
Date: Tue, 7 Jan 2014 16:28:58 -0500
4
Subject: Remove mibstore.h
5
6
As it was done in numerous other drivers. Fixes compile error.
7
8
Tested-by: Trevor Woerner <trevor.woerner@linaro.org>
9
Signed-off-by: Gaetan Nadon <memsize@videotron.ca>
10
11
diff --git a/src/s3_driver.c b/src/s3_driver.c
12
index 61242ad..85763ba 100644
13
--- src/s3_driver.c
14
+++ src/s3_driver.c
15
@@ -52,7 +52,6 @@
16
 #include "compiler.h"
17
 #include "mipointer.h"
18
 #include "micmap.h"
19
-#include "mibstore.h"
20
 #include "fb.h"
21
 #include "inputstr.h"
22
 #include "shadowfb.h"
23
@@ -822,7 +821,6 @@ static Bool S3ScreenInit(SCREEN_INIT_ARGS_DECL)
24
 	fbPictureInit (pScreen, 0, 0);
25
 	S3DGAInit(pScreen);
26
 
27
-        miInitializeBackingStore(pScreen);
28
         xf86SetBackingStore(pScreen);
29
 
30
 	/* framebuffer manager setup */
31
-- 
32
cgit v0.10.2
33
(-)x11-drivers/xf86-video-s3/files/patch-git_03_7b45358 (+35 lines)
Line 0 Link Here
1
From 7b454358082fc07985878fc92b902d7534144cae Mon Sep 17 00:00:00 2001
2
From: Alan Coopersmith <alan.coopersmith@oracle.com>
3
Date: Sat, 12 Mar 2016 10:54:22 -0800
4
Subject: When checking malloc for success, it helps to use == NULL, instead of
5
 =
6
7
Fixes gcc 5.3 compiler warning:
8
s3_bios.c: In function 'find_bios_string':
9
s3_bios.c:49:2: warning: suggest parentheses around assignment used as
10
    truth value [-Wparentheses]
11
  if (bios = NULL)
12
    ^
13
14
[Tested by compiling only, as I have no S3 hardware, but clearly no one
15
 else has tested this code since commit c41a1188ce53 in 2009, as it would
16
 be segfaulting if run.]
17
18
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
19
20
diff --git a/src/s3_bios.c b/src/s3_bios.c
21
index 323e2ce..1c7c5fe 100644
22
--- src/s3_bios.c
23
+++ src/s3_bios.c
24
@@ -46,7 +46,7 @@ static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
25
 	S3Ptr pS3 = S3PTR(pScrn);
26
 
27
 	bios = malloc(BIOS_BSIZE);
28
-	if (bios = NULL)
29
+	if (bios == NULL)
30
 		return NULL;
31
 
32
 	if (!init) {
33
-- 
34
cgit v0.10.2
35
(-)x11-drivers/xf86-video-s3/files/patch-git_04_82bd67a (+92 lines)
Line 0 Link Here
1
From 82bd67a255fb45847d8a10811641bc0b203ba864 Mon Sep 17 00:00:00 2001
2
From: Alan Coopersmith <alan.coopersmith@oracle.com>
3
Date: Thu, 17 Mar 2016 10:27:51 -0700
4
Subject: s3_bios.c: Simplify code for choosing between 16000 & 16000 for
5
 RefClock
6
7
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
8
9
diff --git a/src/s3_bios.c b/src/s3_bios.c
10
index 1c7c5fe..262d40a 100644
11
--- src/s3_bios.c
12
+++ src/s3_bios.c
13
@@ -29,75 +29,9 @@
14
 #include "config.h"
15
 #endif
16
 
17
-#include "xf86.h"
18
-#include "xf86_OSproc.h"
19
-#include "compiler.h"
20
-
21
 #include "s3.h"
22
 
23
-
24
-static unsigned char *find_bios_string(ScrnInfoPtr pScrn, int BIOSbase,
25
-				       char *match1, char *match2)
26
-{
27
-	static unsigned char *bios;
28
-	static int init=0;
29
-	int i, j, l1, l2, ret;
30
-
31
-	S3Ptr pS3 = S3PTR(pScrn);
32
-
33
-	bios = malloc(BIOS_BSIZE);
34
-	if (bios == NULL)
35
-		return NULL;
36
-
37
-	if (!init) {
38
-		init = 1;
39
-#ifndef XSERVER_LIBPCIACCESS
40
-		if (xf86ReadDomainMemory(pS3->PciTag, BIOSbase, BIOS_BSIZE, bios) != BIOS_BSIZE)
41
-			goto error;
42
-#else
43
-		ret = pci_device_read_rom(pS3->PciInfo, bios);
44
-		if (ret) {
45
-			xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
46
-				"libpciaccess failed to read video BIOS: %s\n",
47
-				strerror(-ret));
48
-		        goto error;
49
-		}
50
-#endif
51
-		if ((bios[0] != 0x55) || (bios[1] != 0xaa))
52
-			goto error;
53
-	}
54
-	if (match1 == NULL)
55
-		goto error;
56
-
57
-	l1 = strlen(match1);
58
-	if (match2 != NULL)
59
-		l2 = strlen(match2);
60
-	else
61
-		l2 = 0;
62
-
63
-	for (i=0; i<BIOS_BSIZE; i++)
64
-		if (bios[i] == match1[0] && !memcmp(&bios[i], match1, l1)) {
65
-			if (match2 == NULL)
66
-				return &bios[i+l1];
67
-			else
68
-				for(j=i+l1; (j<BIOS_BSIZE-l2) && bios[j]; j++)
69
-					if (bios[j] == match2[0] &&
70
-					    !memcmp(&bios[j], match2, l2))
71
-						return &bios[j+l2];
72
-		}
73
-error:
74
-	free(bios);
75
-	return NULL;
76
-}
77
-
78
-
79
 int S3GetRefClock(ScrnInfoPtr pScrn)
80
 {
81
-	int RefClock = 16000;	/* default */
82
-
83
-	if (find_bios_string(pScrn, BIOS_BASE, "Number Nine Visual Technology",
84
-					"Motion 771") != NULL)
85
-		RefClock = 16000;
86
-
87
-	return RefClock;
88
+	return 16000;
89
 }
90
-- 
91
cgit v0.10.2
92
(-)x11-drivers/xf86-video-s3/files/patch-src_s3__driver.c (-15 / +10 lines)
Lines 1-18 Link Here
1
# Correct a string that should be const
2
#
1
--- src/s3_driver.c.orig	2012-07-17 04:50:05 UTC
3
--- src/s3_driver.c.orig	2012-07-17 04:50:05 UTC
2
+++ src/s3_driver.c
4
+++ src/s3_driver.c
3
@@ -52,7 +52,6 @@
5
@@ -309,7 +308,7 @@ static Bool S3PreInit(ScrnInfoPtr pScrn,
4
 #include "compiler.h"
6
 	Gamma gzeros = {0.0, 0.0, 0.0};
5
 #include "mipointer.h"
7
 	int i, vgaCRIndex, vgaCRReg;
6
 #include "micmap.h"
8
 	unsigned char tmp;
7
-#include "mibstore.h"
9
-	char *s;
8
 #include "fb.h"
10
+	const char *s;
9
 #include "inputstr.h"
10
 #include "shadowfb.h"
11
@@ -822,7 +821,6 @@ static Bool S3ScreenInit(SCREEN_INIT_ARG
12
 	fbPictureInit (pScreen, 0, 0);
13
 	S3DGAInit(pScreen);
14
 
11
 
15
-        miInitializeBackingStore(pScreen);
12
         if (flags & PROBE_DETECT)
16
         xf86SetBackingStore(pScreen);
13
                 return FALSE;
17
 
18
 	/* framebuffer manager setup */

Return to bug 216289