return 0;
out += sprintf(out, "\n%s (vid/did: %04x/%04x)\n",
- pdev->dev.name, (int)pdev->vendor, (int)pdev->device);
+ pci_name(pdev), (int)pdev->vendor, (int)pdev->device);
out += sprintf(out, "pci-power-state: %u\n", (unsigned) pdev->current_state);
out += sprintf(out, "resources: irq=%u / io=0x%04x / dma_mask=0x%016Lx\n",
pdev->irq, (unsigned)pci_resource_start(pdev, 0), (u64)pdev->dma_mask);
if (vlsi_start_hw(idev))
printk(KERN_CRIT "%s: failed to restart hw - %s(%s) unusable!\n",
- __FUNCTION__, idev->pdev->dev.name, ndev->name);
+ __FUNCTION__, pci_name(idev->pdev), ndev->name);
else
netif_start_queue(ndev);
}
pdev->current_state = 0; /* hw must be running now */
printk(KERN_INFO "%s: IrDA PCI controller %s detected\n",
- drivername, pdev->dev.name);
+ drivername, pci_name(pdev));
if ( !pci_resource_start(pdev,0)
|| !(pci_resource_flags(pdev,0) & IORESOURCE_IO) ) {
* ndev->destructor called (if present) when going to free
*/
- printk(KERN_INFO "%s: %s removed\n", drivername, pdev->dev.name);
+ printk(KERN_INFO "%s: %s removed\n", drivername, pci_name(pdev));
}
#ifdef CONFIG_PM
{
if (state < 1 || state > 3 ) {
printk( KERN_ERR "%s - %s: invalid pm state request: %u\n",
- __FUNCTION__, pdev->dev.name, state);
+ __FUNCTION__, pci_name(pdev), state);
return -1;
}
return 0;
if (state < 1 || state > 3 ) {
printk( KERN_ERR "%s - %s: invalid pm state request: %u\n",
- __FUNCTION__, pdev->dev.name, state);
+ __FUNCTION__, pci_name(pdev), state);
return 0;
}
if (!ndev) {
- printk(KERN_ERR "%s - %s: no netdevice \n", __FUNCTION__, pdev->dev.name);
+ printk(KERN_ERR "%s - %s: no netdevice \n", __FUNCTION__, pci_name(pdev));
return 0;
}
idev = ndev->priv;
}
else
printk(KERN_ERR "%s - %s: invalid suspend request %u -> %u\n",
- __FUNCTION__, pdev->dev.name, pdev->current_state, state);
+ __FUNCTION__, pci_name(pdev), pdev->current_state, state);
up(&idev->sem);
return 0;
}
vlsi_irda_dev_t *idev;
if (!ndev) {
- printk(KERN_ERR "%s - %s: no netdevice \n", __FUNCTION__, pdev->dev.name);
+ printk(KERN_ERR "%s - %s: no netdevice \n", __FUNCTION__, pci_name(pdev));
return 0;
}
idev = ndev->priv;
down(&idev->sem);
if (pdev->current_state == 0) {
up(&idev->sem);
- printk(KERN_ERR "%s - %s: already resumed\n", __FUNCTION__, pdev->dev.name);
+ printk(KERN_ERR "%s - %s: already resumed\n", __FUNCTION__, pci_name(pdev));
return 0;
}