Bugzilla – Attachment 63024 Details for
Bug 132308
X server crashes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
Incremental patch to fix Bug #142039
p_pci-domain-incr.diff (text/plain), 2.08 KB, created by
Stefan Dirsch
on 2006-01-12 05:29:38 UTC
(
hide
)
Description:
Incremental patch to fix Bug #142039
Filename:
MIME Type:
Creator:
Stefan Dirsch
Created:
2006-01-12 05:29:38 UTC
Size:
2.08 KB
patch
obsolete
>diff -u programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c >--- programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c 2005-11-29 01:08:03.000000000 +0100 >+++ programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c 2006-01-10 18:24:54.000000000 +0100 >@@ -540,18 +540,18 @@ > pPCI = xf86GetPciHostConfigFromTag(Tag); > > if (pPCI && (result = PCI_DOM_FROM_BUS(pPCI->busnum))) >- return result + 1; >+ return result; > > if (!pPCI || pPCI->fakeDevice) >- 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 >@@ -623,7 +623,7 @@ > return NULL; > } > >-#define MAX_DOMAINS 257 >+#define MAX_DOMAINS 256 > static pointer DomainMmappedIO[MAX_DOMAINS]; > static pointer DomainMmappedMem[MAX_DOMAINS]; > >@@ -645,11 +645,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); >@@ -734,7 +733,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]) >@@ -880,7 +879,7 @@ > RANGE_TYPE(ResExcIoBlock, domain)); > pRes = xf86AddResToList(pRes, &range, -1); > >- if (domain <= 0) >+ if (domain < 0) > break; > } > } >@@ -932,7 +931,7 @@ > RANGE_TYPE(ResExcIoBlock, domain)); > pRes = xf86AddResToList(pRes, &range, -1); > >- if (domain <= 0) >+ if (domain < 0) > break; > } > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 132308
:
56480
|
56955
|
58767
|
58769
|
58776
|
58825
|
58912
| 63024