Changeset f9599b9c in mainline
- Timestamp:
- 2015-06-29T04:46:48Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- a6abe20
- Parents:
- ac96b11
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ehci/utils/malloc32.h
rac96b11 rf9599b9c 65 65 } 66 66 67 /** Physical mallocator simulator68 *69 * @param[in] size Size of the required memory space70 * @return Address of the aligned and big enough memory place, NULL on failure.71 */72 static inline void * malloc32(size_t size)73 { return memalign(EHCI_ALIGN, size); }74 75 /** Physical mallocator simulator76 *77 * @param[in] addr Address of the place allocated by malloc3278 */79 static inline void free32(void *addr)80 { free(addr); }81 82 67 /** Create 4KB page mapping 83 68 * … … 100 85 dmamem_unmap_anonymous(page); 101 86 } 87 88 /** Physical mallocator simulator 89 * 90 * @param[in] size Size of the required memory space 91 * @return Address of the aligned and big enough memory place, NULL on failure. 92 */ 93 static inline void * malloc32(size_t size) 94 { 95 assert(size < PAGE_SIZE); 96 return get_page(); 97 } 98 99 /** Physical mallocator simulator 100 * 101 * @param[in] addr Address of the place allocated by malloc32 102 */ 103 static inline void free32(void *addr) 104 { 105 return_page(addr); 106 } 107 102 108 #endif 103 109 /**
Note:
See TracChangeset
for help on using the changeset viewer.