projects
/
my-code
/
arm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
bullshit commit, sync for travel (to zn00H!) :)
[my-code/arm.git]
/
betty
/
pffs.h
diff --git
a/betty/pffs.h
b/betty/pffs.h
index
98ddd50
..
5849fa7
100644
(file)
--- a/
betty/pffs.h
+++ b/
betty/pffs.h
@@
-66,10
+66,9
@@
typedef struct s_pffs {
/* flash specs */
typedef struct s_pffs {
/* flash specs */
- u32 base_addr;
- u32 *sec_addr;
- u8 sec_num_data[2]; // first/last sector used for data
- u8 sec_num_index[2]; // 2 sectors used as an index
+ u32 base_addr; // base flash access address
+ u32 *sec_addr; // pointer to sector addresses
+ u8 sec_num; // number of sectors
/* flash write, read and sector erase function pointers */
int (*fw)(u32 addr,u16 *buf,int len);
/* flash write, read and sector erase function pointers */
int (*fw)(u32 addr,u16 *buf,int len);
@@
-78,7
+77,6
@@
typedef struct s_pffs {
/* pffs internal variables */
u8 state;
/* pffs internal variables */
u8 state;
- u8 index_sec; // current index sector
u8 data_tmp_sec; // current temp data sector
} t_pffs;
u8 data_tmp_sec; // current temp data sector
} t_pffs;
@@
-105,9
+103,7
@@
typedef struct s_pffs_file_header {
}
/* function prototypes (only the ones applications should use!) */
}
/* function prototypes (only the ones applications should use!) */
-int pffs_flash_register(t_pffs *pffs,u32 base_addr,u32 *sec_addr,
- u8 sec_num_data_min,u8 sec_num_data_max,
- u8 sec_num_index0,u8 sec_num_index1,
+int pffs_flash_register(t_pffs *pffs,u32 base_addr,u32 *sec_addr,u8 sec_num,
int (*fw)(u32 addr,u16 *buf,int len),
int (*fr)(u32 addr,u16 *buf,int len),
int (*fe)(u32 addr));
int (*fw)(u32 addr,u16 *buf,int len),
int (*fr)(u32 addr,u16 *buf,int len),
int (*fe)(u32 addr));