]> git.baikalelectronics.ru Git - kernel.git/commit
net: hns3: optimize the CSQ cmd error handling
authorPeng Li <lipeng321@huawei.com>
Fri, 28 Jun 2019 11:50:18 +0000 (19:50 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 28 Jun 2019 16:39:49 +0000 (09:39 -0700)
commitc880f27b7f20e46a5cdd41dfbdafbfe770372b4b
tree3e1160733dcb6f79492db15cf4fd0169a07d0c20
parentb852c5feeeb0add4a5311332c577e2977b375677
net: hns3: optimize the CSQ cmd error handling

If CMDQ ring is full, hclge_cmd_send may return directly, but IMP still
working and HW pointer changed, SW ring pointer do not match the HW
pointer. This patch update the SW pointer every time when the space is
full, so it can work normally next time if IMP and HW still working.

Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_cmd.c
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_cmd.c