Lines Matching refs:pbm
185 struct pyro_pbm *pbm; in pyro_init() local
189 pbm = kmem_zalloc(sizeof(*pbm), KM_SLEEP); in pyro_init()
190 pbm->pp_sc = sc; in pyro_init()
191 pbm->pp_bus_a = busa; in pyro_init()
194 &pbm->pp_nrange, (void **)&pbm->pp_range)) in pyro_init()
207 pyro_init_iommu(sc, pbm); in pyro_init()
209 pbm->pp_memt = pyro_alloc_mem_tag(pbm); in pyro_init()
210 pbm->pp_iot = pyro_alloc_io_tag(pbm); in pyro_init()
211 pbm->pp_cfgt = pyro_alloc_config_tag(pbm); in pyro_init()
212 pbm->pp_dmat = pyro_alloc_dma_tag(pbm); in pyro_init()
213 pbm->pp_flags = (pbm->pp_memt ? PCI_FLAGS_MEM_OKAY : 0) | in pyro_init()
214 (pbm->pp_iot ? PCI_FLAGS_IO_OKAY : 0); in pyro_init()
216 if (bus_space_map(pbm->pp_cfgt, 0, 0x10000000, 0, &pbm->pp_cfgh)) in pyro_init()
219 pbm->pp_pc = pyro_alloc_chipset(pbm, sc->sc_node, &_sparc_pci_chipset); in pyro_init()
220 pbm->pp_pc->spc_busmax = busranges[1]; in pyro_init()
221 pbm->pp_pc->spc_busnode = kmem_zalloc(sizeof(*pbm->pp_pc->spc_busnode), in pyro_init()
225 pbm->pp_pc->bustag = pbm->pp_cfgt; in pyro_init()
226 pbm->pp_pc->bushandle = pbm->pp_cfgh; in pyro_init()
231 pba.pba_pc = pbm->pp_pc; in pyro_init()
232 pba.pba_flags = pbm->pp_flags; in pyro_init()
233 pba.pba_dmat = pbm->pp_dmat; in pyro_init()
235 pba.pba_memt = pbm->pp_memt; in pyro_init()
236 pba.pba_iot = pbm->pp_iot; in pyro_init()
245 pyro_init_iommu(struct pyro_softc *sc, struct pyro_pbm *pbm) in pyro_init_iommu() argument
247 struct iommu_state *is = &pbm->pp_is; in pyro_init_iommu()
252 pbm->pp_sb.sb_is = is; in pyro_init_iommu()
391 pyro_alloc_bus_tag(struct pyro_pbm *pbm, const char *name, int type) in pyro_alloc_bus_tag() argument
393 struct pyro_softc *sc = pbm->pp_sc; in pyro_alloc_bus_tag()
403 bt->cookie = pbm; in pyro_alloc_bus_tag()
413 pyro_alloc_dma_tag(struct pyro_pbm *pbm) in pyro_alloc_dma_tag() argument
415 struct pyro_softc *sc = pbm->pp_sc; in pyro_alloc_dma_tag()
419 dt->_cookie = pbm; in pyro_alloc_dma_tag()
440 pyro_alloc_chipset(struct pyro_pbm *pbm, int node, pci_chipset_tag_t pc) in pyro_alloc_chipset() argument
446 npc->cookie = pbm; in pyro_alloc_chipset()
461 struct pyro_pbm *pbm = t->_cookie; in pyro_dmamap_create() local
467 (*dmamp)->_dm_cookie = &pbm->pp_sb; in pyro_dmamap_create()
475 struct pyro_pbm *pbm = t->cookie; in pyro_bus_map() local
476 struct pyro_softc *sc = pbm->pp_sc; in pyro_bus_map()
499 for (i = 0; i < pbm->pp_nrange; i++) { in pyro_bus_map()
501 struct pyro_range *pr = &pbm->pp_range[i]; in pyro_bus_map()
519 struct pyro_pbm *pbm = t->cookie; in pyro_bus_mmap() local
520 struct pyro_softc *sc = pbm->pp_sc; in pyro_bus_mmap()
539 for (i = 0; i < pbm->pp_nrange; i++) { in pyro_bus_mmap()
540 struct pyro_range *pr = &pbm->pp_range[i]; in pyro_bus_mmap()
557 struct pyro_pbm *pbm = t->cookie; in pyro_intr_establish() local
558 struct pyro_softc *sc = pbm->pp_sc; in pyro_intr_establish()
640 struct pyro_pbm *pbm = (struct pyro_pbm *)pc->cookie; in pyro_pci_intr_establish() local
643 cookie = bus_intr_establish(pbm->pp_memt, ih, level, func, arg); in pyro_pci_intr_establish()