Revision 54fa49ee88138756df0fcf867cb1849904710a8c authored by Vladimir Oltean on 27 December 2019, 01:11:13 UTC, committed by David S. Miller on 31 December 2019, 04:15:02 UTC
For first-generation switches (SJA1105E and SJA1105T):
- TPID means C-Tag (typically 0x8100)
- TPID2 means S-Tag (typically 0x88A8)

While for the second generation switches (SJA1105P, SJA1105Q, SJA1105R,
SJA1105S) it is the other way around:
- TPID means S-Tag (typically 0x88A8)
- TPID2 means C-Tag (typically 0x8100)

In other words, E/T tags untagged traffic with TPID, and P/Q/R/S with
TPID2.

So the patch mentioned below fixed VLAN filtering for P/Q/R/S, but broke
it for E/T.

We strive for a common code path for all switches in the family, so just
lie in the static config packing functions that TPID and TPID2 are at
swapped bit offsets than they actually are, for P/Q/R/S. This will make
both switches understand TPID to be ETH_P_8021Q and TPID2 to be
ETH_P_8021AD. The meaning from the original E/T was chosen over P/Q/R/S
because E/T is actually the one with public documentation available
(UM10944.pdf).

Fixes: f9a1a7646c0d ("net: dsa: sja1105: Reverse TPID and TPID2")
Signed-off-by: Vladimir Oltean <olteanv@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 3a323ed
History
File Mode Size
ABI
EDID
PCI
RCU
accounting
admin-guide
arm
arm64
block
bpf
cdrom
core-api
cpu-freq
crypto
dev-tools
devicetree
doc-guide
driver-api
fault-injection
fb
features
filesystems
firmware-guide
firmware_class
fpga
gpu
hid
hwmon
i2c
ia64
ide
iio
infiniband
input
isdn
kbuild
kernel-hacking
leds
livepatch
locking
m68k
maintainer
media
mic
mips
misc-devices
netlabel
networking
nios2
nvdimm
openrisc
parisc
pcmcia
power
powerpc
process
riscv
s390
scheduler
scsi
security
sh
sound
sparc
sphinx
sphinx-static
spi
target
timers
trace
translations
usb
userspace-api
virt
virtual
vm
w1
watchdog
x86
xtensa
.gitignore -rw-r--r-- 13 bytes
COPYING-logo -rw-r--r-- 563 bytes
Changes l--------- 19 bytes
CodingStyle -rw-r--r-- 48 bytes
DMA-API-HOWTO.txt -rw-r--r-- 32.8 KB
DMA-API.txt -rw-r--r-- 27.3 KB
DMA-ISA-LPC.txt -rw-r--r-- 5.1 KB
DMA-attributes.txt -rw-r--r-- 6.0 KB
IPMI.txt -rw-r--r-- 29.7 KB
IRQ-affinity.txt -rw-r--r-- 2.5 KB
IRQ-domain.txt -rw-r--r-- 10.9 KB
IRQ.txt -rw-r--r-- 994 bytes
Kconfig -rw-r--r-- 360 bytes
Makefile -rw-r--r-- 5.3 KB
SubmittingPatches -rw-r--r-- 54 bytes
asm-annotations.rst -rw-r--r-- 9.1 KB
atomic_bitops.txt -rw-r--r-- 1.5 KB
atomic_t.txt -rw-r--r-- 6.9 KB
bus-virt-phys-mapping.txt -rw-r--r-- 8.0 KB
conf.py -rw-r--r-- 20.4 KB
crc32.txt -rw-r--r-- 8.6 KB
debugging-modules.txt -rw-r--r-- 954 bytes
debugging-via-ohci1394.txt -rw-r--r-- 7.5 KB
digsig.txt -rw-r--r-- 3.0 KB
docutils.conf -rw-r--r-- 159 bytes
dontdiff -rw-r--r-- 2.6 KB
futex-requeue-pi.txt -rw-r--r-- 5.1 KB
hwspinlock.txt -rw-r--r-- 15.1 KB
index.rst -rw-r--r-- 4.0 KB
io-mapping.txt -rw-r--r-- 3.3 KB
io_ordering.txt -rw-r--r-- 2.0 KB
irqflags-tracing.txt -rw-r--r-- 2.3 KB
kobject.txt -rw-r--r-- 18.5 KB
kprobes.txt -rw-r--r-- 30.3 KB
kref.txt -rw-r--r-- 8.9 KB
logo.gif -rw-r--r-- 16.0 KB
lzo.txt -rw-r--r-- 9.1 KB
mailbox.txt -rw-r--r-- 4.4 KB
memory-barriers.txt -rw-r--r-- 114.2 KB
nommu-mmap.txt -rw-r--r-- 12.4 KB
padata.txt -rw-r--r-- 7.3 KB
percpu-rw-semaphore.txt -rw-r--r-- 1.1 KB
pi-futex.txt -rw-r--r-- 5.7 KB
preempt-locking.txt -rw-r--r-- 5.5 KB
rbtree.txt -rw-r--r-- 14.8 KB
remoteproc.txt -rw-r--r-- 12.8 KB
robust-futex-ABI.txt -rw-r--r-- 8.7 KB
robust-futexes.txt -rw-r--r-- 9.5 KB
rpmsg.txt -rw-r--r-- 13.1 KB
speculation.txt -rw-r--r-- 2.8 KB
static-keys.txt -rw-r--r-- 13.0 KB
tee.txt -rw-r--r-- 5.2 KB
this_cpu_ops.txt -rw-r--r-- 11.2 KB
unaligned-memory-access.txt -rw-r--r-- 10.4 KB
xz.txt -rw-r--r-- 5.5 KB

back to top