]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
net: hns: remove useless variable assignment and comment
authorQianqian Xie <xieqianqian@huawei.com>
Thu, 24 Mar 2016 11:08:03 +0000 (19:08 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 24 Mar 2016 18:33:06 +0000 (14:33 -0400)
The variable head in hns_nic_tx_fini_pro has read a value, but it is
obviously no use. The patch will fix it.
And the comment is nothing to do with the routine, so it has to be removed

Signed-off-by: Qianqian Xie <xieqianqian@huawei.com>
Signed-off-by: Yisen Zhuang <Yisen.Zhuang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns/hns_enet.c

index 71aa37b4b338c99e6ca7e34fc1a92527c0b0d00e..f0c9a41a74439cfe2721f5e3bbce73a8bca31646 100644 (file)
@@ -913,10 +913,7 @@ static int hns_nic_tx_poll_one(struct hns_nic_ring_data *ring_data,
 static void hns_nic_tx_fini_pro(struct hns_nic_ring_data *ring_data)
 {
        struct hnae_ring *ring = ring_data->ring;
-       int head = ring->next_to_clean;
-
-       /* for hardware bug fixed */
-       head = readl_relaxed(ring->io_base + RCB_REG_HEAD);
+       int head = readl_relaxed(ring->io_base + RCB_REG_HEAD);
 
        if (head != ring->next_to_clean) {
                ring_data->ring->q->handle->dev->ops->toggle_ring_irq(