From: sashiko-bot@kernel.org
To: "Selvamani Rajagopal via B4 Relay"
<devnull+Selvamani.Rajagopal.onsemi.com@kernel.org>
Cc: devicetree@vger.kernel.org, robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH net v3 1/2] net: ethernet: oa_tc6: Interrupt is active low, level triggered.
Date: Tue, 02 Jun 2026 16:07:41 +0000 [thread overview]
Message-ID: <20260602160741.7E27D1F00893@smtp.kernel.org> (raw)
In-Reply-To: <20260601-level-trigger-v3-1-da73e7010532@onsemi.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] IRQ storm and starvation caused by level-triggered interrupt without IRQF_ONESHOT or manual masking.
--
commit 3908a29ac2b1392995dbf0f4228af86bbddb0261
Author: Selvamani Rajagopal <Selvamani.Rajagopal@onsemi.com>
net: ethernet: oa_tc6: Interrupt is active low, level triggered.
According OPEN Alliance 10BASET1x MAC-PHY Serial Interface
specification, interrupt is active low, level triggered.
> diff --git a/drivers/net/ethernet/oa_tc6.c b/drivers/net/ethernet/oa_tc6.c
> index 91a906a7918a2..667faf1554053 100644
> --- a/drivers/net/ethernet/oa_tc6.c
> +++ b/drivers/net/ethernet/oa_tc6.c
> @@ -1323,7 +1323,7 @@ struct oa_tc6 *oa_tc6_init(struct spi_device *spi, struct net_device *netdev)
> sched_set_fifo(tc6->spi_thread);
>
> ret = devm_request_irq(&tc6->spi->dev, tc6->spi->irq, oa_tc6_macphy_isr,
> - IRQF_TRIGGER_FALLING, dev_name(&tc6->spi->dev),
> + IRQF_TRIGGER_LOW, dev_name(&tc6->spi->dev),
> tc6);
[Severity: High]
Does changing this to a level-triggered interrupt cause an IRQ storm?
Looking at the primary hardirq handler:
drivers/net/ethernet/oa_tc6.c:oa_tc6_macphy_isr() {
...
tc6->int_flag = true;
wake_up_interruptible(&tc6->spi_wq);
return IRQ_HANDLED;
}
Since the handler returns IRQ_HANDLED without clearing the hardware condition
on the device, the IRQ core will immediately unmask the line. Because the
MAC-PHY is still holding the line low (waiting for the SPI kthread to run and
clear it), the interrupt will instantly re-trigger.
Could this starve the awakened spi_wq kthread and lead to a CPU lockup or the
kernel permanently disabling the interrupt line? Should this use a threaded
IRQ with IRQF_ONESHOT, or explicitly disable the IRQ in the handler until the
kthread completes the SPI transfer?
> if (ret) {
> dev_err(&tc6->spi->dev, "Failed to request macphy isr %d\n",
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260601-level-trigger-v3-0-da73e7010532@onsemi.com?part=1
next prev parent reply other threads:[~2026-06-02 16:07 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-01 16:07 [PATCH net v3 0/2] Resubmitting with cover-letter and threaded patch series Selvamani Rajagopal via B4 Relay
2026-06-01 16:07 ` Selvamani Rajagopal
2026-06-01 16:07 ` [PATCH net v3 1/2] net: ethernet: oa_tc6: Interrupt is active low, level triggered Selvamani Rajagopal via B4 Relay
2026-06-01 16:07 ` Selvamani Rajagopal
2026-06-02 16:07 ` sashiko-bot [this message]
2026-06-01 16:07 ` [PATCH net v3 2/2] dt-bindings: net: updated interrupt type to be " Selvamani Rajagopal via B4 Relay
2026-06-01 16:07 ` Selvamani Rajagopal
2026-06-02 16:07 ` sashiko-bot
2026-06-02 16:42 ` Conor Dooley
2026-06-02 17:36 ` Selvamani Rajagopal
2026-06-03 15:08 ` Conor Dooley
2026-06-04 6:29 ` Parthiban.Veerasooran
2026-06-04 7:08 ` Nicolai Buchwitz
2026-06-04 15:21 ` Selvamani Rajagopal
2026-06-04 16:36 ` Conor Dooley
2026-06-04 17:00 ` Andrew Lunn
2026-06-04 13:19 ` [PATCH net v3 0/2] Resubmitting with cover-letter and threaded patch series Paolo Abeni
2026-06-04 14:51 ` Selvamani Rajagopal
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=20260602160741.7E27D1F00893@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=devnull+Selvamani.Rajagopal.onsemi.com@kernel.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.