]> git.sur5r.net Git - u-boot/blobdiff - include/common.h
* Patch by Nicolas Lacressonnière, 12 Nov 2003:
[u-boot] / include / common.h
index 5158f97ece3774105087e557a5919b387bfce289..39c232a0ffa96824b18b4433b8e042cb0581d131 100644 (file)
@@ -62,6 +62,10 @@ typedef volatile unsigned char       vu_char;
 #elif defined(CONFIG_8260)
 #include <asm/immap_8260.h>
 #endif
+#ifdef CONFIG_MPC85xx
+#include <mpc85xx.h>
+#include <asm/immap_85xx.h>
+#endif
 #ifdef CONFIG_4xx
 #include <ppc4xx.h>
 #endif
@@ -148,7 +152,7 @@ int readline        (const char *const prompt);
 void   init_cmd_timeout(void);
 void   reset_cmd_timeout(void);
 
-/* common/board.c */
+/* lib_$(ARCH)/board.c */
 void   board_init_f  (ulong);
 void   board_init_r  (gd_t *, ulong);
 int    checkboard    (void);
@@ -236,7 +240,7 @@ extern void  pic_write (uchar reg, uchar val);
 # define CFG_DEF_EEPROM_ADDR CFG_I2C_EEPROM_ADDR
 #endif /* CONFIG_SPI || !defined(CFG_I2C_EEPROM_ADDR) */
 
-#if defined(CONFIG_PCU_E) || defined(CONFIG_CCM) || defined(CONFIG_ATC)
+#if defined(CONFIG_SPI)
 extern void spi_init_f (void);
 extern void spi_init_r (void);
 extern ssize_t spi_read  (uchar *, int, uchar *, int);
@@ -287,6 +291,7 @@ int testdram(void);
     defined(CONFIG_8xx)
 uint   get_immr      (uint);
 #endif
+uint   get_pir       (void);
 uint   get_pvr       (void);
 uint   rd_ic_cst     (void);
 void   wr_ic_cst     (uint);
@@ -359,6 +364,11 @@ ulong      get_UCLK (void);
 #endif
 ulong  get_bus_freq  (ulong);
 
+#if defined(CONFIG_MPC85xx)
+typedef MPC85xx_SYS_INFO sys_info_t;
+void    get_sys_info  ( sys_info_t * );
+#endif
+
 #if defined(CONFIG_4xx) || defined(CONFIG_IOP480)
 #  if defined(CONFIG_440)
     typedef PPC440_SYS_INFO sys_info_t;
@@ -372,7 +382,7 @@ void    get_sys_info  ( sys_info_t * );
 #if defined(CONFIG_8xx) || defined(CONFIG_8260)
 void   cpu_init_f    (volatile immap_t *immr);
 #endif
-#ifdef CONFIG_4xx
+#if defined(CONFIG_4xx) || defined(CONFIG_MPC85xx)
 void   cpu_init_f    (void);
 #endif
 int    cpu_init_r    (void);
@@ -400,6 +410,9 @@ uint        dpram_alloc(uint size);
 uint   dpram_alloc_align(uint size,uint align);
 void   post_word_store (ulong);
 ulong  post_word_load (void);
+void   bootcount_store (ulong);
+ulong  bootcount_load (void);
+#define BOOTCOUNT_MAGIC                0xB001C041
 
 /* $(CPU)/.../<eth> */
 void mii_init (void);
@@ -417,24 +430,24 @@ ulong     video_setmem (ulong);
 void   flush_cache   (unsigned long, unsigned long);
 
 
-/* ppc/ticks.S */
+/* lib_$(ARCH)/ticks.S */
 unsigned long long get_ticks(void);
 void   wait_ticks    (unsigned long);
 
-/* ppc/time.c */
+/* lib_$(ARCH)/time.c */
 void   udelay        (unsigned long);
 ulong  usec2ticks    (unsigned long usec);
 ulong  ticks2usec    (unsigned long ticks);
 int    init_timebase (void);
 
-/* ppc/vsprintf.c */
+/* lib_generic/vsprintf.c */
 ulong  simple_strtoul(const char *cp,char **endp,unsigned int base);
 long   simple_strtol(const char *cp,char **endp,unsigned int base);
 void   panic(const char *fmt, ...);
 int    sprintf(char * buf, const char *fmt, ...);
 int    vsprintf(char *buf, const char *fmt, va_list args);
 
-/* ppc/crc32.c */
+/* lib_generic/crc32.c */
 ulong crc32 (ulong, const unsigned char *, uint);
 ulong crc32_no_comp (ulong, const unsigned char *, uint);