Rev 422 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
422 | giacomo | 1 | /* |
2 | * include/linux/rmap-locking.h |
||
3 | * |
||
4 | * Locking primitives for exclusive access to a page's reverse-mapping |
||
5 | * pte chain. |
||
6 | */ |
||
7 | |||
8 | #include <linux/slab.h> |
||
9 | |||
10 | struct pte_chain; |
||
11 | extern kmem_cache_t *pte_chain_cache; |
||
12 | |||
13 | #define pte_chain_lock(page) bit_spin_lock(PG_chainlock, &page->flags) |
||
14 | #define pte_chain_unlock(page) bit_spin_unlock(PG_chainlock, &page->flags) |
||
15 | |||
16 | struct pte_chain *pte_chain_alloc(int gfp_flags); |
||
17 | void __pte_chain_free(struct pte_chain *pte_chain); |
||
18 | |||
19 | static inline void pte_chain_free(struct pte_chain *pte_chain) |
||
20 | { |
||
21 | if (pte_chain) |
||
22 | __pte_chain_free(pte_chain); |
||
23 | } |