[<prev] [next>] [day] [month] [year] [list]
Message-ID: <1499942980-95496-1-git-send-email-wangkefeng.wang@huawei.com>
Date: Thu, 13 Jul 2017 18:49:40 +0800
From: Kefeng Wang <wangkefeng.wang@...wei.com>
To: Bjorn Helgaas <bhelgaas@...gle.com>, <linux-kernel@...r.kernel.org>
CC: David Woodhouse <dwmw@...zon.co.uk>,
Kefeng Wang <wangkefeng.wang@...wei.com>
Subject: [PATCH] pci: remove unused res in pci_resource_io
After commit dca40b186b75 ("PCI: Use BAR index in sysfs attr->private
instead of resource pointer"), no need res variable, kill it.
Signed-off-by: Kefeng Wang <wangkefeng.wang@...wei.com>
---
drivers/pci/pci-sysfs.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 2f3780b..0e43705 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -1211,11 +1211,8 @@ static ssize_t pci_resource_io(struct file *filp, struct kobject *kobj,
{
struct pci_dev *pdev = to_pci_dev(kobj_to_dev(kobj));
int bar = (unsigned long)attr->private;
- struct resource *res;
unsigned long port = off;
- res = &pdev->resource[bar];
-
port += pci_resource_start(pdev, bar);
if (port > pci_resource_end(pdev, bar))
--
1.8.3.1
Powered by blists - more mailing lists