summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2008-11-25 11:32:10 +0100
committerWolfgang Denk <wd@denx.de>2008-11-25 11:32:10 +0100
commitc49dc0b3b8f0fc9ed8e50d17d20e8e65d7abae57 (patch)
tree0a58b3df46601362cf4b811b8fbfa87e45f89b1f /include
parent58c696eed839af894e0265064669c402dc28b371 (diff)
parent91809ed51d8327a8dbbf29aa98a091154c282171 (diff)
downloadblackbird-obmc-uboot-c49dc0b3b8f0fc9ed8e50d17d20e8e65d7abae57.tar.gz
blackbird-obmc-uboot-c49dc0b3b8f0fc9ed8e50d17d20e8e65d7abae57.zip
Merge branch 'master' of git://git.denx.de/u-boot-cfi-flash
Diffstat (limited to 'include')
-rw-r--r--include/flash.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/flash.h b/include/flash.h
index a6e91b5e69..6e2981c5ae 100644
--- a/include/flash.h
+++ b/include/flash.h
@@ -58,6 +58,8 @@ typedef struct {
#endif
} flash_info_t;
+typedef unsigned long flash_sect_t;
+
/*
* Values for the width of the port
*/
@@ -84,6 +86,9 @@ typedef struct {
/* convert between bit value and numeric value */
#define CFI_FLASH_SHIFT_WIDTH 3
+
+/* cfi-mtd device name */
+#define CFI_MTD_DEV_NAME "cfi-mtd"
/* Prototypes */
extern unsigned long flash_init (void);
@@ -92,6 +97,8 @@ extern int flash_erase (flash_info_t *, int, int);
extern int flash_sect_erase (ulong addr_first, ulong addr_last);
extern int flash_sect_protect (int flag, ulong addr_first, ulong addr_last);
extern int flash_sect_roundb (ulong *addr);
+extern unsigned long flash_sector_size(flash_info_t *info, flash_sect_t sect);
+extern void flash_set_verbose(uint);
/* common/flash.c */
extern void flash_protect (int flag, ulong from, ulong to, flash_info_t *info);
@@ -99,6 +106,11 @@ extern int flash_write (char *, ulong, ulong);
extern flash_info_t *addr2info (ulong);
extern int write_buff (flash_info_t *info, uchar *src, ulong addr, ulong cnt);
+/* drivers/mtd/cfi_mtd.c */
+#ifdef CONFIG_FLASH_CFI_MTD
+extern int cfi_mtd_init(void);
+#endif
+
/* board/?/flash.c */
#if defined(CONFIG_SYS_FLASH_PROTECTION)
extern int flash_real_protect(flash_info_t *info, long sector, int prot);
OpenPOWER on IntegriCloud