Changeset 438 for trunk/kernel/mm/kmem.c
- Timestamp:
- Apr 4, 2018, 2:49:02 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/mm/kmem.c
r435 r438 145 145 assert( ((type > 1) && (type < KMEM_TYPES_NR) ) , __FUNCTION__ , "illegal KCM type" ); 146 146 147 #if CONFIG_DEBUG_KMEM147 #if DEBUG_KMEM 148 148 uint32_t cycle = (uint32_t)hal_get_cycles(); 149 if( CONFIG_DEBUG_KMEM < cycle )149 if( DEBUG_KMEM < cycle ) 150 150 printk("\n[DBG] %s : thread %x enter / KCM type %s missing in cluster %x / cycle %d\n", 151 151 __FUNCTION__, CURRENT_THREAD, kmem_type_str( type ), local_cxy, cycle ); … … 173 173 hal_fence(); 174 174 175 #if CONFIG_DEBUG_KMEM175 #if DEBUG_KMEM 176 176 cycle = (uint32_t)hal_get_cycles(); 177 if( CONFIG_DEBUG_KMEM < cycle )177 if( DEBUG_KMEM < cycle ) 178 178 printk("\n[DBG] %s : thread %x exit / cycle %d\n", 179 179 __FUNCTION__, CURRENT_THREAD, cycle ); … … 200 200 assert( (type < KMEM_TYPES_NR) , __FUNCTION__ , "illegal KMEM request type" ); 201 201 202 #if CONFIG_DEBUG_KMEM202 #if DEBUG_KMEM 203 203 uint32_t cycle = (uint32_t)hal_get_cycles(); 204 if( CONFIG_DEBUG_KMEM < cycle )204 if( DEBUG_KMEM < cycle ) 205 205 printk("\n[DBG] %s : thread %x enter / type %s / cluster %x / cycle %d\n", 206 206 __FUNCTION__, CURRENT_THREAD, kmem_type_str( type ), local_cxy, cycle ); … … 222 222 if( flags & AF_ZERO ) page_zero( (page_t *)ptr ); 223 223 224 #if CONFIG_DEBUG_KMEM224 #if DEBUG_KMEM 225 225 cycle = (uint32_t)hal_get_cycles(); 226 if( CONFIG_DEBUG_KMEM < cycle )226 if( DEBUG_KMEM < cycle ) 227 227 printk("\n[DBG] %s : thread %x exit / %d page(s) allocated / ppn %x / cycle %d\n", 228 228 __FUNCTION__, CURRENT_THREAD, 1<<size, ppm_page2ppn(XPTR(local_cxy,ptr)), cycle ); … … 244 244 if( flags & AF_ZERO ) memset( ptr , 0 , size ); 245 245 246 #if CONFIG_DEBUG_KMEM246 #if DEBUG_KMEM 247 247 cycle = (uint32_t)hal_get_cycles(); 248 if( CONFIG_DEBUG_KMEM < cycle )248 if( DEBUG_KMEM < cycle ) 249 249 printk("\n[DBG] %s : thread %x exit / type %s allocated / base %x / size %d / cycle %d\n", 250 250 __FUNCTION__, CURRENT_THREAD, kmem_type_str( type ), (intptr_t)ptr, size, cycle ); … … 275 275 if( flags & AF_ZERO ) memset( ptr , 0 , kmem_type_size( type ) ); 276 276 277 #if CONFIG_DEBUG_KMEM277 #if DEBUG_KMEM 278 278 cycle = (uint32_t)hal_get_cycles(); 279 if( CONFIG_DEBUG_KMEM < cycle )279 if( DEBUG_KMEM < cycle ) 280 280 printk("\n[DBG] %s : thread %x exit / type %s allocated / base %x / size %d / cycle %d\n", 281 281 __FUNCTION__, CURRENT_THREAD, kmem_type_str(type), (intptr_t)ptr,
Note: See TracChangeset
for help on using the changeset viewer.