From: Marek Vasut <marex@denx.de>
To: Thomas Gleixner <tglx@linutronix.de>,
linux-arm-kernel@lists.infradead.org
Cc: Marc Zyngier <marc.zyngier@arm.com>,
Linus Walleij <linus.walleij@linaro.org>,
Stephen Boyd <sboyd@codeaurora.org>,
Alexandre Torgue <alexandre.torgue@st.com>,
Fabien Dessenne <fabien.dessenne@st.com>
Subject: Re: [PATCH] [RFC] genirq: Check irq_data_get_irq_chip() return value before use
Date: Thu, 14 May 2020 02:26:26 +0200 [thread overview]
Message-ID: <461c5fe4-66f6-7805-9235-310a0d95806b@denx.de> (raw)
In-Reply-To: <87a72b1rxe.fsf@nanos.tec.linutronix.de>
On 5/13/20 10:49 PM, Thomas Gleixner wrote:
> Marek,
>
> Marek Vasut <marex@denx.de> writes:
>> On 5/7/20 11:51 PM, Thomas Gleixner wrote:
>> All right, so I found out the root cause is already fixed in next, and
>> just needs to be backported to stable. I'll ping the patch author about
>> that.
>>
>> It's this patch:
>> 69269446ccbf ("mailbox: stm32-ipcc: Update wakeup management")
>>
>> I also need to revisit the regulator suspend topic next, that seems to
>> be a separate issue after all.
>>
>> Sorry for the noise.
>
> Nothing to be sorry about.
>
>> That said, do you want to take this patch to add the missing check
>> anyway or is there a reason the check is missing ?
>
> The reason is probably that chip == NULL is unexpected at least from the
> initial callers.
>
> Adding a check for robustness is a good thing, but it should be done
> slightly different.
>
> do {
> chip = irq_data_get_irq_chip(data);
> if (WARN_ON_ONCE(!chip))
> return -ENODEV;
>
> Simply because to alert the developer that this call is at the wrong
> place.
>
> Care to refresh it?
Yep, done.
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-05-14 0:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-07 15:07 [PATCH] [RFC] genirq: Check irq_data_get_irq_chip() return value before use Marek Vasut
2020-05-07 17:30 ` Thomas Gleixner
2020-05-07 18:29 ` Marek Vasut
2020-05-07 21:51 ` Thomas Gleixner
2020-05-10 14:49 ` Marek Vasut
2020-05-13 20:49 ` Thomas Gleixner
2020-05-14 0:26 ` Marek Vasut [this message]
2020-05-14 12:16 ` Alexandre Torgue
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=461c5fe4-66f6-7805-9235-310a0d95806b@denx.de \
--to=marex@denx.de \
--cc=alexandre.torgue@st.com \
--cc=fabien.dessenne@st.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=marc.zyngier@arm.com \
--cc=sboyd@codeaurora.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;
as well as URLs for NNTP newsgroup(s).