All of lore.kernel.org
 help / color / mirror / Atom feed
From: Miquel Raynal <miquel.raynal@bootlin.com>
To: Lee Keon-Hyeong <leegun25@proton.me>
Cc: alex.aring@gmail.com,  stefan@datenfreihafen.org,
	linux-wpan@vger.kernel.org,  netdev@vger.kernel.org
Subject: Re: [PATCH net v2 2/2] mac802154: look up children by extended address
Date: Wed, 25 Nov 2026 14:45:54 +0100	[thread overview]
Message-ID: <877bi1yqgd.fsf@bootlin.com> (raw)
In-Reply-To: <20261124085905.710751-2-leegun25@proton.me> (Lee Keon-Hyeong's message of "Tue, 24 Nov 2026 08:59:21 +0000")

On 24/11/2026 at 08:59:21 GMT, Lee Keon-Hyeong <leegun25@proton.me> wrote:

> The source address of an ASSOC REQ is always an extended address, but
> mac802154_process_association_req() builds the lookup key with the
> address mode chosen for the new child.  With alloc_addr=1 the new child
> has short-address mode, and cfg802154_pan_device_is_matching() rejects
> short-mode queries, so the lookup never matches.  Every retransmission
> is then appended as a new child, consuming an association slot and a
> short address.
>
> Look up the existing child by its extended address.
>
> With max_associations=2, two association requests from the same peer
> exhaust all available slots and prevent another peer from associating.
>
> I found this during an LLM-assisted code review and reproduced it with
> mac802154_hwsim.
>
> In a separate mac802154_hwsim test, 64 requests from the same peer
> left 64 child entries on the unpatched kernel.  With both patches
> applied, the same test left one entry.  Kernel selftests were not run.
>
> Fixes: 601f160b61b2 ("mac802154: Handle association requests from peers")
> Signed-off-by: Lee Keon-Hyeong <leegun25@proton.me>

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

  reply	other threads:[~2026-11-25 13:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-24  8:59 [PATCH net v2 1/2] mac802154: free a replaced child Lee Keon-Hyeong
2026-11-24  8:59 ` [PATCH net v2 2/2] mac802154: look up children by extended address Lee Keon-Hyeong
2026-11-25 13:45   ` Miquel Raynal [this message]
2026-11-25 13:47 ` [PATCH net v2 1/2] mac802154: free a replaced child Miquel Raynal
2026-11-26  9:46 ` Stefan Schmidt

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=877bi1yqgd.fsf@bootlin.com \
    --to=miquel.raynal@bootlin.com \
    --cc=alex.aring@gmail.com \
    --cc=leegun25@proton.me \
    --cc=linux-wpan@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stefan@datenfreihafen.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 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.