Changeset 438 for trunk/kernel/mm/ppm.c
- Timestamp:
- Apr 4, 2018, 2:49:02 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/mm/ppm.c
r437 r438 201 201 uint32_t current_size; 202 202 203 #if CONFIG_DEBUG_PPM_ALLOC_PAGES203 #if DEBUG_PPM_ALLOC_PAGES 204 204 uint32_t cycle = (uint32_t)hal_get_cycles(); 205 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )205 if( DEBUG_PPM_ALLOC_PAGES < cycle ) 206 206 printk("\n[DBG] in %s : thread %x enter for %d page(s) / cycle %d\n", 207 207 __FUNCTION__ , CURRENT_THREAD , 1<<order, cycle ); 208 208 #endif 209 209 210 #if( CONFIG_DEBUG_PPM_ALLOC_PAGES & 0x1)211 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )210 #if(DEBUG_PPM_ALLOC_PAGES & 0x1) 211 if( DEBUG_PPM_ALLOC_PAGES < cycle ) 212 212 ppm_print(); 213 213 #endif … … 239 239 spinlock_unlock( &ppm->free_lock ); 240 240 241 #if CONFIG_DEBUG_PPM_ALLOC_PAGES241 #if DEBUG_PPM_ALLOC_PAGES 242 242 cycle = (uint32_t)hal_get_cycles(); 243 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )243 if( DEBUG_PPM_ALLOC_PAGES < cycle ) 244 244 printk("\n[DBG] in %s : thread %x cannot allocate %d page(s) at cycle %d\n", 245 245 __FUNCTION__ , CURRENT_THREAD , 1<<order, cycle ); … … 275 275 spinlock_unlock( &ppm->free_lock ); 276 276 277 #if CONFIG_DEBUG_PPM_ALLOC_PAGES277 #if DEBUG_PPM_ALLOC_PAGES 278 278 cycle = (uint32_t)hal_get_cycles(); 279 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )279 if( DEBUG_PPM_ALLOC_PAGES < cycle ) 280 280 printk("\n[DBG] in %s : thread %x exit / %d page(s) allocated / ppn = %x / cycle %d\n", 281 281 __FUNCTION__, CURRENT_THREAD, 1<<order, ppm_page2ppn(XPTR( local_cxy , block )), cycle ); … … 292 292 ppm_t * ppm = &LOCAL_CLUSTER->ppm; 293 293 294 #if CONFIG_DEBUG_PPM_FREE_PAGES294 #if DEBUG_PPM_FREE_PAGES 295 295 uint32_t cycle = (uint32_t)hal_get_cycles(); 296 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )296 if( DEBUG_PPM_FREE_PAGES < cycle ) 297 297 printk("\n[DBG] in %s : thread %x enter for %d page(s) / cycle %d\n", 298 298 __FUNCTION__ , CURRENT_THREAD , 1<<page->order , cycle ); 299 299 #endif 300 300 301 #if( CONFIG_DEBUG_PPM_FREE_PAGES & 0x1)302 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )301 #if(DEBUG_PPM_FREE_PAGES & 0x1) 302 if( DEBUG_PPM_FREE_PAGES < cycle ) 303 303 ppm_print(); 304 304 #endif … … 312 312 spinlock_unlock( &ppm->free_lock ); 313 313 314 #if CONFIG_DEBUG_PPM_FREE_PAGES314 #if DEBUG_PPM_FREE_PAGES 315 315 cycle = (uint32_t)hal_get_cycles(); 316 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )316 if( DEBUG_PPM_FREE_PAGES < cycle ) 317 317 printk("\n[DBG] in %s : thread %x exit / %d page(s) released / ppn = %x / cycle %d\n", 318 318 __FUNCTION__, CURRENT_THREAD, 1<<page->order, ppm_page2ppn(XPTR(local_cxy , page)), cycle );
Note: See TracChangeset
for help on using the changeset viewer.