From: Govindraj.R Date: Mon, 28 Feb 2011 12:42:23 +0000 (+0530) Subject: ARM: OMAP2+: UART: Add runtime pm support for omap-serial driver X-Git-Tag: v3.3-rc1~137^2~3^2^2~5^2~15 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fcdca75728ac376f3de74376c791e1078ee83820;p=pandora-kernel.git ARM: OMAP2+: UART: Add runtime pm support for omap-serial driver Adapts omap-serial driver to use pm_runtime API's. Use runtime runtime API's to handle uart clocks and obtain device_usage statics. Set runtime API's usage to irq_safe so that we can use get_sync from irq context. Auto-suspend for port specific activities and put for reg access. Moving suspend/resume hooks to dev_pm_ops structure and bind with config_suspend to avoid any compilation warning if config_suspend is disabled. By default uart autosuspend delay is set to -1 to avoid character loss if uart's are autoidled and woken up on rx pin. After boot up UART's can be autoidled by setting autosuspend delay from sysfs. echo 3000 > /sys/devices/platform/omap/omap_uart.X/power/autosuspend_delay_ms X=0,1,2,3 for UART1/2/3/4. Number of uarts available may vary across omap_soc. Also if uart is not wakeup capable we can prevent runtime autosuspend by forbiding runtime. Signed-off-by: Govindraj.R Acked-by: Alan Cox Acked-by: Greg Kroah-Hartman Signed-off-by: Kevin Hilman --- Reading git-diff-tree failed