Re: [PATCH net 1/5] net: dsa: b53: initialize the jumbo frame size register offset

From: Jonas Gorski

Date: Wed Oct 28 2026 - 05:13:07 EST


On Tue, Oct 27, 2026 at 9:22 PM Florian Fainelli
<florian.fainelli@xxxxxxxxxxxx> wrote:
>
> The chip data specifies both the jumbo port mask and frame size register
> offsets, but b53_switch_init() only copies the former into the device.
> Since the device is zero-initialized, b53_set_jumbo() writes the frame
> size to offset zero instead of the chip-specific size register at 0x05
> or 0x08.

That offset is reserved, so (hopefully) was effectively just a NOP.

Which reminds me that I still don't really know what this register is
good for. The (bcm53115) datasheet says it's used when jumbo support
is disabled(?) to determine max good frame size for MIBs, but also
that it controls up to which lengths frames are admitted, then dropped
(and only allows the values 1518 and 2000).

I tried writing various values to it, and never managed to make it do
anything; neither did the switch start dropping frames longer than
that, nor did I see any effect on the MIB counters ... .

> Copy jumbo_size_reg from the chip data along with jumbo_pm_reg so frame
> size updates reach the intended register.
>
> Fixes: 967dd82ffc52 ("net: dsa: b53: Add support for Broadcom RoboSwitch")
> Signed-off-by: Florian Fainelli <florian.fainelli@xxxxxxxxxxxx>

Reviewed-by: Jonas Gorski <jonas.gorski@xxxxxxxxx>

> ---
> drivers/net/dsa/b53/b53_common.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/dsa/b53/b53_common.c b/drivers/net/dsa/b53/b53_common.c
> index 0880310c9ce3..559d4b360c82 100644
> --- a/drivers/net/dsa/b53/b53_common.c
> +++ b/drivers/net/dsa/b53/b53_common.c
> @@ -3109,6 +3109,7 @@ static int b53_switch_init(struct b53_device *dev)
> dev->vta_regs[1] = chip->vta_regs[1];
> dev->vta_regs[2] = chip->vta_regs[2];
> dev->jumbo_pm_reg = chip->jumbo_pm_reg;
> + dev->jumbo_size_reg = chip->jumbo_size_reg;
> dev->imp_port = chip->imp_port;
> dev->num_vlans = chip->vlans;
> dev->num_arl_bins = chip->arl_bins;
> --
> 2.53.0
>