From: Greg Kroah-Hartman Date: Wed, 2 Jul 2008 20:24:49 +0000 (-0700) Subject: PCI: handle pci_name() being const X-Git-Tag: v2.6.27-rc1~1046^2~16 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=eebfcfb52ce753eaaa8525078bda6b539586066c;p=linux-2.6-omap-h63xx.git PCI: handle pci_name() being const This changes pci_setup_device to handle pci_name() now returning a constant string. Signed-off-by: Greg Kroah-Hartman Signed-off-by: Jesse Barnes --- diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 0420fd8027b..2f0ae70710d 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c @@ -713,9 +713,9 @@ static int pci_setup_device(struct pci_dev * dev) { u32 class; - snprintf(dev->dev.bus_id, BUS_ID_SIZE, - "%04x:%02x:%02x.%d", pci_domain_nr(dev->bus), - dev->bus->number, PCI_SLOT(dev->devfn), PCI_FUNC(dev->devfn)); + dev_set_name(&dev->dev, "%04x:%02x:%02x.%d", pci_domain_nr(dev->bus), + dev->bus->number, PCI_SLOT(dev->devfn), + PCI_FUNC(dev->devfn)); pci_read_config_dword(dev, PCI_CLASS_REVISION, &class); dev->revision = class & 0xff;