]> git.baikalelectronics.ru Git - kernel.git/commit
net: hns3: add support for extended promiscuous command
authorGuojia Liao <liaoguojia@huawei.com>
Sun, 6 Dec 2020 04:06:13 +0000 (12:06 +0800)
committerJakub Kicinski <kuba@kernel.org>
Tue, 8 Dec 2020 19:58:52 +0000 (11:58 -0800)
commit3baecb00c5fdf3c62918b8c748b90bcafa89d877
treefddbe07c7ce5931d3a23df5dc425851832600970
parent1d88caca86fd05806fda994bf2f262e88ff6e4b1
net: hns3: add support for extended promiscuous command

For DEVICE_VERSION_V2, the hardware supports enable tx and rx
promiscuous separately. But tx or rx promiscuous is active for
unicast, multicast and broadcast promiscuous simultaneously.
To support traffics between functions belong to the same port,
we always enable tx promiscuous for broadcast promiscuous, so
tx promiscuous for unicast and multicast promiscuous is also
enabled.

For DEVICE_VERSION_V3, the hardware decouples the above
relationship. Tx unicast promiscuous, rx unicast promiscuous,
tx multicast promiscuous, rx multicast promiscuous, tx broadcast
promiscuous and rx broadcast promiscuous can be enabled separately.

So add support for the new promiscuous command.

Signed-off-by: Guojia Liao <liaoguojia@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c