From: Gabor Juhos Date: Sun, 27 May 2012 17:09:41 +0000 (+0000) Subject: generic: rtl8367: allow to use VLANs > 31 X-Git-Tag: reboot~13783 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=466ef3017307579de1bb529097427a009d562623;p=openwrt%2Fstaging%2Fchunkeey.git generic: rtl8367: allow to use VLANs > 31 SVN-Revision: 31914 --- diff --git a/target/linux/generic/files/drivers/net/phy/rtl8367.c b/target/linux/generic/files/drivers/net/phy/rtl8367.c index d60af022a7..f4ef0c14f4 100644 --- a/target/linux/generic/files/drivers/net/phy/rtl8367.c +++ b/target/linux/generic/files/drivers/net/phy/rtl8367.c @@ -1350,6 +1350,9 @@ static int rtl8367_is_vlan_valid(struct rtl8366_smi *smi, unsigned vlan) { unsigned max = RTL8367_NUM_VLANS; + if (smi->vlan4k_enabled) + max = RTL8367_NUM_VIDS - 1; + if (vlan == 0 || vlan >= max) return 0;