usb: otg: tegra: update interrupt status properly
Rohith Seelaboyina [Thu, 25 Apr 2013 07:10:21 +0000 (12:10 +0530)]
Interrupt status is being overridden,
fix this accordingly

Bug 1275428

Change-Id: I0812cbda3fd75a7d33dc180db31ad2ee1699d3bf
Signed-off-by: Rohith Seelaboyina <rseelaboyina@nvidia.com>
Reviewed-on: http://git-master/r/222812
Reviewed-by: Riham Haidar <rhaidar@nvidia.com>
Tested-by: Riham Haidar <rhaidar@nvidia.com>

drivers/usb/otg/tegra-otg.c

index 74ba382..6c89caf 100644 (file)
@@ -767,11 +767,10 @@ static void tegra_otg_resume(struct device *dev)
 
                spin_lock_irqsave(&tegra->lock, flags);
                if (tegra->support_usb_id)
-                       tegra->int_status = val | USB_ID_INT_EN |
-                                       USB_ID_PIN_WAKEUP_EN;
+                       val |= USB_ID_INT_EN | USB_ID_PIN_WAKEUP_EN;
                if (!tegra->support_pmu_vbus)
-                       tegra->int_status = val | USB_VBUS_INT_EN |
-                                       USB_VBUS_WAKEUP_EN;
+                       val |= USB_VBUS_INT_EN | USB_VBUS_WAKEUP_EN;
+               tegra->int_status = val;
                spin_unlock_irqrestore(&tegra->lock, flags);
        }