xserver: Branch 'master' - 2 commits
Keith Packard
keithp at kemper.freedesktop.org
Thu Jul 1 05:15:38 PDT 2010
hw/xfree86/common/xf86Configure.c | 25 -------------------------
hw/xfree86/common/xf86pciBus.c | 13 +------------
2 files changed, 1 insertion(+), 37 deletions(-)
New commits:
commit 5ea497fc32202ff19c2b7d8ef4eba08889108a87
Author: Tiago Vignatti <tiago.vignatti at nokia.com>
Date: Tue Jun 29 16:08:02 2010 +0300
xfree86: configure: remove vendor and card name matching rules
Although vendor and board naming are used to create the configure file, the
server doesn't actually use it when fetching such file and probing devices.
Reported-by: Richard Barnette <jrbarnette at chromium.org>
Signed-off-by: Tiago Vignatti <tiago.vignatti at nokia.com>
Reviewed-by: Mikhail Gusarov <dottedmag at dottedmag.net>
Reviewed-by: Alex Deucher <alexdeucher at gmail.com>
Tested-by: Richard Barnette <jrbarnette at chromium.org>
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/common/xf86Configure.c b/hw/xfree86/common/xf86Configure.c
index 822d767..da654f0 100644
--- a/hw/xfree86/common/xf86Configure.c
+++ b/hw/xfree86/common/xf86Configure.c
@@ -107,8 +107,6 @@ bus_sbus_configure(void *busData)
static void
bus_pci_newdev_configure(void *busData, int i, int *chipset)
{
- const char *VendorName;
- const char *CardName;
char busnum[8];
struct pci_device * pVideo = NULL;
@@ -116,26 +114,6 @@ bus_pci_newdev_configure(void *busData, int i, int *chipset)
DevToConfig[i].pVideo = pVideo;
- VendorName = pci_device_get_vendor_name( pVideo );
- CardName = pci_device_get_device_name( pVideo );
-
- if (!VendorName) {
- VendorName = xnfalloc(15);
- sprintf((char*)VendorName, "Unknown Vendor");
- }
-
- if (!CardName) {
- CardName = xnfalloc(14);
- sprintf((char*)CardName, "Unknown Board");
- }
-
- DevToConfig[i].GDev.identifier =
- xnfalloc(strlen(VendorName) + strlen(CardName) + 2);
- sprintf(DevToConfig[i].GDev.identifier, "%s %s", VendorName, CardName);
-
- DevToConfig[i].GDev.vendor = (char *)VendorName;
- DevToConfig[i].GDev.board = (char *)CardName;
-
DevToConfig[i].GDev.busID = xnfalloc(16);
xf86FormatPciBusNumber(pVideo->bus, busnum);
sprintf(DevToConfig[i].GDev.busID, "PCI:%s:%d:%d",
@@ -357,9 +335,6 @@ configureDeviceSection (int screennum)
/* Move device info to parser structure */
sprintf(identifier, "Card%d", screennum);
ptr->dev_identifier = strdup(identifier);
-/* ptr->dev_identifier = DevToConfig[screennum].GDev.identifier;*/
- ptr->dev_vendor = DevToConfig[screennum].GDev.vendor;
- ptr->dev_board = DevToConfig[screennum].GDev.board;
ptr->dev_chipset = DevToConfig[screennum].GDev.chipset;
ptr->dev_busid = DevToConfig[screennum].GDev.busID;
ptr->dev_driver = DevToConfig[screennum].GDev.driver;
commit 90fd9e40b59e69333d250a795998f44dc3a5dc0c
Author: Tiago Vignatti <tiago.vignatti at nokia.com>
Date: Tue Jun 29 16:08:01 2010 +0300
xfree86: pci: remove superfluous vendor and card name logging
X server suffers in startup time when relying on the pciaccess's linear search
to fetch vendor and video device name from PCI ID file (when existent). Such
names are only used to write the log, which may be superfluous. This
information often is provided by the drivers or likewise users can get the it
using external tools like lspci or scanpci.
This patch remove the references of those functions from X start up.
Reported-by: Richard Barnette <jrbarnette at chromium.org>
Signed-off-by: Tiago Vignatti <tiago.vignatti at nokia.com>
Tested-by: Richard Barnette <jrbarnette at chromium.org>
Reviewed-by: James Cloos <cloos at jhcloos.com>
Reviewed-by: Mikhail Gusarov <dottedmag at dottedmag.net>
Reviewed-by: Alex Deucher <alexdeucher at gmail.com>
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/common/xf86pciBus.c b/hw/xfree86/common/xf86pciBus.c
index 1517951..74016af 100644
--- a/hw/xfree86/common/xf86pciBus.c
+++ b/hw/xfree86/common/xf86pciBus.c
@@ -151,18 +151,13 @@ xf86PciProbe(void)
/* Print a summary of the video devices found */
for (k = 0; k < num; k++) {
- const char *vendorname = NULL, *chipname = NULL;
const char *prim = " ";
Bool memdone = FALSE, iodone = FALSE;
info = xf86PciVideoInfo[k];
- vendorname = pci_device_get_vendor_name( info );
- chipname = pci_device_get_device_name( info );
-
- if ((!vendorname || !chipname) &&
- !PCIALWAYSPRINTCLASSES(info->device_class))
+ if (!PCIALWAYSPRINTCLASSES(info->device_class))
continue;
if (xf86IsPrimaryPci(info))
@@ -173,12 +168,6 @@ xf86PciProbe(void)
info->vendor_id, info->device_id,
info->subvendor_id, info->subdevice_id);
- if (vendorname)
- xf86ErrorF("%s ", vendorname);
-
- if (chipname)
- xf86ErrorF("%s ", chipname);
-
xf86ErrorF("rev %d", info->revision);
for (i = 0; i < 6; i++) {
More information about the xorg-commit
mailing list