Lines Matching refs:pci_info

98 static void amd8111_pci_bridge_init(struct amd8111_pci_info *pci_info)  in amd8111_pci_bridge_init()  argument
101 struct pci_dev *dev = pci_info->dev; in amd8111_pci_bridge_init()
146 static void amd8111_pci_bridge_exit(struct amd8111_pci_info *pci_info) in amd8111_pci_bridge_exit() argument
149 struct pci_dev *dev = pci_info->dev; in amd8111_pci_bridge_exit()
171 struct amd8111_pci_info *pci_info = edac_dev->pvt_info; in amd8111_pci_bridge_check() local
172 struct pci_dev *dev = pci_info->dev; in amd8111_pci_bridge_check()
179 "register on device %s\n", pci_info->ctl_name); in amd8111_pci_bridge_check()
195 "register on device %s\n", pci_info->ctl_name); in amd8111_pci_bridge_check()
209 "register on device %s\n", pci_info->ctl_name); in amd8111_pci_bridge_check()
224 pci_info->ctl_name); in amd8111_pci_bridge_check()
439 struct amd8111_pci_info *pci_info = &amd8111_pcis[id->driver_data]; in amd8111_pci_probe() local
441 pci_info->dev = pci_get_device(PCI_VENDOR_ID_AMD, in amd8111_pci_probe()
442 pci_info->err_dev, NULL); in amd8111_pci_probe()
444 if (!pci_info->dev) { in amd8111_pci_probe()
447 PCI_VENDOR_ID_AMD, pci_info->err_dev, in amd8111_pci_probe()
448 pci_info->ctl_name); in amd8111_pci_probe()
452 if (pci_enable_device(pci_info->dev)) { in amd8111_pci_probe()
453 pci_dev_put(pci_info->dev); in amd8111_pci_probe()
456 PCI_VENDOR_ID_AMD, pci_info->err_dev, in amd8111_pci_probe()
457 pci_info->ctl_name); in amd8111_pci_probe()
466 pci_info->edac_idx = edac_pci_alloc_index(); in amd8111_pci_probe()
467 pci_info->edac_dev = edac_pci_alloc_ctl_info(0, pci_info->ctl_name); in amd8111_pci_probe()
468 if (!pci_info->edac_dev) in amd8111_pci_probe()
471 pci_info->edac_dev->pvt_info = pci_info; in amd8111_pci_probe()
472 pci_info->edac_dev->dev = &pci_info->dev->dev; in amd8111_pci_probe()
473 pci_info->edac_dev->mod_name = AMD8111_EDAC_MOD_STR; in amd8111_pci_probe()
474 pci_info->edac_dev->ctl_name = pci_info->ctl_name; in amd8111_pci_probe()
475 pci_info->edac_dev->dev_name = dev_name(&pci_info->dev->dev); in amd8111_pci_probe()
478 pci_info->edac_dev->edac_check = pci_info->check; in amd8111_pci_probe()
480 if (pci_info->init) in amd8111_pci_probe()
481 pci_info->init(pci_info); in amd8111_pci_probe()
483 if (edac_pci_add_device(pci_info->edac_dev, pci_info->edac_idx) > 0) { in amd8111_pci_probe()
485 pci_info->ctl_name); in amd8111_pci_probe()
486 edac_pci_free_ctl_info(pci_info->edac_dev); in amd8111_pci_probe()
492 PCI_VENDOR_ID_AMD, pci_info->err_dev, in amd8111_pci_probe()
493 pci_info->ctl_name); in amd8111_pci_probe()
500 struct amd8111_pci_info *pci_info; in amd8111_pci_remove() local
502 for (pci_info = amd8111_pcis; pci_info->err_dev; pci_info++) in amd8111_pci_remove()
503 if (pci_info->dev->device == dev->device) in amd8111_pci_remove()
506 if (!pci_info->err_dev) /* should never happen */ in amd8111_pci_remove()
509 if (pci_info->edac_dev) { in amd8111_pci_remove()
510 edac_pci_del_device(pci_info->edac_dev->dev); in amd8111_pci_remove()
511 edac_pci_free_ctl_info(pci_info->edac_dev); in amd8111_pci_remove()
514 if (pci_info->exit) in amd8111_pci_remove()
515 pci_info->exit(pci_info); in amd8111_pci_remove()
517 pci_dev_put(pci_info->dev); in amd8111_pci_remove()