diff options
author | Hans de Goede <hdegoede@redhat.com> | 2016-06-18 05:31:33 -0400 |
---|---|---|
committer | Kishon Vijay Abraham I <kishon@ti.com> | 2016-06-22 02:03:46 -0400 |
commit | 04e59a0211ff012ba60c00baca673482570784e9 (patch) | |
tree | 94838caee6dbd50b1393b321e05e4497810dd285 | |
parent | 6c081ff6fd5abd621797570be43d5e3c6acfcd58 (diff) |
phy-sun4i-usb: Fix irq free conditions to match request conditions
commit 5cf700ac9d50 ("phy: phy-sun4i-usb: Fix optional gpios failing
probe")
changed the condition under which irqs are requested, but omitted matching
changes to sun4i_usb_phy_remove(). This commit fixes this.
Fixes: 5cf700ac9d50 ("phy: phy-sun4i-usb: Fix optional gpios failing probe")
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
-rw-r--r-- | drivers/phy/phy-sun4i-usb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/phy/phy-sun4i-usb.c b/drivers/phy/phy-sun4i-usb.c index 739029430dda..de3101fbbf40 100644 --- a/drivers/phy/phy-sun4i-usb.c +++ b/drivers/phy/phy-sun4i-usb.c | |||
@@ -514,9 +514,9 @@ static int sun4i_usb_phy_remove(struct platform_device *pdev) | |||
514 | 514 | ||
515 | if (data->vbus_power_nb_registered) | 515 | if (data->vbus_power_nb_registered) |
516 | power_supply_unreg_notifier(&data->vbus_power_nb); | 516 | power_supply_unreg_notifier(&data->vbus_power_nb); |
517 | if (data->id_det_irq >= 0) | 517 | if (data->id_det_irq > 0) |
518 | devm_free_irq(dev, data->id_det_irq, data); | 518 | devm_free_irq(dev, data->id_det_irq, data); |
519 | if (data->vbus_det_irq >= 0) | 519 | if (data->vbus_det_irq > 0) |
520 | devm_free_irq(dev, data->vbus_det_irq, data); | 520 | devm_free_irq(dev, data->vbus_det_irq, data); |
521 | 521 | ||
522 | cancel_delayed_work_sync(&data->detect); | 522 | cancel_delayed_work_sync(&data->detect); |