Changeset 89c57b6 in mainline for uspace/srv/fs/fat/fat.h
- Timestamp:
- 2011-04-13T14:45:41Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 88634420
- Parents:
- cefb126 (diff), 17279ead (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/fat/fat.h
rcefb126 r89c57b6 35 35 36 36 #include "fat_fat.h" 37 #include <ipc/ipc.h>38 37 #include <fibril_synch.h> 39 38 #include <libfs.h> … … 48 47 49 48 #define min(a, b) ((a) < (b) ? (a) : (b)) 49 50 /* 51 * Convenience macros for accessing some frequently used boot sector members. 52 */ 53 #define BPS(bs) uint16_t_le2host((bs)->bps) 54 #define SPC(bs) (bs)->spc 55 #define RSCNT(bs) uint16_t_le2host((bs)->rscnt) 56 #define FATCNT(bs) (bs)->fatcnt 57 #define SF(bs) uint16_t_le2host((bs)->sec_per_fat) 58 #define RDE(bs) uint16_t_le2host((bs)->root_ent_max) 59 #define TS(bs) (uint16_t_le2host((bs)->totsec16) != 0 ? \ 60 uint16_t_le2host((bs)->totsec16) : \ 61 uint32_t_le2host(bs->totsec32)) 50 62 51 63 #define BS_BLOCK 0 … … 163 175 164 176 fibril_mutex_t lock; 165 dev _handle_t dev_handle;177 devmap_handle_t devmap_handle; 166 178 fs_index_t index; 167 179 /** … … 198 210 unsigned refcnt; 199 211 bool dirty; 212 213 /* 214 * Cache of the node's last and "current" cluster to avoid some 215 * unnecessary FAT walks. 216 */ 217 /* Node's last cluster in FAT. */ 218 bool lastc_cached_valid; 219 fat_cluster_t lastc_cached_value; 220 /* Node's "current" cluster, i.e. where the last I/O took place. */ 221 bool currc_cached_valid; 222 aoff64_t currc_cached_bn; 223 fat_cluster_t currc_cached_value; 200 224 } fat_node_t; 201 225 … … 217 241 extern void fat_sync(ipc_callid_t, ipc_call_t *); 218 242 219 extern int fat_idx_get_new(fat_idx_t **, dev _handle_t);220 extern fat_idx_t *fat_idx_get_by_pos(dev _handle_t, fat_cluster_t, unsigned);221 extern fat_idx_t *fat_idx_get_by_index(dev _handle_t, fs_index_t);243 extern int fat_idx_get_new(fat_idx_t **, devmap_handle_t); 244 extern fat_idx_t *fat_idx_get_by_pos(devmap_handle_t, fat_cluster_t, unsigned); 245 extern fat_idx_t *fat_idx_get_by_index(devmap_handle_t, fs_index_t); 222 246 extern void fat_idx_destroy(fat_idx_t *); 223 247 extern void fat_idx_hashin(fat_idx_t *); … … 226 250 extern int fat_idx_init(void); 227 251 extern void fat_idx_fini(void); 228 extern int fat_idx_init_by_dev _handle(dev_handle_t);229 extern void fat_idx_fini_by_dev _handle(dev_handle_t);252 extern int fat_idx_init_by_devmap_handle(devmap_handle_t); 253 extern void fat_idx_fini_by_devmap_handle(devmap_handle_t); 230 254 231 255 #endif
Note:
See TracChangeset
for help on using the changeset viewer.