ShingledFS 2.0
SMR-AwareFUSE-basedFileSystem
|
00001 00009 #ifndef __BAND_LOG_H_ 00010 #define __BAND_LOG_H_ 00011 00012 00013 00014 /* 00015 * Log entry structure to be appended in store log for each band when a file is 00016 * placed on a band. 00017 * 00018 */ 00019 00020 struct store_entry { 00021 int offset; 00022 int size; 00023 int inode_num; 00024 long int age; 00025 }; 00026 00027 00028 /* 00029 * Log entry structure to be appended in deleted log for each file deleted 00030 * from a band. 00031 * 00032 */ 00033 00034 struct delete_entry { 00035 int offset; 00036 int size; 00037 int entrynumber; 00038 }; 00039 00040 00041 00042 /* ========================= */ 00043 /* -- Function Prototypes -- */ 00044 /* ========================= */ 00045 00046 int init_storelog(int band_num); 00047 int init_deletelog(int band_num); 00048 void clear_storelog(int band_num); 00049 void clear_deletelog(int band_num); 00050 int append_storelog(int fd, int offset, int size, int inode_num, long int age); 00051 void append_deletelog(int fd, int offset, int size, int entrynumber); 00052 struct store_entry* get_livelog(int band_num, int store_fd, int delete_fd, 00053 int *length, int *livedatablocks); 00054 int band_delentries(int band_num); 00055 00056 00057 00058 #endif /* __BAND_LOG_H_ */