Lines Matching refs:bus

58 	return dev->bus->chipinfo.id == BCMA_CHIP_ID_BCM47162 &&  in bcma_core_mips_bcm47162a0_quirk()
59 dev->bus->chipinfo.rev == 0 && dev->id.id == BCMA_CORE_MIPS_74K; in bcma_core_mips_bcm47162a0_quirk()
65 return (dev->bus->chipinfo.id == BCMA_CHIP_ID_BCM5357 || in bcma_core_mips_bcm5357b0_quirk()
66 dev->bus->chipinfo.id == BCMA_CHIP_ID_BCM4749) && in bcma_core_mips_bcm5357b0_quirk()
67 dev->bus->chipinfo.pkg == 11 && in bcma_core_mips_bcm5357b0_quirk()
123 struct bcma_device *mdev = dev->bus->drv_mips.core; in bcma_core_mips_irq()
142 struct bcma_bus *bus = dev->bus; in bcma_core_mips_set_irq() local
143 struct bcma_device *mdev = bus->drv_mips.core; in bcma_core_mips_set_irq()
173 list_for_each_entry(core, &bus->cores, list) { in bcma_core_mips_set_irq()
185 bcma_debug(bus, "set_irq: core 0x%04x, irq %d => %d\n", in bcma_core_mips_set_irq()
189 static void bcma_core_mips_set_irq_name(struct bcma_bus *bus, unsigned int irq, in bcma_core_mips_set_irq_name() argument
194 core = bcma_find_core_unit(bus, coreid, unit); in bcma_core_mips_set_irq_name()
196 bcma_warn(bus, in bcma_core_mips_set_irq_name()
215 static void bcma_core_mips_dump_irq(struct bcma_bus *bus) in bcma_core_mips_dump_irq() argument
219 list_for_each_entry(core, &bus->cores, list) { in bcma_core_mips_dump_irq()
226 struct bcma_bus *bus = mcore->core->bus; in bcma_cpu_clock() local
228 if (bus->drv_cc.capabilities & BCMA_CC_CAP_PMU) in bcma_cpu_clock()
229 return bcma_pmu_get_cpu_clock(&bus->drv_cc); in bcma_cpu_clock()
231 bcma_err(bus, "No PMU available, need this to get the cpu clock\n"); in bcma_cpu_clock()
236 static enum bcma_boot_dev bcma_boot_dev(struct bcma_bus *bus) in bcma_boot_dev() argument
238 struct bcma_drv_cc *cc = &bus->drv_cc; in bcma_boot_dev()
244 core = bcma_find_core(bus, BCMA_CORE_NS_ROM); in bcma_boot_dev()
277 struct bcma_bus *bus = mcore->core->bus; in bcma_core_mips_flash_detect() local
278 struct bcma_drv_cc *cc = &bus->drv_cc; in bcma_core_mips_flash_detect()
285 bcma_debug(bus, "Found serial flash\n"); in bcma_core_mips_flash_detect()
289 bcma_debug(bus, "Found parallel flash\n"); in bcma_core_mips_flash_detect()
306 bcma_err(bus, "Flash type not supported\n"); in bcma_core_mips_flash_detect()
310 bus->chipinfo.id == BCMA_CHIP_ID_BCM4706) { in bcma_core_mips_flash_detect()
312 bcma_debug(bus, "Found NAND flash\n"); in bcma_core_mips_flash_detect()
318 boot_dev = bcma_boot_dev(bus); in bcma_core_mips_flash_detect()
340 struct bcma_bus *bus = mcore->core->bus; in bcma_core_mips_early_init() local
345 bcma_chipco_serial_init(&bus->drv_cc); in bcma_core_mips_early_init()
351 static void bcma_fix_i2s_irqflag(struct bcma_bus *bus) in bcma_fix_i2s_irqflag() argument
358 if (bus->chipinfo.id != BCMA_CHIP_ID_BCM4716 && in bcma_fix_i2s_irqflag()
359 bus->chipinfo.id != BCMA_CHIP_ID_BCM4748) in bcma_fix_i2s_irqflag()
362 cpu = bcma_find_core(bus, BCMA_CORE_MIPS_74K); in bcma_fix_i2s_irqflag()
363 pcie = bcma_find_core(bus, BCMA_CORE_PCIE); in bcma_fix_i2s_irqflag()
364 i2s = bcma_find_core(bus, BCMA_CORE_I2S); in bcma_fix_i2s_irqflag()
372 bcma_debug(bus, in bcma_fix_i2s_irqflag()
379 struct bcma_bus *bus; in bcma_core_mips_init() local
381 bus = mcore->core->bus; in bcma_core_mips_init()
386 bcma_debug(bus, "Initializing MIPS core...\n"); in bcma_core_mips_init()
390 bcma_fix_i2s_irqflag(bus); in bcma_core_mips_init()
392 switch (bus->chipinfo.id) { in bcma_core_mips_init()
395 bcma_core_mips_set_irq_name(bus, 1, BCMA_CORE_80211, 0); in bcma_core_mips_init()
396 bcma_core_mips_set_irq_name(bus, 2, BCMA_CORE_MAC_GBIT, 0); in bcma_core_mips_init()
397 bcma_core_mips_set_irq_name(bus, 3, BCMA_CORE_USB20_HOST, 0); in bcma_core_mips_init()
398 bcma_core_mips_set_irq_name(bus, 4, BCMA_CORE_PCIE, 0); in bcma_core_mips_init()
399 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_CHIPCOMMON, 0); in bcma_core_mips_init()
400 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_I2S, 0); in bcma_core_mips_init()
405 bcma_core_mips_set_irq_name(bus, 1, BCMA_CORE_80211, 0); in bcma_core_mips_init()
406 bcma_core_mips_set_irq_name(bus, 2, BCMA_CORE_MAC_GBIT, 0); in bcma_core_mips_init()
407 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_CHIPCOMMON, 0); in bcma_core_mips_init()
411 bcma_core_mips_set_irq_name(bus, 1, BCMA_CORE_80211, 0); in bcma_core_mips_init()
412 bcma_core_mips_set_irq_name(bus, 2, BCMA_CORE_MAC_GBIT, 0); in bcma_core_mips_init()
413 bcma_core_mips_set_irq_name(bus, 3, BCMA_CORE_USB20_HOST, 0); in bcma_core_mips_init()
414 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_CHIPCOMMON, 0); in bcma_core_mips_init()
415 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_I2S, 0); in bcma_core_mips_init()
418 bcma_core_mips_set_irq_name(bus, 1, BCMA_CORE_PCIE, 0); in bcma_core_mips_init()
419 bcma_core_mips_set_irq_name(bus, 2, BCMA_CORE_4706_MAC_GBIT, in bcma_core_mips_init()
421 bcma_core_mips_set_irq_name(bus, 3, BCMA_CORE_PCIE, 1); in bcma_core_mips_init()
422 bcma_core_mips_set_irq_name(bus, 4, BCMA_CORE_USB20_HOST, 0); in bcma_core_mips_init()
423 bcma_core_mips_set_irq_name(bus, 0, BCMA_CORE_4706_CHIPCOMMON, in bcma_core_mips_init()
427 list_for_each_entry(core, &bus->cores, list) { in bcma_core_mips_init()
430 bcma_err(bus, in bcma_core_mips_init()
432 bus->chipinfo.id); in bcma_core_mips_init()
434 bcma_debug(bus, "IRQ reconfiguration done\n"); in bcma_core_mips_init()
435 bcma_core_mips_dump_irq(bus); in bcma_core_mips_init()