Re: [PATCH v2 14/22] MIPS/Xlp/MSI: Use MSI chip framework to configure MSI/MSI-X irq
On 2014/9/25 15:36, Thierry Reding wrote: > On Thu, Sep 25, 2014 at 11:14:24AM +0800, Yijing Wang wrote: >> Use MSI chip framework instead of arch MSI functions to configure >> MSI/MSI-X irq. So we can manage MSI/MSI-X irq in a unified framework. > > Nit: s/irq/IRQ/ in the above. > >> Signed-off-by: Yijing Wang >> --- >> arch/mips/pci/msi-xlp.c | 14 -- >> 1 files changed, 12 insertions(+), 2 deletions(-) >> >> diff --git a/arch/mips/pci/msi-xlp.c b/arch/mips/pci/msi-xlp.c >> index e469dc7..6b791ef 100644 >> --- a/arch/mips/pci/msi-xlp.c >> +++ b/arch/mips/pci/msi-xlp.c >> @@ -245,7 +245,7 @@ static struct irq_chip xlp_msix_chip = { >> .irq_unmask = unmask_msi_irq, >> }; >> >> -void arch_teardown_msi_irq(unsigned int irq) >> +void xlp_teardown_msi_irq(unsigned int irq) > > Should this not be static now as well? Yes, Will update. > > Thierry > -- Thanks! Yijing ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev
Re: [PATCH v2 14/22] MIPS/Xlp/MSI: Use MSI chip framework to configure MSI/MSI-X irq
On Thu, Sep 25, 2014 at 11:14:24AM +0800, Yijing Wang wrote: > Use MSI chip framework instead of arch MSI functions to configure > MSI/MSI-X irq. So we can manage MSI/MSI-X irq in a unified framework. Nit: s/irq/IRQ/ in the above. > Signed-off-by: Yijing Wang > --- > arch/mips/pci/msi-xlp.c | 14 -- > 1 files changed, 12 insertions(+), 2 deletions(-) > > diff --git a/arch/mips/pci/msi-xlp.c b/arch/mips/pci/msi-xlp.c > index e469dc7..6b791ef 100644 > --- a/arch/mips/pci/msi-xlp.c > +++ b/arch/mips/pci/msi-xlp.c > @@ -245,7 +245,7 @@ static struct irq_chip xlp_msix_chip = { > .irq_unmask = unmask_msi_irq, > }; > > -void arch_teardown_msi_irq(unsigned int irq) > +void xlp_teardown_msi_irq(unsigned int irq) Should this not be static now as well? Thierry pgphFbTjhVGSy.pgp Description: PGP signature ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev
[PATCH v2 14/22] MIPS/Xlp/MSI: Use MSI chip framework to configure MSI/MSI-X irq
Use MSI chip framework instead of arch MSI functions to configure MSI/MSI-X irq. So we can manage MSI/MSI-X irq in a unified framework. Signed-off-by: Yijing Wang --- arch/mips/pci/msi-xlp.c | 14 -- 1 files changed, 12 insertions(+), 2 deletions(-) diff --git a/arch/mips/pci/msi-xlp.c b/arch/mips/pci/msi-xlp.c index e469dc7..6b791ef 100644 --- a/arch/mips/pci/msi-xlp.c +++ b/arch/mips/pci/msi-xlp.c @@ -245,7 +245,7 @@ static struct irq_chip xlp_msix_chip = { .irq_unmask = unmask_msi_irq, }; -void arch_teardown_msi_irq(unsigned int irq) +void xlp_teardown_msi_irq(unsigned int irq) { } @@ -450,7 +450,7 @@ static int xlp_setup_msix(uint64_t lnkbase, int node, int link, return 0; } -int arch_setup_msi_irq(struct pci_dev *dev, struct msi_desc *desc) +static int xlp_setup_msi_irq(struct pci_dev *dev, struct msi_desc *desc) { struct pci_dev *lnkdev; uint64_t lnkbase; @@ -472,6 +472,16 @@ int arch_setup_msi_irq(struct pci_dev *dev, struct msi_desc *desc) return xlp_setup_msi(lnkbase, node, link, desc); } +static struct msi_chip xlp_chip = { + .setup_irq = xlp_setup_msi_irq, + .teardown_irq = xlp_teardown_msi_irq, +}; + +struct msi_chip *arch_find_msi_chip(struct pci_dev *dev) +{ + return &xlp_chip; +} + void __init xlp_init_node_msi_irqs(int node, int link) { struct nlm_soc_info *nodep; -- 1.7.1 ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev