From: Paul Thomas <pthomas8589@gmail.com> To: Nicolas Ferre <nicolas.ferre@microchip.com>, Claudiu Beznea <claudiu.beznea@microchip.com>, "David S. Miller" <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org>, Russell King <linux@armlinux.org.uk>, Palmer Dabbelt <palmer@dabbelt.com>, Paul Walmsley <paul.walmsley@sifive.com>, netdev@vger.kernel.org, linux-kernel <linux-kernel@vger.kernel.org>, linux-riscv@lists.infradead.org Subject: net: macb: can macb use __napi_schedule_irqoff() instead of __napi_schedule() Date: Mon, 11 Jan 2021 14:45:54 -0500 [thread overview] Message-ID: <CAD56B7fYivPF33BhXWDPskYqNE5jRxd-sA=6+ushNXhyiCrwiQ@mail.gmail.com> (raw) Hello, recently I was doing a lot of tracing/profiling to understand an issue we were having. Anyway, during this I ran across __napi_schedule_irqoff() where the comment in dev.c says "Variant of __napi_schedule() assuming hard irqs are masked". It looks like the queue_writel(queue, IDR, bp->rx_intr_mask); call just before the __napi_schedule() call in macb_main.c is doing this hard irq masking? So could it change to be like this? --- a/drivers/net/ethernet/cadence/macb_main.c +++ b/drivers/net/ethernet/cadence/macb_main.c @@ -1616,7 +1623,7 @@ static irqreturn_t macb_interrupt(int irq, void *dev_id) if (napi_schedule_prep(&queue->napi)) { netdev_vdbg(bp->dev, "scheduling RX softirq\n"); - __napi_schedule(&queue->napi); + __napi_schedule_irqoff(&queue->napi); } } -Paul
WARNING: multiple messages have this Message-ID (diff)
From: Paul Thomas <pthomas8589@gmail.com> To: Nicolas Ferre <nicolas.ferre@microchip.com>, Claudiu Beznea <claudiu.beznea@microchip.com>, "David S. Miller" <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org>, Russell King <linux@armlinux.org.uk>, Palmer Dabbelt <palmer@dabbelt.com>, Paul Walmsley <paul.walmsley@sifive.com>, netdev@vger.kernel.org, linux-kernel <linux-kernel@vger.kernel.org>, linux-riscv@lists.infradead.org Subject: net: macb: can macb use __napi_schedule_irqoff() instead of __napi_schedule() Date: Mon, 11 Jan 2021 14:45:54 -0500 [thread overview] Message-ID: <CAD56B7fYivPF33BhXWDPskYqNE5jRxd-sA=6+ushNXhyiCrwiQ@mail.gmail.com> (raw) Hello, recently I was doing a lot of tracing/profiling to understand an issue we were having. Anyway, during this I ran across __napi_schedule_irqoff() where the comment in dev.c says "Variant of __napi_schedule() assuming hard irqs are masked". It looks like the queue_writel(queue, IDR, bp->rx_intr_mask); call just before the __napi_schedule() call in macb_main.c is doing this hard irq masking? So could it change to be like this? --- a/drivers/net/ethernet/cadence/macb_main.c +++ b/drivers/net/ethernet/cadence/macb_main.c @@ -1616,7 +1623,7 @@ static irqreturn_t macb_interrupt(int irq, void *dev_id) if (napi_schedule_prep(&queue->napi)) { netdev_vdbg(bp->dev, "scheduling RX softirq\n"); - __napi_schedule(&queue->napi); + __napi_schedule_irqoff(&queue->napi); } } -Paul _______________________________________________ linux-riscv mailing list linux-riscv@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-riscv
next reply other threads:[~2021-01-11 19:46 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-01-11 19:45 Paul Thomas [this message] 2021-01-11 19:45 ` net: macb: can macb use __napi_schedule_irqoff() instead of __napi_schedule() Paul Thomas 2021-01-11 21:35 ` Heiner Kallweit 2021-01-11 21:35 ` Heiner Kallweit 2021-01-11 22:09 ` Paul Thomas 2021-01-11 22:09 ` Paul Thomas
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='CAD56B7fYivPF33BhXWDPskYqNE5jRxd-sA=6+ushNXhyiCrwiQ@mail.gmail.com' \ --to=pthomas8589@gmail.com \ --cc=claudiu.beznea@microchip.com \ --cc=davem@davemloft.net \ --cc=kuba@kernel.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-riscv@lists.infradead.org \ --cc=linux@armlinux.org.uk \ --cc=netdev@vger.kernel.org \ --cc=nicolas.ferre@microchip.com \ --cc=palmer@dabbelt.com \ --cc=paul.walmsley@sifive.com \ /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: linkBe 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.