Lines Matching refs:pdn
370 static void pnv_pci_config_check_eeh(struct pci_dn *pdn) in pnv_pci_config_check_eeh() argument
372 struct pnv_phb *phb = pdn->phb->private_data; in pnv_pci_config_check_eeh()
383 pe_no = pdn->pe_number; in pnv_pci_config_check_eeh()
411 (pdn->busno << 8) | (pdn->devfn), pe_no, fstate); in pnv_pci_config_check_eeh()
428 int pnv_pci_cfg_read(struct pci_dn *pdn, in pnv_pci_cfg_read() argument
431 struct pnv_phb *phb = pdn->phb->private_data; in pnv_pci_cfg_read()
432 u32 bdfn = (pdn->busno << 8) | pdn->devfn; in pnv_pci_cfg_read()
460 __func__, pdn->busno, pdn->devfn, where, size, *val); in pnv_pci_cfg_read()
464 int pnv_pci_cfg_write(struct pci_dn *pdn, in pnv_pci_cfg_write() argument
467 struct pnv_phb *phb = pdn->phb->private_data; in pnv_pci_cfg_write()
468 u32 bdfn = (pdn->busno << 8) | pdn->devfn; in pnv_pci_cfg_write()
471 pdn->busno, pdn->devfn, where, size, val); in pnv_pci_cfg_write()
490 static bool pnv_pci_cfg_check(struct pci_dn *pdn) in pnv_pci_cfg_check() argument
493 struct pnv_phb *phb = pdn->phb->private_data; in pnv_pci_cfg_check()
500 edev = pdn->edev; in pnv_pci_cfg_check()
513 static inline pnv_pci_cfg_check(struct pci_dn *pdn) in pnv_pci_cfg_check() argument
523 struct pci_dn *pdn; in pnv_pci_read_config() local
528 pdn = pci_get_pdn_by_devfn(bus, devfn); in pnv_pci_read_config()
529 if (!pdn) in pnv_pci_read_config()
532 if (!pnv_pci_cfg_check(pdn)) in pnv_pci_read_config()
535 ret = pnv_pci_cfg_read(pdn, where, size, val); in pnv_pci_read_config()
536 phb = pdn->phb->private_data; in pnv_pci_read_config()
537 if (phb->flags & PNV_PHB_FLAG_EEH && pdn->edev) { in pnv_pci_read_config()
539 eeh_dev_check_failure(pdn->edev)) in pnv_pci_read_config()
542 pnv_pci_config_check_eeh(pdn); in pnv_pci_read_config()
552 struct pci_dn *pdn; in pnv_pci_write_config() local
556 pdn = pci_get_pdn_by_devfn(bus, devfn); in pnv_pci_write_config()
557 if (!pdn) in pnv_pci_write_config()
560 if (!pnv_pci_cfg_check(pdn)) in pnv_pci_write_config()
563 ret = pnv_pci_cfg_write(pdn, where, size, val); in pnv_pci_write_config()
564 phb = pdn->phb->private_data; in pnv_pci_write_config()
566 pnv_pci_config_check_eeh(pdn); in pnv_pci_write_config()
672 struct pci_dn *pdn; in pnv_pci_dma_dev_setup() local
676 pdn = pci_get_pdn(pdev); in pnv_pci_dma_dev_setup()
677 WARN_ON(pdn->pe_number != IODA_INVALID_PE); in pnv_pci_dma_dev_setup()
681 pdn->pe_number = pe->pe_number; in pnv_pci_dma_dev_setup()