Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1263310

Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device driver

From Keith Busch <keith.busch@intel.com>
Newsgroups linux.kernel
Subject Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device driver
Date 2015-11-05 16:00 +0100
Message-ID <qrub9-81X-33@gated-at.bofh.it> (permalink)
References (3 earlier) <qqxup-3IW-11@gated-at.bofh.it> <qqIg9-2a9-3@gated-at.bofh.it> <qr7xU-1HX-19@gated-at.bofh.it> <qr80V-28m-5@gated-at.bofh.it> <qrmng-30y-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Nov 05, 2015 at 02:35:31PM +0800, Jiang Liu wrote:
> Hi Keith,
> 	Could you please try the attached patch?
> Thanks!
> Gerry

Thanks! I anticipated this and tested the same thing yesterday, and it
is successful.

I'll apply to the series and send a new revision hopefully today. Not
requiring a parent simplifies the driver since we don't define
irq_domain_ops now, and the functionality they provided moves to the
irq_chip.



> From: Liu Jiang <jiang.liu@linux.intel.com>
> Date: Thu, 5 Nov 2015 11:25:07 +0800
> Subject: [PATCH] msi: Relax msi_domain_alloc() to support parentless MSI
>  irqdomains
> 
> Previously msi_domain_alloc() assumes MSI irqdomains always have parent
> irqdomains, but that's not true for the new Intel VMD devices. So relax
> msi_domain_alloc() to support parentless MSI irqdomains.
> 
> Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
> Signed-off-by: Liu Jiang <jiang.liu@linux.intel.com>
> ---
>  kernel/irq/msi.c |    8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/kernel/irq/msi.c b/kernel/irq/msi.c
> index 7e6512b9dc1f..e4d3d707efff 100644
> --- a/kernel/irq/msi.c
> +++ b/kernel/irq/msi.c
> @@ -109,9 +109,11 @@ static int msi_domain_alloc(struct irq_domain *domain, unsigned int virq,
>  	if (irq_find_mapping(domain, hwirq) > 0)
>  		return -EEXIST;
>  
> -	ret = irq_domain_alloc_irqs_parent(domain, virq, nr_irqs, arg);
> -	if (ret < 0)
> -		return ret;
> +	if (domain->parent) {
> +		ret = irq_domain_alloc_irqs_parent(domain, virq, nr_irqs, arg);
> +		if (ret < 0)
> +			return ret;
> +	}
>  
>  	for (i = 0; i < nr_irqs; i++) {
>  		ret = ops->msi_init(domain, info, virq + i, hwirq + i, arg);
> -- 
> 1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Thomas Gleixner <tglx@linutronix.de> - 2015-11-02 19:40 +0100
  Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Keith Busch <keith.busch@intel.com> - 2015-11-03 01:20 +0100
    Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Thomas Gleixner <tglx@linutronix.de> - 2015-11-03 12:50 +0100
      Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Keith Busch <keith.busch@intel.com> - 2015-11-04 15:50 +0100
        Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Thomas Gleixner <tglx@linutronix.de> - 2015-11-04 16:20 +0100
          Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Jiang Liu <jiang.liu@linux.intel.com> - 2015-11-05 07:40 +0100
            Re: [RFC PATCHv3 3/4] x86/pci: Initial commit for new VMD device  driver Keith Busch <keith.busch@intel.com> - 2015-11-05 16:00 +0100

csiph-web