diff options
author | Michal Simek <monstr@monstr.eu> | 2007-08-15 21:06:52 +0200 |
---|---|---|
committer | Michal Simek <monstr@monstr.eu> | 2007-08-15 21:06:52 +0200 |
commit | 19909edb97140a5ea3139705589bb90e023ab5e1 (patch) | |
tree | 6629766d2355d3c01b96b0c5ee6b9fd73502c943 /include/ppc440.h | |
parent | d1ed28cf36ab6b1d4c479809de7252bf53d2f2d4 (diff) | |
parent | 210f463c71917b7a4495c2103c228b9c179ae64d (diff) | |
download | u-boot-imx-19909edb97140a5ea3139705589bb90e023ab5e1.zip u-boot-imx-19909edb97140a5ea3139705589bb90e023ab5e1.tar.gz u-boot-imx-19909edb97140a5ea3139705589bb90e023ab5e1.tar.bz2 |
Merge git://www.denx.de/git/u-boot into merge
Diffstat (limited to 'include/ppc440.h')
-rw-r--r-- | include/ppc440.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/ppc440.h b/include/ppc440.h index 93c10f1..38809f3 100644 --- a/include/ppc440.h +++ b/include/ppc440.h @@ -3354,6 +3354,19 @@ typedef struct { unsigned long pciClkSync; /* PCI clock is synchronous */ } PPC440_SYS_INFO; +static inline u32 get_mcsr(void) +{ + u32 val; + + asm volatile("mfspr %0, 0x23c" : "=r" (val) :); + return val; +} + +static inline void set_mcsr(u32 val) +{ + asm volatile("mtspr 0x23c, %0" : "=r" (val) :); +} + #endif /* _ASMLANGUAGE */ #define RESET_VECTOR 0xfffffffc |