Lines Matching refs:pci_dev
346 int asihpi_adapter_probe(struct pci_dev *pci_dev, in asihpi_adapter_probe() argument
359 dev_printk(KERN_DEBUG, &pci_dev->dev, in asihpi_adapter_probe()
360 "probe %04x:%04x,%04x:%04x,%04x\n", pci_dev->vendor, in asihpi_adapter_probe()
361 pci_dev->device, pci_dev->subsystem_vendor, in asihpi_adapter_probe()
362 pci_dev->subsystem_device, pci_dev->devfn); in asihpi_adapter_probe()
364 if (pcim_enable_device(pci_dev) < 0) { in asihpi_adapter_probe()
365 dev_err(&pci_dev->dev, in asihpi_adapter_probe()
370 pci_set_master(pci_dev); /* also sets latency timer if < 16 */ in asihpi_adapter_probe()
383 &pci_dev->resource[idx]); in asihpi_adapter_probe()
385 if (pci_resource_flags(pci_dev, idx) & IORESOURCE_MEM) { in asihpi_adapter_probe()
386 memlen = pci_resource_len(pci_dev, idx); in asihpi_adapter_probe()
388 ioremap(pci_resource_start(pci_dev, idx), in asihpi_adapter_probe()
399 pci.pci_dev = pci_dev; in asihpi_adapter_probe()
442 dev_info(&pci_dev->dev, in asihpi_adapter_probe()
453 dev_info(&pci_dev->dev, in asihpi_adapter_probe()
465 pci_set_drvdata(pci_dev, &adapters[adapter_index]); in asihpi_adapter_probe()
469 dev_err(&pci_dev->dev, in asihpi_adapter_probe()
490 if (request_threaded_irq(pci_dev->irq, asihpi_isr, in asihpi_adapter_probe()
493 dev_err(&pci_dev->dev, "request_irq(%d) failed\n", in asihpi_adapter_probe()
494 pci_dev->irq); in asihpi_adapter_probe()
500 dev_info(&pci_dev->dev, "using irq %d\n", pci_dev->irq); in asihpi_adapter_probe()
501 adapters[adapter_index].irq = pci_dev->irq; in asihpi_adapter_probe()
503 dev_info(&pci_dev->dev, "using polled mode\n"); in asihpi_adapter_probe()
506 dev_info(&pci_dev->dev, "probe succeeded for ASI%04X HPI index %d\n", in asihpi_adapter_probe()
528 void asihpi_adapter_remove(struct pci_dev *pci_dev) in asihpi_adapter_remove() argument
536 pa = pci_get_drvdata(pci_dev); in asihpi_adapter_remove()
563 dev_info(&pci_dev->dev, in asihpi_adapter_remove()
565 pci_dev->vendor, pci_dev->device, in asihpi_adapter_remove()
566 pci_dev->subsystem_vendor, pci_dev->subsystem_device, in asihpi_adapter_remove()
567 pci_dev->devfn, pa->adapter->index); in asihpi_adapter_remove()