diff options
author | Vladimir Oltean <vladimir.oltean@nxp.com> | 2021-05-24 12:25:22 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-05-24 13:20:24 -0700 |
commit | ba61cf167cb77e54c1ec5adb7aa49a22ab3c9b28 (patch) | |
tree | c6affbecd561407a3f50ac487ca9f0f6cd0b2151 /lib/test_min_heap.c | |
parent | net: hso: fix control-request directions (diff) | |
download | linux-dev-ba61cf167cb77e54c1ec5adb7aa49a22ab3c9b28.tar.xz linux-dev-ba61cf167cb77e54c1ec5adb7aa49a22ab3c9b28.zip |
net: dsa: sja1105: fix VL lookup command packing for P/Q/R/S
At the beginning of the sja1105_dynamic_config.c file there is a diagram
of the dynamic config interface layout:
packed_buf
|
V
+-----------------------------------------+------------------+
| ENTRY BUFFER | COMMAND BUFFER |
+-----------------------------------------+------------------+
<----------------------- packed_size ------------------------>
So in order to pack/unpack the command bits into the buffer,
sja1105_vl_lookup_cmd_packing must first advance the buffer pointer by
the length of the entry. This is similar to what the other *cmd_packing
functions do.
This bug exists because the command packing function for P/Q/R/S was
copied from the E/T generation, and on E/T, the command was actually
embedded within the entry buffer itself.
Fixes: 94f94d4acfb2 ("net: dsa: sja1105: add static tables for virtual links")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'lib/test_min_heap.c')
0 files changed, 0 insertions, 0 deletions