From: Marek Vasut <marek.vasut@mailbox.org>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: linux-input@vger.kernel.org, Conor Dooley <conor+dt@kernel.org>,
Frank Li <Frank.Li@nxp.com>, Job Noorman <job@noorman.info>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Rob Herring <robh@kernel.org>,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-renesas-soc@vger.kernel.org
Subject: Re: [PATCH v4 3/3] Input: ili210x - add support for polling mode
Date: Tue, 20 Jan 2026 23:50:53 +0100 [thread overview]
Message-ID: <bbb7fb54-5b04-4c38-840b-8cab58eeec7b@mailbox.org> (raw)
In-Reply-To: <wv3vil4b4lgfrqt4qnzxiffnniw422xjfdiz4svkklnfrslz3g@yzqc265pj5t5>
On 1/20/26 7:31 PM, Dmitry Torokhov wrote:
> Hi Marek,
>
> On Sat, Jan 17, 2026 at 01:12:04AM +0100, Marek Vasut wrote:
>> @@ -860,16 +893,12 @@ static ssize_t ili210x_firmware_update_store(struct device *dev,
>> * the touch controller to disable the IRQs during update, so we have
>> * to do it this way here.
>> */
>> - scoped_guard(disable_irq, &client->irq) {
>> - dev_dbg(dev, "Firmware update started, firmware=%s\n", fwname);
>> -
>> - ili210x_hardware_reset(priv->reset_gpio);
>> -
>> - error = ili210x_do_firmware_update(priv, fwbuf, ac_end, df_end);
>> -
>> - ili210x_hardware_reset(priv->reset_gpio);
>> -
>> - dev_dbg(dev, "Firmware update ended, error=%i\n", error);
>> + if (client->irq > 0) {
>> + scoped_guard(disable_irq, &client->irq) {
>> + error = ili210x_firmware_update_noirq(dev, fwbuf, ac_end, df_end);
>> + }
>
> You already have a scope here, no need to establish a new one:
>
> guard(disable_irq)(&client->irq);
> error = ili210x_firmware_update_noirq(dev, fwbuf, ac_end, df_end);
This part ^ I do not understand. If there is no IRQ defined in DT, I
need to call ili210x_firmware_update_noirq() without the guard because I
cannot disable_irq() with client->irq < 0, else I need to call
ili210x_firmware_update_noirq() within the scoped_guard() to disable
IRQs to avoid spurious IRQs that would interfere with the firmware update ?
> BTW, not a fan of the "_noirq" suffix... Maybe drop it and add
> lockdep_is_held() there?
This part I understand even less, how does lockdep play into this ? The
scoped_guard() disables and enables IRQs if they are available.
next prev parent reply other threads:[~2026-01-21 2:24 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-17 0:12 [PATCH v4 1/3] dt-bindings: touchscreen: trivial-touch: Drop 'interrupts' requirement for old Ilitek Marek Vasut
2026-01-17 0:12 ` [PATCH v4 2/3] Input: ili210x - convert to dev_err_probe() Marek Vasut
2026-01-17 11:22 ` Krzysztof Kozlowski
2026-01-20 10:20 ` Geert Uytterhoeven
2026-01-20 18:25 ` Dmitry Torokhov
2026-01-17 0:12 ` [PATCH v4 3/3] Input: ili210x - add support for polling mode Marek Vasut
2026-01-18 17:19 ` Frank Li
2026-01-20 18:31 ` Dmitry Torokhov
2026-01-20 22:50 ` Marek Vasut [this message]
2026-01-21 5:23 ` Dmitry Torokhov
2026-01-21 22:42 ` Marek Vasut
2026-01-21 22:53 ` Dmitry Torokhov
2026-01-21 23:12 ` Marek Vasut
2026-01-17 11:22 ` [PATCH v4 1/3] dt-bindings: touchscreen: trivial-touch: Drop 'interrupts' requirement for old Ilitek Krzysztof Kozlowski
2026-01-17 15:33 ` Marek Vasut
2026-01-17 18:34 ` Krzysztof Kozlowski
2026-01-20 10:23 ` Geert Uytterhoeven
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=bbb7fb54-5b04-4c38-840b-8cab58eeec7b@mailbox.org \
--to=marek.vasut@mailbox.org \
--cc=Frank.Li@nxp.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=job@noorman.info \
--cc=krzk+dt@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=robh@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
all inboxes | Powered by JetHome®