]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: mv88e6xxx: protect FID registers access
authorVivien Didelot <vivien.didelot@savoirfairelinux.com>
Thu, 31 Mar 2016 20:53:42 +0000 (16:53 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 5 Apr 2016 01:31:35 +0000 (21:31 -0400)
commitc3bf29faf9fd9d9d8e0fdb838a4897e99d0b7de4
tree72758b0cfcea34110e0f2bc7e4154cd777ae56ad
parent063dd4feb3015fb10676327d0296a5faafd361ba
net: dsa: mv88e6xxx: protect FID registers access

Only switch families with 4096 address databases have dedicated FID
registers for ATU and VTU operations.

Factorize the access to the GLOBAL_ATU_FID register and introduce a
mv88e6xxx_has_fid_reg() helper function to protect the access to
GLOBAL_ATU_FID and GLOBAL_VTU_FID.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/mv88e6xxx.c