Lines Matching refs:pbm

35 static void psycho_check_stc_error(struct pci_pbm_info *pbm)  in psycho_check_stc_error()  argument
38 struct strbuf *strbuf = &pbm->stc; in psycho_check_stc_error()
90 pbm->name, in psycho_check_stc_error()
101 pbm->name, in psycho_check_stc_error()
109 pbm->name, in psycho_check_stc_error()
126 static void psycho_record_iommu_tags_and_data(struct pci_pbm_info *pbm, in psycho_record_iommu_tags_and_data() argument
132 unsigned long base = pbm->controller_regs; in psycho_record_iommu_tags_and_data()
154 static void psycho_dump_iommu_tags_and_data(struct pci_pbm_info *pbm, in psycho_dump_iommu_tags_and_data() argument
185 pbm->name, i, type_str, in psycho_dump_iommu_tags_and_data()
192 pbm->name, i, in psycho_dump_iommu_tags_and_data()
202 void psycho_check_iommu_error(struct pci_pbm_info *pbm, in psycho_check_iommu_error() argument
208 struct iommu *iommu = pbm->iommu; in psycho_check_iommu_error()
235 pbm->name, type_str); in psycho_check_iommu_error()
243 psycho_record_iommu_tags_and_data(pbm, iommu_tag, iommu_data); in psycho_check_iommu_error()
244 psycho_dump_iommu_tags_and_data(pbm, iommu_tag, iommu_data); in psycho_check_iommu_error()
246 psycho_check_stc_error(pbm); in psycho_check_iommu_error()
253 static irqreturn_t psycho_pcierr_intr_other(struct pci_pbm_info *pbm) in psycho_pcierr_intr_other() argument
259 csr = upa_readq(pbm->pci_csr); in psycho_pcierr_intr_other()
263 upa_writeq(csr, pbm->pci_csr); in psycho_pcierr_intr_other()
268 "error asserted.\n", pbm->name); in psycho_pcierr_intr_other()
271 pbm->name); in psycho_pcierr_intr_other()
274 addr = psycho_pci_config_mkaddr(pbm, pbm->pci_first_busno, in psycho_pcierr_intr_other()
283 pbm->name, stat); in psycho_pcierr_intr_other()
307 struct pci_pbm_info *pbm = dev_id; in psycho_pcierr_intr() local
311 afsr = upa_readq(pbm->pci_afsr); in psycho_pcierr_intr()
312 afar = upa_readq(pbm->pci_afar); in psycho_pcierr_intr()
319 return psycho_pcierr_intr_other(pbm); in psycho_pcierr_intr()
320 upa_writeq(error_bits, pbm->pci_afsr); in psycho_pcierr_intr()
322 pbm->name, in psycho_pcierr_intr()
332 pbm->name, in psycho_pcierr_intr()
336 printk(KERN_ERR "%s: PCI AFAR [%016llx]\n", pbm->name, afar); in psycho_pcierr_intr()
337 printk(KERN_ERR "%s: PCI Secondary errors [", pbm->name); in psycho_pcierr_intr()
360 psycho_check_iommu_error(pbm, afsr, afar, PCI_ERR); in psycho_pcierr_intr()
361 pci_scan_for_target_abort(pbm, pbm->pci_bus); in psycho_pcierr_intr()
364 pci_scan_for_master_abort(pbm, pbm->pci_bus); in psycho_pcierr_intr()
367 pci_scan_for_parity_error(pbm, pbm->pci_bus); in psycho_pcierr_intr()
372 static void psycho_iommu_flush(struct pci_pbm_info *pbm) in psycho_iommu_flush() argument
379 upa_writeq(0, pbm->controller_regs + PSYCHO_IOMMU_TAG + off); in psycho_iommu_flush()
380 upa_writeq(0, pbm->controller_regs + PSYCHO_IOMMU_DATA + off); in psycho_iommu_flush()
400 int psycho_iommu_init(struct pci_pbm_info *pbm, int tsbsize, in psycho_iommu_init() argument
404 struct iommu *iommu = pbm->iommu; in psycho_iommu_init()
408 iommu->iommu_control = pbm->controller_regs + PSYCHO_IOMMU_CONTROL; in psycho_iommu_init()
409 iommu->iommu_tsbbase = pbm->controller_regs + PSYCHO_IOMMU_TSBBASE; in psycho_iommu_init()
410 iommu->iommu_flush = pbm->controller_regs + PSYCHO_IOMMU_FLUSH; in psycho_iommu_init()
411 iommu->iommu_tags = pbm->controller_regs + PSYCHO_IOMMU_TAG; in psycho_iommu_init()
412 iommu->write_complete_reg = (pbm->controller_regs + in psycho_iommu_init()
421 psycho_iommu_flush(pbm); in psycho_iommu_init()
425 dvma_offset, dma_mask, pbm->numa_node); in psycho_iommu_init()
452 void psycho_pbm_init_common(struct pci_pbm_info *pbm, struct platform_device *op, in psycho_pbm_init_common() argument
457 pbm->name = dp->full_name; in psycho_pbm_init_common()
458 pbm->numa_node = NUMA_NO_NODE; in psycho_pbm_init_common()
459 pbm->chip_type = chip_type; in psycho_pbm_init_common()
460 pbm->chip_version = of_getintprop_default(dp, "version#", 0); in psycho_pbm_init_common()
461 pbm->chip_revision = of_getintprop_default(dp, "module-revision#", 0); in psycho_pbm_init_common()
462 pbm->op = op; in psycho_pbm_init_common()
463 pbm->pci_ops = &sun4u_pci_ops; in psycho_pbm_init_common()
464 pbm->config_space_reg_bits = 8; in psycho_pbm_init_common()
465 pbm->index = pci_num_pbms++; in psycho_pbm_init_common()
466 pci_get_pbm_props(pbm); in psycho_pbm_init_common()
467 pci_determine_mem_io_space(pbm); in psycho_pbm_init_common()
470 pbm->name, chip_name, in psycho_pbm_init_common()
471 pbm->chip_version, pbm->chip_revision); in psycho_pbm_init_common()