aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/plat-samsung
diff options
context:
space:
mode:
authorTomasz Figa <t.figa@samsung.com>2014-03-17 18:28:09 -0400
committerKukjin Kim <kgene.kim@samsung.com>2014-03-20 15:06:12 -0400
commitd38688a69fd88269eae3c7c66ec34fb02fb04fd1 (patch)
tree4a2673db3695d9539b6c8772a8193afd84c6b110 /arch/arm/plat-samsung
parent99b2fc2b8b40256538332769f11f2fe6ee942f6c (diff)
ARM: SAMSUNG: Consolidate PM debug functions
This patch removes one-line functions that was used just to pass constant arguments to lower level functions. After previous patches the need for those constants has been eliminated, so the main functions can be called directly. Signed-off-by: Tomasz Figa <t.figa@samsung.com> Acked-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/plat-samsung')
-rw-r--r--arch/arm/plat-samsung/pm.c20
1 files changed, 6 insertions, 14 deletions
diff --git a/arch/arm/plat-samsung/pm.c b/arch/arm/plat-samsung/pm.c
index c7fac34de621..dd70337822da 100644
--- a/arch/arm/plat-samsung/pm.c
+++ b/arch/arm/plat-samsung/pm.c
@@ -85,9 +85,10 @@ static inline void __iomem *s3c_pm_uart_base(void)
85 return (void __iomem *)vaddr; 85 return (void __iomem *)vaddr;
86} 86}
87 87
88static void s3c_pm_save_uart(unsigned int uart, struct pm_uart_save *save) 88static void s3c_pm_save_uarts(void)
89{ 89{
90 void __iomem *regs = s3c_pm_uart_base(); 90 void __iomem *regs = s3c_pm_uart_base();
91 struct pm_uart_save *save = &uart_save;
91 92
92 save->ulcon = __raw_readl(regs + S3C2410_ULCON); 93 save->ulcon = __raw_readl(regs + S3C2410_ULCON);
93 save->ucon = __raw_readl(regs + S3C2410_UCON); 94 save->ucon = __raw_readl(regs + S3C2410_UCON);
@@ -98,18 +99,14 @@ static void s3c_pm_save_uart(unsigned int uart, struct pm_uart_save *save)
98 if (!soc_is_s3c2410()) 99 if (!soc_is_s3c2410())
99 save->udivslot = __raw_readl(regs + S3C2443_DIVSLOT); 100 save->udivslot = __raw_readl(regs + S3C2443_DIVSLOT);
100 101
101 S3C_PMDBG("UART[%d]: ULCON=%04x, UCON=%04x, UFCON=%04x, UBRDIV=%04x\n", 102 S3C_PMDBG("UART[%p]: ULCON=%04x, UCON=%04x, UFCON=%04x, UBRDIV=%04x\n",
102 uart, save->ulcon, save->ucon, save->ufcon, save->ubrdiv); 103 regs, save->ulcon, save->ucon, save->ufcon, save->ubrdiv);
103}
104
105static void s3c_pm_save_uarts(void)
106{
107 s3c_pm_save_uart(CONFIG_DEBUG_S3C_UART, &uart_save);
108} 104}
109 105
110static void s3c_pm_restore_uart(unsigned int uart, struct pm_uart_save *save) 106static void s3c_pm_restore_uarts(void)
111{ 107{
112 void __iomem *regs = s3c_pm_uart_base(); 108 void __iomem *regs = s3c_pm_uart_base();
109 struct pm_uart_save *save = &uart_save;
113 110
114 s3c_pm_arch_update_uart(regs, save); 111 s3c_pm_arch_update_uart(regs, save);
115 112
@@ -122,11 +119,6 @@ static void s3c_pm_restore_uart(unsigned int uart, struct pm_uart_save *save)
122 if (!soc_is_s3c2410()) 119 if (!soc_is_s3c2410())
123 __raw_writel(save->udivslot, regs + S3C2443_DIVSLOT); 120 __raw_writel(save->udivslot, regs + S3C2443_DIVSLOT);
124} 121}
125
126static void s3c_pm_restore_uarts(void)
127{
128 s3c_pm_restore_uart(CONFIG_DEBUG_S3C_UART, &uart_save);
129}
130#else 122#else
131#define s3c_pm_debug_init() do { } while (0) 123#define s3c_pm_debug_init() do { } while (0)
132 124