From: Jisheng Zhang <jszhang@marvell.com>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: <jason@lakedaemon.net>, <linux@arm.linux.org.uk>,
<linux-kernel@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH v3 2/2] irqchip: dw-apb-ictl: add irq_set_affinity support
Date: Mon, 6 Jul 2015 21:10:35 +0800 [thread overview]
Message-ID: <20150706211035.6676916f@xhacker> (raw)
In-Reply-To: <alpine.DEB.2.11.1507061228060.3916@nanos>
On Mon, 6 Jul 2015 12:30:01 +0200
Thomas Gleixner <tglx@linutronix.de> wrote:
> On Mon, 6 Jul 2015, Jisheng Zhang wrote:
> > +static int dw_apb_ictl_set_affinity(struct irq_data *d,
> > + const struct cpumask *mask_val,
> > + bool force)
> > +{
> > + struct irq_chip_generic *gc = irq_data_get_irq_chip_data(d);
> > + struct dw_apb_ictl_priv *priv = gc->private;
> > + struct irq_chip *chip = irq_get_chip(priv->parent_irq);
> > + struct irq_data *data = irq_get_irq_data(priv->parent_irq);
> > +
> > + if (chip && chip->irq_set_affinity)
> > + return chip->irq_set_affinity(data, mask_val, force);
>
> This is wrong as it lacks proper locking of the parent irq. That needs
> to be solved at the core code level in a clean way.
Is it acceptable to call irq_set_affinity() or irq_force_affinity() as the
following:
if (force)
return irq_force_affinity(priv->parent_irq, mask_val);
else
return irq_set_affinity(priv->parent_irq, mask_val);
Thanks,
Jisheng
next prev parent reply other threads:[~2015-07-06 13:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-06 4:15 [PATCH v3 0/2] irqchip: dw-apb-ictl: add irq_set_affinity support Jisheng Zhang
2015-07-06 4:15 ` [PATCH v3 1/2] irqchip: dw-apb-ictl: add private data structure Jisheng Zhang
2015-07-06 4:15 ` [PATCH v3 2/2] irqchip: dw-apb-ictl: add irq_set_affinity support Jisheng Zhang
2015-07-06 10:30 ` Thomas Gleixner
2015-07-06 13:10 ` Jisheng Zhang [this message]
2015-07-06 13:51 ` Thomas Gleixner
2015-07-06 14:17 ` Jisheng Zhang
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=20150706211035.6676916f@xhacker \
--to=jszhang@marvell.com \
--cc=jason@lakedaemon.net \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=tglx@linutronix.de \
/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