Commit 04e59a02 authored by Hans de Goede's avatar Hans de Goede Committed by Kishon Vijay Abraham I

phy-sun4i-usb: Fix irq free conditions to match request conditions

commit 5cf700ac ("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: 5cf700ac ("phy: phy-sun4i-usb: Fix optional gpios failing probe")
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarKishon Vijay Abraham I <kishon@ti.com>
parent 6c081ff6
...@@ -514,9 +514,9 @@ static int sun4i_usb_phy_remove(struct platform_device *pdev) ...@@ -514,9 +514,9 @@ static int sun4i_usb_phy_remove(struct platform_device *pdev)
if (data->vbus_power_nb_registered) if (data->vbus_power_nb_registered)
power_supply_unreg_notifier(&data->vbus_power_nb); power_supply_unreg_notifier(&data->vbus_power_nb);
if (data->id_det_irq >= 0) if (data->id_det_irq > 0)
devm_free_irq(dev, data->id_det_irq, data); devm_free_irq(dev, data->id_det_irq, data);
if (data->vbus_det_irq >= 0) if (data->vbus_det_irq > 0)
devm_free_irq(dev, data->vbus_det_irq, data); devm_free_irq(dev, data->vbus_det_irq, data);
cancel_delayed_work_sync(&data->detect); cancel_delayed_work_sync(&data->detect);
......
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