Re: [PATCH net-next 4/7] net: dsa: b53: fix CPU port unicast ARL entries for BCM5325/65

From: Jonas Gorski

Date: Wed Nov 26 2025 - 04:08:01 EST


On Tue, Nov 25, 2025 at 9:42 PM Vladimir Oltean <olteanv@xxxxxxxxx> wrote:
>
> On Tue, Nov 25, 2025 at 08:51:47AM +0100, Jonas Gorski wrote:
> > On BCM5325 and BCM5365, unicast ARL entries use 8 as the value for the
> > CPU port, so we need to translate it to/from 5 as used for the CPU port
> > at most other places.
> > + ent->port = (mac_vid >> ARLTBL_DATA_PORT_ID_S_25) &
> > + ARLTBL_DATA_PORT_ID_MASK_25;
> > + if (!is_multicast_ether_addr(ent->mac) && ent->port == B53_CPU_PORT)
> > + ent->port = B53_CPU_PORT_25;
>
> Why not use is_unicast_ether_addr() to have a more clear correlation
> between the commit message and the code?

There is a very simple explanation for that: I didn't know it existed.
Will change it for v2.

Thanks for the review,
Jonas