aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files/drivers/net/phy/ar8216.h
diff options
context:
space:
mode:
authorDavid Bauer <mail@david-bauer.net>2019-11-24 20:53:39 +0100
committerDavid Bauer <mail@david-bauer.net>2019-11-30 16:52:33 +0100
commitdb8345d8e43f0cc8ac8cf53fbab4037bfe33cfa3 (patch)
treed8e9766af0e40705dc9a34151584d75138e790ed /target/linux/generic/files/drivers/net/phy/ar8216.h
parentcde70954effe137fac830730105853f929e9d28a (diff)
downloadupstream-db8345d8e43f0cc8ac8cf53fbab4037bfe33cfa3.tar.gz
upstream-db8345d8e43f0cc8ac8cf53fbab4037bfe33cfa3.tar.bz2
upstream-db8345d8e43f0cc8ac8cf53fbab4037bfe33cfa3.zip
generic ar8xxx: increase VLAN table for AR83x7
The Atheros AR8327 and AR8337 have (according to their datasheet) a VLAN table with a maximum of 4096 entries. Currently, there's a hard limit of 128 VLANs, which is the same as for most other Atheros switches. Increase this limit only for the AR83x7 series and modify some shared functions to allow them to work with a variable max VLAN count. Signed-off-by: David Bauer <mail@david-bauer.net> (cherry picked from commit 3f79aaa2979793c054eae2c8b4058c8c7fccdbe7)
Diffstat (limited to 'target/linux/generic/files/drivers/net/phy/ar8216.h')
-rw-r--r--target/linux/generic/files/drivers/net/phy/ar8216.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/target/linux/generic/files/drivers/net/phy/ar8216.h b/target/linux/generic/files/drivers/net/phy/ar8216.h
index 93170d5863..bf34fdb775 100644
--- a/target/linux/generic/files/drivers/net/phy/ar8216.h
+++ b/target/linux/generic/files/drivers/net/phy/ar8216.h
@@ -31,6 +31,9 @@
/* size of the vlan table */
#define AR8X16_MAX_VLANS 128
+#define AR83X7_MAX_VLANS 4096
+#define AR8XXX_MAX_VLANS AR83X7_MAX_VLANS
+
#define AR8X16_PROBE_RETRIES 10
#define AR8X16_MAX_PORTS 8
@@ -504,8 +507,9 @@ struct ar8xxx_priv {
/* all fields below are cleared on reset */
bool vlan;
- u16 vlan_id[AR8X16_MAX_VLANS];
- u8 vlan_table[AR8X16_MAX_VLANS];
+
+ u16 vlan_id[AR8XXX_MAX_VLANS];
+ u8 vlan_table[AR8XXX_MAX_VLANS];
u8 vlan_tagged;
u16 pvid[AR8X16_MAX_PORTS];
int arl_age_time;