mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marc Zyngier <maz@kernel.org>
To: "Sverdlin,
	Alexander (Nokia - DE/Ulm)" <alexander.sverdlin@nokia.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Grant Likely <grant.likely@secretlab.ca>
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Jon Hunter <jonathanh@nvidia.com>,
	"Glavinic-Pecotic,
	Matija (EXT - DE/Ulm)"  <matija.glavinic-pecotic.ext@nokia.com>,
	"Adamski,
	Krzysztof (Nokia - PL/Wroclaw)"  <krzysztof.adamski@nokia.com>,
	"stable@vger.kernel.org" <stable@vger.kernel.org>
Subject: Re: [PATCH 3/3] genirq/irqdomain: Detect type race in irq_create_fwspec_mapping()
Date: Fri, 20 Sep 2019 17:07:26 +0100	[thread overview]
Message-ID: <e86441c4-9ce2-b0f2-f8ca-2823497b4d6d@kernel.org> (raw)
In-Reply-To: <20190912094343.5480-4-alexander.sverdlin@nokia.com>

On 12/09/2019 10:44, Sverdlin, Alexander (Nokia - DE/Ulm) wrote:
> From: Alexander Sverdlin <alexander.sverdlin@nokia.com>
> 
> irq_create_fwspec_mapping() can race with itself during IRQ trigger type
> configuration. Possible scenarios include:
> 
> - Mapping exists, two irq_create_fwspec_mapping() running in parallel do
>   not detect type mismatch, IRQ remains configured with one of the
>   different trigger types randomly
> - Second call to irq_create_fwspec_mapping() sees existing mapping just
>   created by first call, but earlier irqd_set_trigger_type() call races
>   with later irqd_set_trigger_type() => totally undetected, IRQ type
>   is being set randomly to either one or another type

Is that an actual thing? Frankly, the scenario you're describing here
seems to carry the hallmarks of a completely broken system. Can you
point at a system supported in mainline that would behave as such?

Thanks,

	M.
-- 
Jazz is not dead, it just smells funny...

  reply	other threads:[~2019-09-20 16:07 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-12  9:44 [PATCH 0/3] Fix irq_domain vs. irq user race Sverdlin, Alexander (Nokia - DE/Ulm)
2019-09-12  9:44 ` [PATCH 1/3] genirq/irqdomain: Check for existing mapping in irq_domain_associate() Sverdlin, Alexander (Nokia - DE/Ulm)
2019-09-20 15:37   ` Marc Zyngier
2019-09-12  9:44 ` [PATCH 2/3] genirq/irqdomain: Re-check mapping after associate in irq_create_mapping() Sverdlin, Alexander (Nokia - DE/Ulm)
2019-09-20 15:52   ` Marc Zyngier
2019-09-20 16:06     ` Sverdlin, Alexander (Nokia - DE/Ulm)
2020-01-08 15:07     ` Alexander Sverdlin
2019-09-12  9:44 ` [PATCH 3/3] genirq/irqdomain: Detect type race in irq_create_fwspec_mapping() Sverdlin, Alexander (Nokia - DE/Ulm)
2019-09-20 16:07   ` Marc Zyngier [this message]
2019-09-20 16:14     ` Sverdlin, Alexander (Nokia - DE/Ulm)

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=e86441c4-9ce2-b0f2-f8ca-2823497b4d6d@kernel.org \
    --to=maz@kernel.org \
    --cc=alexander.sverdlin@nokia.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=grant.likely@secretlab.ca \
    --cc=jonathanh@nvidia.com \
    --cc=krzysztof.adamski@nokia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matija.glavinic-pecotic.ext@nokia.com \
    --cc=stable@vger.kernel.org \
    --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

all inboxes | Powered by JetHome®