Linux IEEE 802.15.4 and 6LoWPAN development
 help / color / mirror / Atom feed
From: Miquel Raynal <miquel.raynal@bootlin.com>
To: Wentao Liang <vulab@iscas.ac.cn>
Cc: Alexander Aring <alex.aring@gmail.com>,
	 Stefan Schmidt <stefan@datenfreihafen.org>,
	 "David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@kernel.org>,
	 Jakub Kicinski <kuba@kernel.org>,
	Paolo Abeni <pabeni@redhat.com>,  Simon Horman <horms@kernel.org>,
	linux-wpan@vger.kernel.org,  netdev@vger.kernel.org
Subject: Re: [PATCH] ieee802154: drop the extra phy reference in del_iface
Date: Mon, 16 Nov 2026 16:04:42 +0100	[thread overview]
Message-ID: <87ld6srf5h.fsf@bootlin.com> (raw)
In-Reply-To: <20261104022809.1484165-1-vulab@iscas.ac.cn> (Wentao Liang's message of "Wed, 4 Nov 2026 02:28:09 +0000")

On 04/11/2026 at 02:28:09 GMT, Wentao Liang <vulab@iscas.ac.cn> wrote:

> ieee802154_del_iface() takes a reference on the phy of the interface and
> then looks up the phy named by IEEE802154_ATTR_PHY_NAME, which takes
> another reference. When the optional attribute names the phy of the
> interface being deleted, phy and phy2 are the same device, the lookup
> reference is not dropped and the function later puts the phy only once.
> Deleting an interface while passing its own phy name therefore leaks a
> wpan_phy reference.
>
> Put the lookup reference in the matching case as well, leaving only the
> reference taken from the interface.
>
> Fixes: bb1cafb8fc41 ("ieee802154: add support for creation/removal of logic interfaces")
> Cc: stable@vger.kernel.org
> Assisted-by: DeepSeek-V4.1-Flash and OpenAI Codex
> Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>

Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>

      parent reply	other threads:[~2026-11-16 15:04 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-04  2:28 [PATCH] ieee802154: drop the extra phy reference in del_iface Wentao Liang
2026-11-04  2:32 ` netdev-bot+sinfo
2026-11-04  7:41 ` Krzysztof Kozlowski
2026-11-16 15:04 ` Miquel Raynal [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=87ld6srf5h.fsf@bootlin.com \
    --to=miquel.raynal@bootlin.com \
    --cc=alex.aring@gmail.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@kernel.org \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-wpan@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=stefan@datenfreihafen.org \
    --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