OSDN Git Service

net: hns: fix for promisc mode in HNS driver
authorKejian Yan <yankejian@huawei.com>
Wed, 9 Nov 2016 18:13:47 +0000 (18:13 +0000)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Nov 2016 16:45:37 +0000 (11:45 -0500)
commit1f5fa2dd1cfa4c1356e83ff4bdd82561cad95278
treebb9c20adb0912550ad89ed206740f64c3c7c9302
parent153b1d48707eff876c1e0d72bb1e3dcd99613729
net: hns: fix for promisc mode in HNS driver

If set promisc mode when there is some traffic, The service nic will
cause system halted. We reserve the last 6 tcam entry for the 6 ports.
If promisc mode is enabled, we can config the relative tcam as fuzzy
matching and set to be valid, or set the tcam to be invalid

Signed-off-by: Kejian Yan <yankejian@huawei.com>
Reviewed-by: Yisen Zhuang <yisen.zhuang@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns/hns_dsaf_mac.c
drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c
drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.h
drivers/net/ethernet/hisilicon/hns/hns_dsaf_reg.h