1
0
OBS User unknown 2006-12-19 16:31:36 +00:00 committed by Git OBS Bridge
parent 45427d893c
commit 1a507912f5
5 changed files with 72 additions and 111 deletions

40
int10-fix.diff Normal file
View File

@ -0,0 +1,40 @@
From: Alan Hourihane <alanh@fairlite.demon.co.uk>
Date: Wed, 13 Dec 2006 12:13:11 +0000 (+0000)
Subject: Set Int10Current->Tag for the linux native int10 module
X-Git-Url: http://gitweb.freedesktop.org/?p=xorg/xserver.git;a=commitdiff;h=b88ad820fac81d0dfd557a384bf0406e8893e7af
Set Int10Current->Tag for the linux native int10 module
Fixes bug #9296
(cherry picked from 731952c561a3972d09d1315f4fd31466e459ccb9 commit)
---
--- a/hw/xfree86/int10/generic.c
+++ b/hw/xfree86/int10/generic.c
@@ -98,7 +98,7 @@ xf86ExtendedInitInt10(int entityIndex, i
base = INTPriv(pInt)->base = xnfalloc(SYS_BIOS);
pvp = xf86GetPciInfoForEntity(entityIndex);
- if (pvp) pInt->Tag = ((pciConfigPtr)(pvp->thisCard))->tag;
+ if (pvp) pInt->Tag = pciTag(pvp->bus, pvp->device, pvp->func);
/*
* we need to map video RAM MMIO as some chipsets map mmio
--- a/hw/xfree86/os-support/linux/int10/linux.c
+++ b/hw/xfree86/os-support/linux/int10/linux.c
@@ -90,6 +90,7 @@ xf86ExtendedInitInt10(int entityIndex, i
legacyVGARec vga;
xf86int10BiosLocation bios;
Bool videoBiosMapped = FALSE;
+ pciVideoPtr pvp;
if (int10Generation != serverGeneration) {
counter = 0;
@@ -151,6 +152,8 @@ xf86ExtendedInitInt10(int entityIndex, i
pInt = (xf86Int10InfoPtr)xnfcalloc(1, sizeof(xf86Int10InfoRec));
pInt->scrnIndex = screen;
pInt->entityIndex = entityIndex;
+ pvp = xf86GetPciInfoForEntity(entityIndex);
+ if (pvp) pInt->Tag = pciTag(pvp->bus, pvp->device, pvp->func);
if (!xf86Int10ExecSetup(pInt))
goto error0;
pInt->mem = &linuxMem;

View File

@ -1,19 +0,0 @@
Index: linux.c
===================================================================
RCS file: /work/cvsdir/cvs/xc/programs/Xserver/hw/xfree86/os-support/linux/int10/linux.c,v
retrieving revision 1.1.1.30
diff -u -r1.1.1.30 linux.c
--- linux.c 13 Sep 2005 10:31:31 -0000 1.1.1.30
+++ linux.c 27 Jun 2006 14:25:58 -0000
@@ -158,6 +158,11 @@
pInt = (xf86Int10InfoPtr)xnfcalloc(1, sizeof(xf86Int10InfoRec));
pInt->scrnIndex = screen;
pInt->entityIndex = entityIndex;
+ {
+ pciVideoPtr pvp = xf86GetPciInfoForEntity(entityIndex);
+ if (pvp) pInt->Tag = ((pciConfigPtr)(pvp->thisCard))->tag;
+ }
+
if (!xf86Int10ExecSetup(pInt))
goto error0;
pInt->mem = &linuxMem;

View File

@ -1,89 +1,11 @@
--- hw/xfree86/os-support/bus/linuxPci.c --- hw/xfree86/os-support/bus/linuxPci.c.orig 2006-11-20 22:04:35.000000000 +0100
+++ hw/xfree86/os-support/bus/linuxPci.c +++ hw/xfree86/os-support/bus/linuxPci.c 2006-11-20 22:06:08.000000000 +0100
@@ -550,15 +550,15 @@ @@ -547,7 +547,7 @@
return result; pPCI = xf86GetPciHostConfigFromTag(Tag);
if (pPCI && (result = PCI_DOM_FROM_BUS(pPCI->busnum)))
- return result;
+ return result + 1;
if (!pPCI || pPCI->fakeDevice) if (!pPCI || pPCI->fakeDevice)
- return 1; /* Domain 0 is reserved */ return 1; /* Domain 0 is reserved */
+ return 0;
if ((fd = linuxPciOpenFile(pPCI ? pPCI->tag : 0,FALSE)) < 0)
- return 0;
+ return -1;
if ((result = ioctl(fd, PCIIOC_CONTROLLER, 0)) < 0)
- return 0;
+ return -1;
- return result + 1; /* Domain 0 is reserved */
+ return result;
}
static pointer
@@ -628,7 +628,7 @@
return NULL;
}
-#define MAX_DOMAINS 257
+#define MAX_DOMAINS 256
static pointer DomainMmappedIO[MAX_DOMAINS];
static int
@@ -649,11 +649,10 @@
domain = xf86GetPciDomain(Tag);
bus = PCI_BUS_NO_DOMAIN(PCI_BUS_FROM_TAG(Tag));
- /* Domain 0 is reserved -- see xf86GetPciDomain() */
- if ((domain <= 0) || (domain >= MAX_DOMAINS))
+ if ((domain < 0) || (domain >= MAX_DOMAINS))
FatalError("linuxOpenLegacy(): domain out of range\n");
- sprintf(path, PREFIX, domain - 1, bus, name);
+ sprintf(path, PREFIX, domain, bus, name);
fd = open(path, O_RDWR);
if (fd >= 0) {
xfree(path);
@@ -685,7 +684,6 @@
xf86MapDomainMemory(int ScreenNum, int Flags, PCITAG Tag,
ADDRESS Base, unsigned long Size)
{
- int domain = xf86GetPciDomain(Tag);
int fd;
pointer addr;
@@ -733,7 +731,7 @@
int domain = xf86GetPciDomain(Tag);
int fd;
- if ((domain <= 0) || (domain >= MAX_DOMAINS))
+ if ((domain < 0) || (domain >= MAX_DOMAINS))
FatalError("xf86MapDomainIO(): domain out of range\n");
if (DomainMmappedIO[domain])
@@ -847,7 +845,7 @@
RANGE_TYPE(ResExcIoBlock, domain));
pRes = xf86AddResToList(pRes, &range, -1);
- if (domain <= 0)
+ if (domain < 0)
break;
}
}
@@ -881,7 +879,7 @@
RANGE_TYPE(ResExcIoBlock, domain));
pRes = xf86AddResToList(pRes, &range, -1);
- if (domain <= 0)
+ if (domain < 0)
break;
}
}
@@ -933,7 +931,7 @@
RANGE_TYPE(ResExcIoBlock, domain));
pRes = xf86AddResToList(pRes, &range, -1);
- if (domain <= 0)
+ if (domain < 0)
break;
}
}

View File

@ -1,3 +1,16 @@
-------------------------------------------------------------------
Tue Dec 19 15:11:17 CET 2006 - sndirsch@suse.de
- int10-fix.diff
* Set Int10Current->Tag for the linux native int10 module (X.Org
Bug #9296)
* obsoletes p_initialize-pci-tag.diff
-------------------------------------------------------------------
Tue Dec 19 14:40:20 CET 2006 - sndirsch@suse.de
- reverted latest change by schwab (Bug #197190, comment #67)
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Dec 18 17:08:00 CET 2006 - schwab@suse.de Mon Dec 18 17:08:00 CET 2006 - schwab@suse.de

View File

@ -17,7 +17,7 @@ BuildRequires: Mesa-devel fontconfig-devel freetype2-devel ghostscript-library
URL: http://xorg.freedesktop.org/ URL: http://xorg.freedesktop.org/
%define EXPERIMENTAL 0 %define EXPERIMENTAL 0
Version: 7.2 Version: 7.2
Release: 32 Release: 33
License: X11/MIT License: X11/MIT
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
Group: System/X11/Servers/XF86_4 Group: System/X11/Servers/XF86_4
@ -52,7 +52,6 @@ Patch13: p_xorg_acpi.diff
Patch14: p_xkills_wrong_client.diff Patch14: p_xkills_wrong_client.diff
Patch15: p_bug159532.diff Patch15: p_bug159532.diff
Patch16: p_xnest-ignore-getimage-errors.diff Patch16: p_xnest-ignore-getimage-errors.diff
Patch17: p_initialize-pci-tag.diff
Patch18: p_ia64-console.diff Patch18: p_ia64-console.diff
Patch19: disable-aiglx.diff Patch19: disable-aiglx.diff
Patch22: disable-root-xorg_conf.diff Patch22: disable-root-xorg_conf.diff
@ -69,6 +68,7 @@ Patch33: p_pci-off-by-one.diff
Patch34: Mesa-6.5.2.diff Patch34: Mesa-6.5.2.diff
Patch35: xorg-server-1.1.99.901-GetDrawableAttributes.patch Patch35: xorg-server-1.1.99.901-GetDrawableAttributes.patch
Patch36: libdrm.diff Patch36: libdrm.diff
Patch37: int10-fix.diff
Patch334: p_pci-domain.diff Patch334: p_pci-domain.diff
Patch357: p_pci-ce-x.diff Patch357: p_pci-ce-x.diff
@ -114,9 +114,6 @@ sed 's/LIBDIR/%{_lib}/g' %{PATCH2} | patch -p0
%patch14 -p2 %patch14 -p2
%patch15 -p2 %patch15 -p2
%patch16 -p2 %patch16 -p2
pushd hw/xfree86/os-support/linux/int10
%patch17
popd
pushd hw/xfree86/os-support pushd hw/xfree86/os-support
%patch18 %patch18
popd popd
@ -140,6 +137,7 @@ popd
%patch34 -p0 %patch34 -p0
%patch35 -p1 %patch35 -p1
%patch36 -p0 %patch36 -p0
%patch37 -p1
%build %build
autoreconf -fi autoreconf -fi
@ -444,6 +442,13 @@ exit 0
%endif %endif
%changelog -n xorg-x11-server %changelog -n xorg-x11-server
* Tue Dec 19 2006 - sndirsch@suse.de
- int10-fix.diff
* Set Int10Current->Tag for the linux native int10 module (X.Org
Bug #9296)
* obsoletes p_initialize-pci-tag.diff
* Tue Dec 19 2006 - sndirsch@suse.de
- reverted latest change by schwab (Bug #197190, comment #67)
* Mon Dec 18 2006 - schwab@suse.de * Mon Dec 18 2006 - schwab@suse.de
- Fix off-by-one in pci multi-domain support [#229278]. - Fix off-by-one in pci multi-domain support [#229278].
* Wed Dec 13 2006 - sndirsch@suse.de * Wed Dec 13 2006 - sndirsch@suse.de