From: Andrew Lunn <andrew@lunn.ch>
To: Haotian Zhang <vulab@iscas.ac.cn>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org, linux-parisc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net: winbond-840: release IRQ on alloc_ringdesc() error path
Date: Thu, 8 Oct 2026 21:17:36 +0200 [thread overview]
Message-ID: <76d4b791-4a93-4be1-9a3f-0dc1ae7684ea@lunn.ch> (raw)
In-Reply-To: <20261008162109.2678143-1-vulab@iscas.ac.cn>
On Fri, Oct 09, 2026 at 12:21:09AM +0800, Haotian Zhang wrote:
> netdev_open() registers the shared IRQ with request_irq() and then calls
> alloc_ringdesc(). When alloc_ringdesc() fails, the error path jumps to
> out_err, which only calls netif_device_attach() and returns. The IRQ
> handler stays registered forever: net/core/dev.c never calls ndo_stop
> when ndo_open fails, so netdev_close(), the only place that frees the
> IRQ, is never reached. The leaked handler is also left enabled on an
> uninitialised device.
>
> Add a separate out_err_free_irq label that releases the IRQ before
> returning the allocation error, mirroring the cleanup already used by
> the sibling de2104x driver.
Please set the subject line correctly:
https://www.kernel.org/doc/html/latest/process/maintainer-netdev.html
> Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
This obviously does not bother anybody, or it would of been fixed by
now. Please post this to net-next.
You might want to concentrate on drivers from the last decade?
Andrew
---
pw-bot: cr
prev parent reply other threads:[~2026-10-08 19:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-08 16:21 [PATCH] net: winbond-840: release IRQ on alloc_ringdesc() error path Haotian Zhang
2026-10-08 16:23 ` netdev-bot+sinfo
2026-10-08 19:17 ` Andrew Lunn [this message]
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=76d4b791-4a93-4be1-9a3f-0dc1ae7684ea@lunn.ch \
--to=andrew@lunn.ch \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-parisc@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=vulab@iscas.ac.cn \
/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