Changeset 5c3243e in mainline for generic/include/mm/frame.h
- Timestamp:
- 2006-02-08T14:01:58Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 4c8715d2
- Parents:
- 5e3757d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
generic/include/mm/frame.h
r5e3757d r5c3243e 42 42 #define ZONES_MAX 16 /**< Maximum number of zones in system */ 43 43 44 #define ZONE_JOIN 0x1 /**< If possible, merge with neighberhood zones */ 45 44 #define ZONE_JOIN 0x1 /**< If possible, merge with neighberhood zones */ 46 45 47 46 #define FRAME_KA 0x1 /* skip frames conflicting with user address space */ 48 47 #define FRAME_PANIC 0x2 /* panic on failure */ 49 48 #define FRAME_ATOMIC 0x4 /* do not panic and do not sleep on failure */ 50 #define FRAME_NO_RECLAIM 0x8 /* Do not start reclaiming when no free memory */49 #define FRAME_NO_RECLAIM 0x8 /* do not start reclaiming when no free memory */ 51 50 52 51 #define FRAME_OK 0 /* frame_alloc return status */ … … 68 67 static inline __address PFN2ADDR(pfn_t frame) 69 68 { 70 return (__address)(frame << PAGE_WIDTH);69 return (__address)(frame << FRAME_WIDTH); 71 70 } 72 71 73 72 static inline pfn_t ADDR2PFN(__address addr) 74 73 { 75 return (pfn_t)(addr >> PAGE_WIDTH);74 return (pfn_t)(addr >> FRAME_WIDTH); 76 75 } 77 76 … … 80 79 if (!size) 81 80 return 0; 82 return (pfn_t)((size-1) >> PAGE_WIDTH)+1;81 return (pfn_t)((size-1) >> FRAME_WIDTH)+1; 83 82 } 84 83 … … 88 87 #define IS_BUDDY_LEFT_BLOCK_ABS(zone, frame) (((frame_index_abs((zone), (frame)) >> (frame)->buddy_order) & 0x1) == 0) 89 88 #define IS_BUDDY_RIGHT_BLOCK_ABS(zone, frame) (((frame_index_abs((zone), (frame)) >> (frame)->buddy_order) & 0x1) == 1) 90 91 89 92 90 #define frame_alloc(order, flags) frame_alloc_generic(order, flags, NULL, NULL)
Note:
See TracChangeset
for help on using the changeset viewer.