net: hns3: extract macro to simplify ring stats update code
authorPeng Li <lipeng321@huawei.com>
Thu, 2 Dec 2021 08:35:55 +0000 (16:35 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Dec 2021 11:53:42 +0000 (11:53 +0000)
commite6d72f6ac2ad4965491354d74b48e35a60abf298
tree11c2987a519316df0abd1828a5cd3bcae79afce6
parentce8299b6f76f28326fedce2b4da90888bd97eab2
net: hns3: extract macro to simplify ring stats update code

As the code to update ring stats is alike for different ring stats
type, this patch extract macro to simplify ring stats update code.

Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
drivers/net/ethernet/hisilicon/hns3/hns3_enet.h