Commit 957f98dc authored by Sekhar Nori's avatar Sekhar Nori Committed by Kevin Hilman

davinci: make it possible to include clock.h and psc.h in assembly code

psc.h contains register defines for PSC module which
need to be accessed in assembly code which helps the
DA850/OMAP-L138 SoC go to sleep. Shutting down DDR clock
using PSC is a part of the sleep procedure.

Also, the PLL related hardware definitions in clock.h are
needed in assembly code to bypass the DDR2 PLL.
Signed-off-by: default avatarSekhar Nori <nsekhar@ti.com>
Signed-off-by: default avatarKevin Hilman <khilman@deeprootsystems.com>
parent b1719b23
...@@ -12,9 +12,6 @@ ...@@ -12,9 +12,6 @@
#ifndef __ARCH_ARM_DAVINCI_CLOCK_H #ifndef __ARCH_ARM_DAVINCI_CLOCK_H
#define __ARCH_ARM_DAVINCI_CLOCK_H #define __ARCH_ARM_DAVINCI_CLOCK_H
#include <linux/list.h>
#include <asm/clkdev.h>
#define DAVINCI_PLL1_BASE 0x01c40800 #define DAVINCI_PLL1_BASE 0x01c40800
#define DAVINCI_PLL2_BASE 0x01c40c00 #define DAVINCI_PLL2_BASE 0x01c40c00
#define MAX_PLL 2 #define MAX_PLL 2
...@@ -68,6 +65,11 @@ ...@@ -68,6 +65,11 @@
*/ */
#define PLL_LOCK_TIME 20 #define PLL_LOCK_TIME 20
#ifndef __ASSEMBLER__
#include <linux/list.h>
#include <asm/clkdev.h>
struct pll_data { struct pll_data {
u32 phys_base; u32 phys_base;
void __iomem *base; void __iomem *base;
...@@ -124,3 +126,5 @@ int davinci_set_pllrate(struct pll_data *pll, unsigned int prediv, ...@@ -124,3 +126,5 @@ int davinci_set_pllrate(struct pll_data *pll, unsigned int prediv,
extern struct platform_device davinci_wdt_device; extern struct platform_device davinci_wdt_device;
#endif #endif
#endif
...@@ -191,8 +191,12 @@ ...@@ -191,8 +191,12 @@
#define MDSTAT_STATE_MASK 0x1f #define MDSTAT_STATE_MASK 0x1f
#ifndef __ASSEMBLER__
extern int davinci_psc_is_clk_active(unsigned int ctlr, unsigned int id); extern int davinci_psc_is_clk_active(unsigned int ctlr, unsigned int id);
extern void davinci_psc_config(unsigned int domain, unsigned int ctlr, extern void davinci_psc_config(unsigned int domain, unsigned int ctlr,
unsigned int id, char enable); unsigned int id, char enable);
#endif
#endif /* __ASM_ARCH_PSC_H */ #endif /* __ASM_ARCH_PSC_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment