OSDN Git Service

net: hns3: optimize local variable initialization
authorGuangbin Huang <huangguangbin2@huawei.com>
Thu, 31 Oct 2019 11:23:21 +0000 (19:23 +0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 31 Oct 2019 19:03:23 +0000 (12:03 -0700)
commit0bfdf2868cd511e2ceff983fe66a508b0d03d8c5
tree8e4df658fdf2bc5ebe403fbb73adbaab11ae891f
parente4b806edfabd43853d365a9fcaf238cf10c3c4ab
net: hns3: optimize local variable initialization

The variable tx_ring is unnecessary to be initialized as it will be set
before used, and the variable rst_cnt is better to be initialized when
declaration for simplification.

Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c