X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=bertos%2Ffs%2Fbattfs.h;h=f46d8c8a80a7944c78e88d832b3c03293245fe7b;hb=6b6ed6a58e69f4f57c83cf323836da990afa768b;hp=f53bb9164d82a396f279c36564e75a94c60c7763;hpb=b6879dd52657a5cfb5b4f54a0b5c6280b3904a94;p=bertos.git diff --git a/bertos/fs/battfs.h b/bertos/fs/battfs.h index f53bb916..f46d8c8a 100644 --- a/bertos/fs/battfs.h +++ b/bertos/fs/battfs.h @@ -203,8 +203,9 @@ typedef struct BattFsSuper * the entire disk in memory. */ pgcnt_t *page_array; - pgcnt_t curr_page; - bool cache_dirty; + struct BattFsPageHeader curr_hdr; ///< Current page header (cached)- + pgcnt_t curr_page; ///< Current page loaded in disk buffer. + bool cache_dirty; ///< True if current cache is dirty (nneds to be flushed). /** * Lowest address, in page array, for free pages. @@ -243,6 +244,7 @@ typedef struct BattFs BattFsSuper *disk; ///< Disk context filemode_t mode; ///< File open mode pgcnt_t *start; ///< Pointer to page_array file start position. + pgcnt_t max_off; ///< Max page offset allocated for the file. } BattFs; /**