Commit 1f5f5ea7 authored by Chuhong Yuan's avatar Chuhong Yuan Committed by Kalle Valo

qtnfmac_pcie: Use dev_get_drvdata

Instead of using to_pci_dev + pci_get_drvdata,
use dev_get_drvdata to make code simpler.
Signed-off-by: default avatarChuhong Yuan <hslester96@gmail.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent ffa4d78c
......@@ -430,7 +430,7 @@ static int qtnf_pcie_suspend(struct device *dev)
struct qtnf_pcie_bus_priv *priv;
struct qtnf_bus *bus;
bus = pci_get_drvdata(to_pci_dev(dev));
bus = dev_get_drvdata(dev);
if (!bus)
return -EFAULT;
......@@ -443,7 +443,7 @@ static int qtnf_pcie_resume(struct device *dev)
struct qtnf_pcie_bus_priv *priv;
struct qtnf_bus *bus;
bus = pci_get_drvdata(to_pci_dev(dev));
bus = dev_get_drvdata(dev);
if (!bus)
return -EFAULT;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment