|
发表于 2012-2-9 22:19:40
|
显示全部楼层
本帖最后由 chmjiong 于 2012-2-10 10:14 编辑
已经查清楚为什么虚拟出的wan失效了,原来是openwrt的驱动只支持16个vlan,哪怕是truke版也没用,把wan的vlan改成2,立刻就连上了
现在要修改ar8216的驱动了,头大了啊
更新:仔细研究了一下ar8216的源代码,有这样一行东西:
298 static struct switch_attr ar8216_globals[] = {
299 {
300 .type = SWITCH_TYPE_INT,
301 .name = "enable_vlan",
302 .description = "Enable VLAN mode",
303 .set = ar8216_set_vlan,
304 .get = ar8216_get_vlan,
305 .max = 1
306 },
307 };
308
309 static struct switch_attr ar8216_port[] = {
310 };
311
312 static struct switch_attr ar8216_vlan[] = {
313 {
314 .type = SWITCH_TYPE_INT,
315 .name = "pvid",
316 .description = "VLAN ID",
317 .set = ar8216_set_vid,
318 .get = ar8216_get_vid,
319 .max = 4094,
320 },
那么是不是应该用“option pvid 1”来配置vlan,以启用硬件vlan标识呢???
源代码里显示,10.03版的驱动支持128个vlan,truke版的更是可以支持到255 |
|