From bbb6bd7944cffc901d860550cbbb1f85fac70d6b Mon Sep 17 00:00:00 2001 From: Yufeng Mo Date: Tue, 5 Nov 2019 09:12:30 +0800 Subject: [PATCH] net: hns3: some cleanup for coding style driver inclusion category: bugfix bugzilla: NA CVE: NA This patch modifies some coding style problems, including the coding style of the bool type, and the judgment of 0. Feature or Bugfix:Bugfix Signed-off-by: Yufeng Mo Reviewed-by: lipeng Reviewed-by: Yunsheng Lin Signed-off-by: Yang Yingliang --- drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c index 293ba008bcef..c9ab5c1e3d81 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c +++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c @@ -2885,7 +2885,7 @@ static int hclge_get_status(struct hnae3_handle *handle) static struct hclge_vport *hclge_get_vf_vport(struct hclge_dev *hdev, int vf) { - if (pci_num_vf(hdev->pdev) == 0) { + if (!pci_num_vf(hdev->pdev)) { dev_err(&hdev->pdev->dev, "SRIOV is disabled, can not get vport(%d) info.\n", vf); return NULL; -- GitLab