misc: tegra: Disable short delay if wake gpio not
Martin Chi [Fri, 3 Jan 2014 03:24:09 +0000 (11:24 +0800)]
 defined.

Disable short_autosuspend_delay for Modem device, when wake gpio
is not used.

Bug 1362837
Bug 1430974

Change-Id: I9b36becead27903ad6e063ecb450e01c1c56dd5f
Signed-off-by: Martin Chi <mchi@nvidia.com>
Reviewed-on: http://git-master/r/351585
GVS: Gerrit_Virtual_Submit

drivers/misc/tegra-baseband/tegra_usb_modem_power.c

index b012f87..f3e142e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011-2013, NVIDIA CORPORATION.  All rights reserved.
+ * Copyright (c) 2011-2014, NVIDIA CORPORATION.  All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -391,6 +391,7 @@ static int mdm_pm_notifier(struct notifier_block *notifier,
                modem->system_suspend = 1;
 #ifdef CONFIG_PM
                if (modem->capability & TEGRA_MODEM_AUTOSUSPEND &&
+                   modem->wake_irq &&
                    modem->udev &&
                    modem->udev->state != USB_STATE_NOTATTACHED) {
                        pm_runtime_set_autosuspend_delay(&modem->udev->dev,