36,7 → 36,11 |
#define __PAGE_HT_H__ |
|
#include <mm/page.h> |
#include <typedefs.h> |
|
/** Number of slots in page hash table. */ |
#define HT_ENTRIES HT_ENTRIES_ARCH |
|
/** Hash function. |
* |
* @param page Virtual address. Only vpn bits will be used. |
56,7 → 60,7 |
*/ |
#define HT_COMPARE(page, asid, t) HT_COMPARE_ARCH(page, asid, t) |
|
/** Identify empty hash table slots. |
/** Identify empty page hash table slots. |
* |
* @param t Pointer ro hash table typed pte_t *. |
* |
64,6 → 68,12 |
*/ |
#define HT_SLOT_EMPTY(t) HT_SLOT_EMPTY_ARCH(t) |
|
/** Invalidate/empty page hash table slot. |
* |
* @param t Address of the slot to be invalidated. |
*/ |
#define HT_INVALIDATE_SLOT(t) HT_INVALIDATE_SLOT_ARCH(t) |
|
/** Return next record in collision chain. |
* |
* @param t PTE. |
89,6 → 99,12 |
*/ |
#define HT_SET_RECORD(t, page, asid, frame, flags) HT_SET_RECORD_ARCH(t, page, asid, frame, flags) |
|
|
extern page_operations_t page_ht_operations; |
extern spinlock_t page_ht_lock; |
|
extern pte_t *page_ht; |
|
extern void ht_invalidate_all(void); |
|
#endif |