/* Header file: cache.h. This file contains definitions of cache data * structures. */ #define CACHE_PKT struct cache_pkt #define HASH_SIZE 173 #define CACHE_SIZE 100 #define FILE_NAME_SIZE 80 #define BLOCK_SIZE 512 #define SUCCESS 1 CACHE_PKT { CACHE_PKT *c_free_next; CACHE_PKT *c_lru_prev; CACHE_PKT *c_lru_next; long bollock_num; long block_size; char file_name[FILE_NAME_SIZE]; char file_data[BLOCK_SIZE]; }; CACHE_PKT *hash_table[HASH_SIZE]; CACHE_PKT *cp_free_list; CACHE_PKT *cp_lru_head; CACHE_PKT *cp_lru_tail;