]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
net: hns3: minor optimization for ring_space
authorYunsheng Lin <linyunsheng@huawei.com>
Mon, 19 Aug 2019 22:11:00 +0000 (00:11 +0200)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Tue, 17 Sep 2019 16:02:18 +0000 (18:02 +0200)
commite89c503217365c68777dca86121305377d62327c
tree425e2e1a77c2dcbc3c4b56efc04f758d63491ad2
parent31efdc2df4c613e7cd0ab7030472f82450b09469
net: hns3: minor optimization for ring_space

BugLink: https://bugs.launchpad.net/bugs/1840717
This patch optimizes the ring_space by calculating the
ring space without calling ring_dist.

Also ring_dist is only used by ring_space, so this patch
removes it when it is no longer used.

Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
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>
(cherry picked from commit 0aa3d88a9197fd7176dbaf5db769837be6afdf46)
Signed-off-by: dann frazier <dann.frazier@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Connor Kuehl <connor.kuehl@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.h