MTK762x 在桥接模式下不能获取IPv6地址的问题
参考地址:https://dev.archive.openwrt.org/ticket/20453.html
1. 问题简介
Multicast IPv6 ICMP packets are dropped by built-in RT5350 switch, breaking neighbour discovery
2. 解决方案
The problem I have encountered is basically the exact same thing as described in this previous ticket: /ticket/15448.html except that it is happening in a different platform. In my case, I am using the RT5350F CPU with built in switch. The driver for the switch is the file called <openwrt-root>/target/linux/ramips/files/drivers/net/ethernet/ralink/esw_rt3052.c
I am attaching a one-line-modified version that corrects the problem by configuring one register in the CPU differently. Also, I am attaching a screen capture of the relevant datasheet section. Basically, I have set bits 18 to 24 to zeros to enable IPv6 multicast packets to make it to the CPU.
Here is the section I changed:
The following modification by Tom Rodinger
.reg_initval_fct2 = 0x00d6500c, old value
.reg_initval_fct2 = 0x000e500c, fixed value to allow IPv6 multicasts to get to the CPU
Finally, the attached Wireshark screenshot shows that after the fix, the correct neighbour advertisement response is invoked by a neighbour solicitation message.
I believe that this bug affects a number of variants from Ralink that all use this same switch driver. Hopefully you can integrate this fix into trunk.
3. 测试平台说明
软件:openwrt 1505 CC版本
硬件:MT7628NN
4. 补丁文件
--- a/drivers/net/ethernet/ralink/esw_rt3052.c
+++ b/drivers/net/ethernet/ralink/esw_rt3052.c
@@ -1353,7 +1353,9 @@ static const struct switch_dev_ops esw_o
static struct rt305x_esw_platform_data rt3050_esw_data = {
/* All ports are LAN ports. */
.vlan_config = RT305X_ESW_VLAN_CONFIG_NONE,
- .reg_initval_fct2 = 0x00d6500c,
+// The following modification by Tom Rodinger
+// .reg_initval_fct2 = 0x00d6500c, // old value
+ .reg_initval_fct2 = 0x000e500c, // fixed value to allow IPv6 multicasts to get to the CPU
/*
* ext phy base addr 31, enable port 5 polling, rx/tx clock skew 1,
* turbo mii off, rgmi 3.3v off