- fbdev-0.4.0-Make-ISA-optional.patch: to make next patch apply cleanly.

- fbdef-0.4.0-Remove-useless-loader-symbol-lists.patch: fix linker error
    against X server >= 1.6.99.1
This commit is contained in:
Peter Hutterer 2009-06-22 00:01:36 +00:00
parent 42b90b0226
commit c824b770cc
3 changed files with 253 additions and 1 deletions

View File

@ -0,0 +1,86 @@
From 092f0f10cb243ef011a38a92e4eb48d424de80fa Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com>
Date: Sun, 23 Nov 2008 20:04:30 -0500
Subject: [PATCH] Make ISA optional
---
configure.ac | 8 ++++++++
src/fbdev.c | 13 ++++++++-----
2 files changed, 16 insertions(+), 5 deletions(-)
diff --git a/configure.ac b/configure.ac
index ec3d7aa..7e82996 100644
--- a/configure.ac
+++ b/configure.ac
@@ -59,6 +59,14 @@ XORG_DRIVER_CHECK_EXT(XV, videoproto)
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
sdkdir=$(pkg-config --variable=sdkdir xorg-server)
+save_CFLAGS="$CFLAGS"
+CFLAGS="$XORG_CFLAGS"
+AC_CHECK_DECL(xf86ConfigIsaEntity,
+ [AC_DEFINE(HAVE_ISA, 1, [Have ISA support])],
+ [],
+ [#include "xf86.h"])
+CFLAGS="$save_CFLAGS"
+
AM_CONDITIONAL(PCIACCESS, [test "x$PCIACCESS" = xyes])
if test "x$PCIACCESS" = xyes; then
AC_DEFINE(PCIACCESS, 1, [Use libpciaccess])
diff --git a/src/fbdev.c b/src/fbdev.c
index df278f5..7f1a749 100644
--- a/src/fbdev.c
+++ b/src/fbdev.c
@@ -373,9 +373,7 @@ FBDevProbe(DriverPtr drv, int flags)
for (i = 0; i < numDevSections; i++) {
Bool isIsa = FALSE;
-#ifndef XSERVER_LIBPCIACCESS
Bool isPci = FALSE;
-#endif
dev = xf86FindOptionValue(devSections[i]->options,"fbdev");
if (devSections[i]->busID) {
@@ -387,14 +385,18 @@ FBDevProbe(DriverPtr drv, int flags)
isPci = TRUE;
} else
#endif
+#ifdef HAVE_ISA
if (xf86ParseIsaBusString(devSections[i]->busID))
isIsa = TRUE;
+ else
+#endif
+ 0;
}
if (fbdevHWProbe(NULL,dev,NULL)) {
pScrn = NULL;
-#ifndef XSERVER_LIBPCIACCESS
if (isPci) {
+#ifndef XSERVER_LIBPCIACCESS
/* XXX what about when there's no busID set? */
int entity;
@@ -410,9 +412,9 @@ FBDevProbe(DriverPtr drv, int flags)
xf86DrvMsg(pScrn->scrnIndex, X_CONFIG,
"claimed PCI slot %d:%d:%d\n",bus,device,func);
- } else
#endif
- if (isIsa) {
+ } else if (isIsa) {
+#ifdef HAVE_ISA
int entity;
entity = xf86ClaimIsaSlot(drv, 0,
@@ -420,6 +422,7 @@ FBDevProbe(DriverPtr drv, int flags)
pScrn = xf86ConfigIsaEntity(pScrn,0,entity,
NULL,RES_SHARED_VGA,
NULL,NULL,NULL,NULL);
+#endif
} else {
int entity;
--
1.6.3.rc1.2.g0164.dirty

View File

@ -0,0 +1,153 @@
From 16ea2bb46c9acc881f66a1f498d63586071aa9b7 Mon Sep 17 00:00:00 2001
From: Adam Jackson <ajax@redhat.com>
Date: Thu, 28 May 2009 14:55:08 -0400
Subject: [PATCH] Remove useless loader symbol lists.
---
src/fbdev.c | 74 -----------------------------------------------------------
1 files changed, 0 insertions(+), 74 deletions(-)
diff --git a/src/fbdev.c b/src/fbdev.c
index d37f149..9e66095 100644
--- a/src/fbdev.c
+++ b/src/fbdev.c
@@ -141,67 +141,6 @@ static const OptionInfoRec FBDevOptions[] = {
/* -------------------------------------------------------------------- */
-static const char *afbSymbols[] = {
- "afbScreenInit",
- "afbCreateDefColormap",
- NULL
-};
-
-static const char *fbSymbols[] = {
- "fbScreenInit",
- "fbPictureInit",
- NULL
-};
-
-static const char *shadowSymbols[] = {
- "shadowAdd",
- "shadowInit",
- "shadowSetup",
- "shadowUpdatePacked",
- "shadowUpdatePackedWeak",
- "shadowUpdateRotatePacked",
- "shadowUpdateRotatePackedWeak",
- NULL
-};
-
-static const char *fbdevHWSymbols[] = {
- "fbdevHWInit",
- "fbdevHWProbe",
- "fbdevHWSetVideoModes",
- "fbdevHWUseBuildinMode",
-
- "fbdevHWGetDepth",
- "fbdevHWGetLineLength",
- "fbdevHWGetName",
- "fbdevHWGetType",
- "fbdevHWGetVidmem",
- "fbdevHWLinearOffset",
- "fbdevHWLoadPalette",
- "fbdevHWMapVidmem",
- "fbdevHWUnmapVidmem",
-
- /* colormap */
- "fbdevHWLoadPalette",
- "fbdevHWLoadPaletteWeak",
-
- /* ScrnInfo hooks */
- "fbdevHWAdjustFrameWeak",
- "fbdevHWEnterVTWeak",
- "fbdevHWLeaveVTWeak",
- "fbdevHWModeInit",
- "fbdevHWRestore",
- "fbdevHWSave",
- "fbdevHWSaveScreen",
- "fbdevHWSaveScreenWeak",
- "fbdevHWSwitchModeWeak",
- "fbdevHWValidModeWeak",
-
- "fbdevHWDPMSSet",
- "fbdevHWDPMSSetWeak",
-
- NULL
-};
-
#ifdef XFree86LOADER
MODULESETUPPROTO(FBDevSetup);
@@ -230,8 +169,6 @@ FBDevSetup(pointer module, pointer opts, int *errmaj, int *errmin)
if (!setupDone) {
setupDone = TRUE;
xf86AddDriver(&FBDEV, module, HaveDriverFuncs);
- LoaderRefSymLists(afbSymbols, fbSymbols,
- shadowSymbols, fbdevHWSymbols, NULL);
return (pointer)1;
} else {
if (errmaj) *errmaj = LDR_ONCEONLY;
@@ -307,8 +244,6 @@ static Bool FBDevPciProbe(DriverPtr drv, int entity_num,
if (!xf86LoadDrvSubModule(drv, "fbdevhw"))
return FALSE;
- xf86LoaderReqSymLists(fbdevHWSymbols, NULL);
-
pScrn = xf86ConfigPciEntity(NULL, 0, entity_num, NULL, NULL,
NULL, NULL, NULL, NULL);
if (pScrn) {
@@ -369,8 +304,6 @@ FBDevProbe(DriverPtr drv, int flags)
if (!xf86LoadDrvSubModule(drv, "fbdevhw"))
return FALSE;
- xf86LoaderReqSymLists(fbdevHWSymbols, NULL);
-
for (i = 0; i < numDevSections; i++) {
Bool isIsa = FALSE;
Bool isPci = FALSE;
@@ -463,7 +396,6 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
FBDevPtr fPtr;
int default_depth, fbbpp;
const char *mod = NULL, *s;
- const char **syms = NULL;
int type;
if (flags & PROBE_DETECT) return FALSE;
@@ -620,7 +552,6 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
{
case FBDEVHW_PLANES:
mod = "afb";
- syms = afbSymbols;
break;
case FBDEVHW_PACKED_PIXELS:
switch (pScrn->bitsPerPixel)
@@ -630,7 +561,6 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
case 24:
case 32:
mod = "fb";
- syms = fbSymbols;
break;
default:
xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
@@ -666,9 +596,6 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
FBDevFreeRec(pScrn);
return FALSE;
}
- if (mod && syms) {
- xf86LoaderReqSymLists(syms, NULL);
- }
/* Load shadow if needed */
if (fPtr->shadowFB) {
@@ -678,7 +605,6 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
FBDevFreeRec(pScrn);
return FALSE;
}
- xf86LoaderReqSymLists(shadowSymbols, NULL);
}
TRACE_EXIT("PreInit");
--
1.6.3.rc1.2.g0164.dirty

View File

@ -5,7 +5,7 @@
Summary: Xorg X11 fbdev video driver
Name: xorg-x11-drv-fbdev
Version: 0.4.0
Release: 4%{?dist}
Release: 5%{?dist}
URL: http://www.x.org
License: MIT
Group: User Interface/X Hardware Support
@ -17,6 +17,12 @@ ExcludeArch: s390 s390x
Patch1: fbdev-0.3.0-32fbbpp.patch
Patch2: BGNoneRoot.patch
# Taken from upstream. This patch is only here because it allows
# fbdev-0.4.0-Remove-useless-loader-symbol-lists.patch to apply cleanly.
Patch3: fbdev-0.4.0-Make-ISA-optional.patch
# Taken from upstream
Patch4: fbdev-0.4.0-Remove-useless-loader-symbol-lists.patch
BuildRequires: xorg-x11-server-sdk >= 1.4.99.1
Requires: xorg-x11-server-Xorg >= 1.4.99.1
@ -30,6 +36,8 @@ X.Org X11 fbdev video driver.
# code looks like it'll have the same effect. XXX check with katzj.
# %patch1 -p1 -b .fbbpp
%patch2 -p1
%patch3 -p1
%patch4 -p1
%build
%configure --disable-static
@ -53,6 +61,11 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man4/fbdev.4*
%changelog
* Mon Jun 22 2009 Peter Hutterer <peter.hutterer@redhat.com> 0.4.0-5
- fbdev-0.4.0-Make-ISA-optional.patch: to make next patch apply cleanly.
- fbdef-0.4.0-Remove-useless-loader-symbol-lists.patch:
fix linker error against X server >= 1.6.99.1
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild