linux-metag.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Jiang Liu <jiang.liu@linux.intel.com>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Bjorn Helgaas <bhelgaas@google.com>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Randy Dunlap <rdunlap@infradead.org>,
	Yinghai Lu <yinghai@kernel.org>, Borislav Petkov <bp@alien8.de>,
	Richard Henderson <rth@twiddle.net>,
	Ivan Kokshaysky <ink@jurassic.park.msu.ru>,
	Matt Turner <mattst88@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	Steven Miao <realmz6@gmail.com>, Tony Luck <tony.luck@intel.com>,
	Fenghua Yu <fenghua.yu@intel.com>,
	James Hogan <james.hogan@imgtec.com>,
	Ralf Baechle <ralf@linux-mips.org>,
	David Howells <dhowells@redhat.com>
Subject: Re: [Patch v2 08/14] genirq: Introduce helper function irq_data_get_affinity_mask()
Date: Wed, 20 May 2015 20:34:26 +0100	[thread overview]
Message-ID: <20150520193426.GT2067@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1432114845-24304-9-git-send-email-jiang.liu@linux.intel.com>

On Wed, May 20, 2015 at 05:40:39PM +0800, Jiang Liu wrote:
> diff --git a/arch/arm/kernel/irq.c b/arch/arm/kernel/irq.c
> index 350f188c92d2..baf8edebe26f 100644
> --- a/arch/arm/kernel/irq.c
> +++ b/arch/arm/kernel/irq.c
> @@ -140,7 +140,7 @@ int __init arch_probe_nr_irqs(void)
>  static bool migrate_one_irq(struct irq_desc *desc)
>  {
>  	struct irq_data *d = irq_desc_get_irq_data(desc);
> -	const struct cpumask *affinity = d->affinity;
> +	const struct cpumask *affinity = irq_data_get_affinity_mask(d);
>  	struct irq_chip *c;
>  	bool ret = false;
>  
> @@ -160,7 +160,7 @@ static bool migrate_one_irq(struct irq_desc *desc)
>  	if (!c->irq_set_affinity)
>  		pr_debug("IRQ%u: unable to set affinity\n", d->irq);
>  	else if (c->irq_set_affinity(d, affinity, false) == IRQ_SET_MASK_OK && ret)
> -		cpumask_copy(d->affinity, affinity);
> +		cpumask_copy(irq_data_get_affinity_mask(d), affinity);
>  
>  	return ret;
>  }

> diff --git a/include/linux/irq.h b/include/linux/irq.h
> index 43581e166298..2eb82257aaee 100644
> --- a/include/linux/irq.h
> +++ b/include/linux/irq.h
> @@ -650,6 +650,18 @@ static inline int irq_data_get_node(struct irq_data *d)
>  	return irq_common_data_get_node(d->common);
>  }
>  
> +static inline struct cpumask *irq_get_affinity_mask(int irq)
> +{
> +	struct irq_data *d = irq_get_irq_data(irq);
> +
> +	return d ? d->affinity : NULL;
> +}
> +
> +static inline struct cpumask *irq_data_get_affinity_mask(struct irq_data *d)
> +{
> +	return d->affinity;
> +}
> +
>  unsigned int arch_dynirq_lower_bound(unsigned int from);
>  
>  int __irq_alloc_descs(int irq, unsigned int from, unsigned int cnt, int node,

For the above only,

Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>

Thanks.

-- 
FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
according to speedtest.net.


  parent reply	other threads:[~2015-05-20 19:34 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1432114845-24304-1-git-send-email-jiang.liu@linux.intel.com>
2015-05-20  9:40 ` [Patch v2 08/14] genirq: Introduce helper function irq_data_get_affinity_mask() Jiang Liu
2015-05-20 14:50   ` Thomas Gleixner
2015-05-20 19:34   ` Russell King - ARM Linux [this message]
2015-05-20  9:40 ` [Patch v2 14/14] genirq: Pass irq_data to helper function __irq_set_chip_handler_name_locked() Jiang Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150520193426.GT2067@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=benh@kernel.crashing.org \
    --cc=bhelgaas@google.com \
    --cc=bp@alien8.de \
    --cc=catalin.marinas@arm.com \
    --cc=dhowells@redhat.com \
    --cc=fenghua.yu@intel.com \
    --cc=hpa@zytor.com \
    --cc=ink@jurassic.park.msu.ru \
    --cc=james.hogan@imgtec.com \
    --cc=jiang.liu@linux.intel.com \
    --cc=mattst88@gmail.com \
    --cc=mingo@redhat.com \
    --cc=ralf@linux-mips.org \
    --cc=rdunlap@infradead.org \
    --cc=realmz6@gmail.com \
    --cc=rjw@rjwysocki.net \
    --cc=rth@twiddle.net \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --cc=will.deacon@arm.com \
    --cc=yinghai@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).