Re: [PATCH 5/5] dma: cppi41: add support for suspend and resume

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 09/20/2013 05:43 PM, Daniel Mack wrote:

This patch adds support for suspend/resume functionality to the cppi41
DMA driver. The steps neccessary to make the system resume properly were
figured out by hefty trial-and-error. The code as it stands now is the
minimum that has to be done to put the musb host system on an AM33xx
system into an operable state after resume.

Signed-off-by: Daniel Mack <zonque@xxxxxxxxx>
---
  drivers/dma/cppi41.c | 36 ++++++++++++++++++++++++++++++++++++
  1 file changed, 36 insertions(+)

diff --git a/drivers/dma/cppi41.c b/drivers/dma/cppi41.c
index 3347321..a1d162d 100644
--- a/drivers/dma/cppi41.c
+++ b/drivers/dma/cppi41.c
@@ -1040,12 +1040,48 @@ static int cppi41_dma_remove(struct platform_device *pdev)
  	return 0;
  }

+#ifdef CONFIG_PM

   CONFIG_PM_SLEEP instead?

[...]
+static const struct dev_pm_ops cppi41_pm_ops = {
+	.suspend	= cppi41_suspend,
+	.resume		= cppi41_resume,
+};
+
+#define DEV_PM_OPS	(&cppi41_pm_ops)
+#else
+#define DEV_PM_OPS	NULL
+#endif

   Why not use SIMPLE_DEV_PM_OPS() instead?

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux