search for: arch_restore_msi_irqs

Displaying 12 results from an estimated 12 matches for "arch_restore_msi_irqs".

2013 Aug 29
6
[PATCH 2/3 v3] Refactor MSI restore call-chain to drop unnecessary argument
...9;'s duty to restore entry->msi_attrib.masked to device, but with current code, entry->masked is used and MSI-x interrupt is masked. Before patch, restore call graph under initial domain: pci_reset_function-> pci_restore_state-> __pci_restore_msix_state-> arch_restore_msi_irqs-> xen_initdom_restore_msi_irqs-> PHYSDEVOP_restore_msi hypercall (first mask restore) msix_mask_irq(entry, entry->masked) (second mask restore) So msix_mask_irq call in initial domain call graph needs to be removed. Based on this we can...
2014 Aug 20
1
[RFC PATCH 09/11] PCI/MSI: refactor PCI MSI driver
...enabled(dev, MSI_TYPE)) { > + } else if (msi->msi_enabled) { > entry = irq_get_msi_desc(irq); > } > > @@ -133,20 +135,9 @@ static void default_restore_msi_irq(struct pci_dev *dev, > int irq) > write_msi_msg(irq, &entry->msg); > } > > -void __weak arch_restore_msi_irqs(struct pci_dev *dev) > +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) > { > - return default_restore_msi_irqs(dev); > -} > - > -static void msi_set_enable(struct pci_dev *dev, int enable) > -{ > - u16 control; > - > - pci_read_config_word(dev, dev->msi_ca...
2014 Aug 20
1
[RFC PATCH 09/11] PCI/MSI: refactor PCI MSI driver
...enabled(dev, MSI_TYPE)) { > + } else if (msi->msi_enabled) { > entry = irq_get_msi_desc(irq); > } > > @@ -133,20 +135,9 @@ static void default_restore_msi_irq(struct pci_dev *dev, > int irq) > write_msi_msg(irq, &entry->msg); > } > > -void __weak arch_restore_msi_irqs(struct pci_dev *dev) > +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) > { > - return default_restore_msi_irqs(dev); > -} > - > -static void msi_set_enable(struct pci_dev *dev, int enable) > -{ > - u16 control; > - > - pci_read_config_word(dev, dev->msi_ca...
2014 Jul 26
0
[RFC PATCH 09/11] PCI/MSI: refactor PCI MSI driver
...;irq) break; } - } else if (pci_dev_msi_enabled(dev, MSI_TYPE)) { + } else if (msi->msi_enabled) { entry = irq_get_msi_desc(irq); } @@ -133,20 +135,9 @@ static void default_restore_msi_irq(struct pci_dev *dev, int irq) write_msi_msg(irq, &entry->msg); } -void __weak arch_restore_msi_irqs(struct pci_dev *dev) +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) { - return default_restore_msi_irqs(dev); -} - -static void msi_set_enable(struct pci_dev *dev, int enable) -{ - u16 control; - - pci_read_config_word(dev, dev->msi_cap + PCI_MSI_FLAGS, &control); - control &=...
2014 Aug 20
1
[RFC PATCH 10/11] PCI/MSI: Split the generic MSI code into new file
...&entry->msg); > +} > + > +void default_restore_msi_irqs(struct msi_irqs *msi) > +{ > + struct msi_desc *entry; > + > + list_for_each_entry(entry, &msi->msi_list, list) { > + default_restore_msi_irq(msi, entry->irq); > + } > +} > + > +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) > +{ > + return default_restore_msi_irqs(msi); > +} > + > +u32 default_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) > +{ > + struct msi_irqs *msi = desc->msi; > + > + if (!msi || !msi->ops || !msi->ops->msi_mask_irq) > + re...
2014 Aug 20
1
[RFC PATCH 10/11] PCI/MSI: Split the generic MSI code into new file
...&entry->msg); > +} > + > +void default_restore_msi_irqs(struct msi_irqs *msi) > +{ > + struct msi_desc *entry; > + > + list_for_each_entry(entry, &msi->msi_list, list) { > + default_restore_msi_irq(msi, entry->irq); > + } > +} > + > +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) > +{ > + return default_restore_msi_irqs(msi); > +} > + > +u32 default_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) > +{ > + struct msi_irqs *msi = desc->msi; > + > + if (!msi || !msi->ops || !msi->ops->msi_mask_irq) > + re...
2014 Jul 26
0
[RFC PATCH 10/11] PCI/MSI: Split the generic MSI code into new file
...get_msi_desc(irq); + } + + if (entry) + write_msi_msg(irq, &entry->msg); +} + +void default_restore_msi_irqs(struct msi_irqs *msi) +{ + struct msi_desc *entry; + + list_for_each_entry(entry, &msi->msi_list, list) { + default_restore_msi_irq(msi, entry->irq); + } +} + +void __weak arch_restore_msi_irqs(struct msi_irqs *msi) +{ + return default_restore_msi_irqs(msi); +} + +u32 default_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) +{ + struct msi_irqs *msi = desc->msi; + + if (!msi || !msi->ops || !msi->ops->msi_mask_irq) + return desc->masked; + return msi->ops->msi...
2014 Jul 26
20
[RFC PATCH 00/11] Refactor MSI to support Non-PCI device
Hi all, The series is a draft of generic MSI driver that supports PCI and Non-PCI device which have MSI capability. If you're not interested it, sorry for the noise. The series is based on Linux-3.16-rc1. MSI was introduced in PCI Spec 2.2. Currently, kernel MSI driver codes are bonding with PCI device. Because MSI has a lot advantages in design. More and more non-PCI devices want to use
2014 Jul 26
20
[RFC PATCH 00/11] Refactor MSI to support Non-PCI device
Hi all, The series is a draft of generic MSI driver that supports PCI and Non-PCI device which have MSI capability. If you're not interested it, sorry for the noise. The series is based on Linux-3.16-rc1. MSI was introduced in PCI Spec 2.2. Currently, kernel MSI driver codes are bonding with PCI device. Because MSI has a lot advantages in design. More and more non-PCI devices want to use
2014 Aug 20
1
[RFC PATCH 11/11] x86/MSI: Refactor x86 MSI code
...msi_irqs *msi) > { > - x86_msi.teardown_msi_irqs(dev); > + x86_msi.teardown_msi_irqs(msi); > } > > void arch_teardown_msi_irq(unsigned int irq) > @@ -136,9 +136,9 @@ void arch_teardown_msi_irq(unsigned int irq) > x86_msi.teardown_msi_irq(irq); > } > > -void arch_restore_msi_irqs(struct pci_dev *dev) > +void arch_restore_msi_irqs(struct msi_irqs *msi) > { > - x86_msi.restore_msi_irqs(dev); > + x86_msi.restore_msi_irqs(msi); > } > u32 arch_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) > { > diff --git a/drivers/iommu/amd_iommu.c b/driver...
2014 Aug 20
1
[RFC PATCH 11/11] x86/MSI: Refactor x86 MSI code
...msi_irqs *msi) > { > - x86_msi.teardown_msi_irqs(dev); > + x86_msi.teardown_msi_irqs(msi); > } > > void arch_teardown_msi_irq(unsigned int irq) > @@ -136,9 +136,9 @@ void arch_teardown_msi_irq(unsigned int irq) > x86_msi.teardown_msi_irq(irq); > } > > -void arch_restore_msi_irqs(struct pci_dev *dev) > +void arch_restore_msi_irqs(struct msi_irqs *msi) > { > - x86_msi.restore_msi_irqs(dev); > + x86_msi.restore_msi_irqs(msi); > } > u32 arch_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) > { > diff --git a/drivers/iommu/amd_iommu.c b/driver...
2014 Jul 26
0
[RFC PATCH 11/11] x86/MSI: Refactor x86 MSI code
...uct pci_dev *dev) +void arch_teardown_msi_irqs(struct msi_irqs *msi) { - x86_msi.teardown_msi_irqs(dev); + x86_msi.teardown_msi_irqs(msi); } void arch_teardown_msi_irq(unsigned int irq) @@ -136,9 +136,9 @@ void arch_teardown_msi_irq(unsigned int irq) x86_msi.teardown_msi_irq(irq); } -void arch_restore_msi_irqs(struct pci_dev *dev) +void arch_restore_msi_irqs(struct msi_irqs *msi) { - x86_msi.restore_msi_irqs(dev); + x86_msi.restore_msi_irqs(msi); } u32 arch_msi_mask_irq(struct msi_desc *desc, u32 mask, u32 flag) { diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c index 4aec6a2..0e45c...