Remove redundant definition of struct Inst. Safeguard xf86AddDriver against
future additions to DriverRec.
This commit is contained in:
parent
1cfa9f647e
commit
96ca329382
|
@ -1,3 +1,10 @@
|
||||||
|
2006-02-28 Ian Romanick <idr@us.ibm.com>
|
||||||
|
|
||||||
|
* hw/xfree86/common/xf86Helper.c: (xf86AddDriver),
|
||||||
|
(xf86MatchPciInstances):
|
||||||
|
Remove redundant definition of struct Inst.
|
||||||
|
Safeguard xf86AddDriver against future additions to DriverRec.
|
||||||
|
|
||||||
2006-02-28 Daniel Stone <daniel@freedesktop.org>
|
2006-02-28 Daniel Stone <daniel@freedesktop.org>
|
||||||
|
|
||||||
* xkb/maprules.c:
|
* xkb/maprules.c:
|
||||||
|
|
|
@ -90,8 +90,11 @@ xf86AddDriver(DriverPtr driver, pointer module, int flags)
|
||||||
if (flags & HaveDriverFuncs)
|
if (flags & HaveDriverFuncs)
|
||||||
*xf86DriverList[xf86NumDrivers - 1] = *driver;
|
*xf86DriverList[xf86NumDrivers - 1] = *driver;
|
||||||
else {
|
else {
|
||||||
memcpy(xf86DriverList[xf86NumDrivers - 1], driver, sizeof(DriverRec1));
|
(void) memset( xf86DriverList[xf86NumDrivers - 1], 0,
|
||||||
xf86DriverList[xf86NumDrivers - 1]->driverFunc = NULL;
|
sizeof( DriverRec ) );
|
||||||
|
(void) memcpy( xf86DriverList[xf86NumDrivers - 1], driver,
|
||||||
|
sizeof(DriverRec1));
|
||||||
|
|
||||||
}
|
}
|
||||||
xf86DriverList[xf86NumDrivers - 1]->module = module;
|
xf86DriverList[xf86NumDrivers - 1]->module = module;
|
||||||
xf86DriverList[xf86NumDrivers - 1]->refCount = 0;
|
xf86DriverList[xf86NumDrivers - 1]->refCount = 0;
|
||||||
|
@ -1605,14 +1608,7 @@ xf86MatchPciInstances(const char *driverName, int vendorID,
|
||||||
int i,j;
|
int i,j;
|
||||||
MessageType from;
|
MessageType from;
|
||||||
pciVideoPtr pPci, *ppPci;
|
pciVideoPtr pPci, *ppPci;
|
||||||
struct Inst {
|
struct Inst *instances = NULL;
|
||||||
pciVideoPtr pci;
|
|
||||||
GDevPtr dev;
|
|
||||||
Bool foundHW; /* PCIid in list of supported chipsets */
|
|
||||||
Bool claimed; /* BusID matches with a device section */
|
|
||||||
int chip;
|
|
||||||
int screen;
|
|
||||||
} *instances = NULL;
|
|
||||||
int numClaimedInstances = 0;
|
int numClaimedInstances = 0;
|
||||||
int allocatedInstances = 0;
|
int allocatedInstances = 0;
|
||||||
int numFound = 0;
|
int numFound = 0;
|
||||||
|
|
Loading…
Reference in New Issue