Lines Matching refs:xgene_msi

27 	struct xgene_msi	*msi;
32 struct xgene_msi { struct
45 static struct xgene_msi xgene_msi_ctrl; argument
94 static u32 xgene_msi_ir_read(struct xgene_msi *msi, in xgene_msi_ir_read()
102 static u32 xgene_msi_int_read(struct xgene_msi *msi, u32 msi_grp) in xgene_msi_int_read()
143 struct xgene_msi *msi = irq_data_get_irq_chip_data(data); in xgene_compose_msi_msg()
197 struct xgene_msi *msi = domain->host_data; in xgene_irq_domain_alloc()
225 struct xgene_msi *msi = irq_data_get_irq_chip_data(d); in xgene_irq_domain_free()
243 static int xgene_allocate_domains(struct xgene_msi *msi) in xgene_allocate_domains()
262 static void xgene_free_domains(struct xgene_msi *msi) in xgene_free_domains()
270 static int xgene_msi_init_allocator(struct xgene_msi *xgene_msi) in xgene_msi_init_allocator() argument
274 xgene_msi->bitmap = kzalloc(size, GFP_KERNEL); in xgene_msi_init_allocator()
275 if (!xgene_msi->bitmap) in xgene_msi_init_allocator()
278 mutex_init(&xgene_msi->bitmap_lock); in xgene_msi_init_allocator()
280 xgene_msi->msi_groups = kcalloc(NR_HW_IRQS, in xgene_msi_init_allocator()
283 if (!xgene_msi->msi_groups) in xgene_msi_init_allocator()
293 struct xgene_msi *xgene_msi; in xgene_msi_isr() local
301 xgene_msi = msi_groups->msi; in xgene_msi_isr()
309 grp_select = xgene_msi_int_read(xgene_msi, msi_grp); in xgene_msi_isr()
317 msir_val = xgene_msi_ir_read(xgene_msi, msi_grp, msir_index); in xgene_msi_isr()
333 virq = irq_find_mapping(xgene_msi->inner_domain, hw_irq); in xgene_msi_isr()
347 grp_select = xgene_msi_int_read(xgene_msi, msi_grp); in xgene_msi_isr()
358 struct xgene_msi *msi = platform_get_drvdata(pdev); in xgene_msi_remove()
376 struct xgene_msi *msi = &xgene_msi_ctrl; in xgene_msi_hwirq_alloc()
423 struct xgene_msi *msi = &xgene_msi_ctrl; in xgene_msi_hwirq_free()
447 struct xgene_msi *xgene_msi; in xgene_msi_probe() local
451 xgene_msi = &xgene_msi_ctrl; in xgene_msi_probe()
453 platform_set_drvdata(pdev, xgene_msi); in xgene_msi_probe()
456 xgene_msi->msi_regs = devm_ioremap_resource(&pdev->dev, res); in xgene_msi_probe()
457 if (IS_ERR(xgene_msi->msi_regs)) { in xgene_msi_probe()
459 rc = PTR_ERR(xgene_msi->msi_regs); in xgene_msi_probe()
462 xgene_msi->msi_addr = res->start; in xgene_msi_probe()
463 xgene_msi->node = pdev->dev.of_node; in xgene_msi_probe()
464 xgene_msi->num_cpus = num_possible_cpus(); in xgene_msi_probe()
466 rc = xgene_msi_init_allocator(xgene_msi); in xgene_msi_probe()
472 rc = xgene_allocate_domains(xgene_msi); in xgene_msi_probe()
486 xgene_msi->msi_groups[irq_index].gic_irq = virt_msir; in xgene_msi_probe()
487 xgene_msi->msi_groups[irq_index].msi_grp = irq_index; in xgene_msi_probe()
488 xgene_msi->msi_groups[irq_index].msi = xgene_msi; in xgene_msi_probe()
498 msi_val = xgene_msi_ir_read(xgene_msi, irq_index, in xgene_msi_probe()
501 msi_val = xgene_msi_int_read(xgene_msi, irq_index); in xgene_msi_probe()