Lines Matching refs:msi
171 struct nwl_msi msi; member
338 struct nwl_msi *msi = &pcie->msi; in nwl_pcie_handle_msi_irq() local
345 generic_handle_domain_irq(msi->dev_domain, bit); in nwl_pcie_handle_msi_irq()
463 struct nwl_msi *msi = &pcie->msi; in nwl_irq_domain_alloc() local
467 mutex_lock(&msi->lock); in nwl_irq_domain_alloc()
468 bit = bitmap_find_free_region(msi->bitmap, INT_PCI_MSI_NR, in nwl_irq_domain_alloc()
471 mutex_unlock(&msi->lock); in nwl_irq_domain_alloc()
480 mutex_unlock(&msi->lock); in nwl_irq_domain_alloc()
489 struct nwl_msi *msi = &pcie->msi; in nwl_irq_domain_free() local
491 mutex_lock(&msi->lock); in nwl_irq_domain_free()
492 bitmap_release_region(msi->bitmap, data->hwirq, in nwl_irq_domain_free()
494 mutex_unlock(&msi->lock); in nwl_irq_domain_free()
507 struct nwl_msi *msi = &pcie->msi; in nwl_pcie_init_msi_irq_domain() local
509 msi->dev_domain = irq_domain_add_linear(NULL, INT_PCI_MSI_NR, in nwl_pcie_init_msi_irq_domain()
511 if (!msi->dev_domain) { in nwl_pcie_init_msi_irq_domain()
515 msi->msi_domain = pci_msi_create_irq_domain(fwnode, in nwl_pcie_init_msi_irq_domain()
517 msi->dev_domain); in nwl_pcie_init_msi_irq_domain()
518 if (!msi->msi_domain) { in nwl_pcie_init_msi_irq_domain()
520 irq_domain_remove(msi->dev_domain); in nwl_pcie_init_msi_irq_domain()
558 struct nwl_msi *msi = &pcie->msi; in nwl_pcie_enable_msi() local
562 mutex_init(&msi->lock); in nwl_pcie_enable_msi()
565 msi->irq_msi1 = platform_get_irq_byname(pdev, "msi1"); in nwl_pcie_enable_msi()
566 if (msi->irq_msi1 < 0) in nwl_pcie_enable_msi()
569 irq_set_chained_handler_and_data(msi->irq_msi1, in nwl_pcie_enable_msi()
573 msi->irq_msi0 = platform_get_irq_byname(pdev, "msi0"); in nwl_pcie_enable_msi()
574 if (msi->irq_msi0 < 0) in nwl_pcie_enable_msi()
577 irq_set_chained_handler_and_data(msi->irq_msi0, in nwl_pcie_enable_msi()