net: hns3: Add HNS3 IMP(Integrated Mgmt Proc) Cmd Interface Support
authorSalil <salil.mehta@huawei.com>
Wed, 2 Aug 2017 15:59:47 +0000 (16:59 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 3 Aug 2017 22:08:17 +0000 (15:08 -0700)
commit68c0a5c70614ce0adf8c6ff849534dd6d2c0ca43
tree2020b606db8775e15fc010f104ef65d85b369090
parent38caee9d3ee8b32b36912f54e19438eddd126772
net: hns3: Add HNS3 IMP(Integrated Mgmt Proc) Cmd Interface Support

This patch adds the support of IMP (Integrated Management Processor)
command interface to the HNS3 driver.

Each PF/VF has support of CQP(Command Queue Pair) ring interface.
Each CQP consis of send queue CSQ and receive queue CRQ.
There are various commands a PF/VF may support, like for Flow Table
manipulation, Device management, Packet buffer allocation, Forwarding,
VLANs config, Tunneling/Overlays etc.

This patch contains code to initialize the command queue, manage the
command queue descriptors and Rx/Tx protocol with the command processor
in the form of various commands/results and acknowledgements.

Signed-off-by: Daode Huang <huangdaode@hisilicon.com>
Signed-off-by: lipeng <lipeng321@huawei.com>
Signed-off-by: Salil Mehta <salil.mehta@huawei.com>
Signed-off-by: Yisen Zhuang <yisen.zhuang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c [new file with mode: 0644]
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.h [new file with mode: 0644]