Commit 8484aa0c authored by Chuhong Yuan's avatar Chuhong Yuan Committed by Felipe Balbi

usb: gadget: pch_udc: 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 avatarFelipe Balbi <felipe.balbi@linux.intel.com>
parent 18425e5e
...@@ -3046,8 +3046,7 @@ static void pch_udc_remove(struct pci_dev *pdev) ...@@ -3046,8 +3046,7 @@ static void pch_udc_remove(struct pci_dev *pdev)
#ifdef CONFIG_PM_SLEEP #ifdef CONFIG_PM_SLEEP
static int pch_udc_suspend(struct device *d) static int pch_udc_suspend(struct device *d)
{ {
struct pci_dev *pdev = to_pci_dev(d); struct pch_udc_dev *dev = dev_get_drvdata(d);
struct pch_udc_dev *dev = pci_get_drvdata(pdev);
pch_udc_disable_interrupts(dev, UDC_DEVINT_MSK); pch_udc_disable_interrupts(dev, UDC_DEVINT_MSK);
pch_udc_disable_ep_interrupts(dev, UDC_EPINT_MSK_DISABLE_ALL); pch_udc_disable_ep_interrupts(dev, UDC_EPINT_MSK_DISABLE_ALL);
......
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