Changeset 438 for trunk/kernel/mm/ppm.c


Ignore:
Timestamp:
Apr 4, 2018, 2:49:02 PM (7 years ago)
Author:
alain
Message:

Fix a bug in scheduler related to RPC blocking.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/mm/ppm.c

    r437 r438  
    201201        uint32_t   current_size;
    202202 
    203 #if CONFIG_DEBUG_PPM_ALLOC_PAGES
     203#if DEBUG_PPM_ALLOC_PAGES
    204204uint32_t cycle = (uint32_t)hal_get_cycles();
    205 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )
     205if( DEBUG_PPM_ALLOC_PAGES < cycle )
    206206printk("\n[DBG] in %s : thread %x enter for %d page(s) / cycle %d\n",
    207207__FUNCTION__ , CURRENT_THREAD , 1<<order, cycle );
    208208#endif
    209209
    210 #if(CONFIG_DEBUG_PPM_ALLOC_PAGES & 0x1)
    211 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )
     210#if(DEBUG_PPM_ALLOC_PAGES & 0x1)
     211if( DEBUG_PPM_ALLOC_PAGES < cycle )
    212212ppm_print();
    213213#endif
     
    239239                spinlock_unlock( &ppm->free_lock );
    240240
    241 #if CONFIG_DEBUG_PPM_ALLOC_PAGES
     241#if DEBUG_PPM_ALLOC_PAGES
    242242cycle = (uint32_t)hal_get_cycles();
    243 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )
     243if( DEBUG_PPM_ALLOC_PAGES < cycle )
    244244printk("\n[DBG] in %s : thread %x cannot allocate %d page(s) at cycle %d\n",
    245245__FUNCTION__ , CURRENT_THREAD , 1<<order, cycle );
     
    275275        spinlock_unlock( &ppm->free_lock );
    276276
    277 #if CONFIG_DEBUG_PPM_ALLOC_PAGES
     277#if DEBUG_PPM_ALLOC_PAGES
    278278cycle = (uint32_t)hal_get_cycles();
    279 if( CONFIG_DEBUG_PPM_ALLOC_PAGES < cycle )
     279if( DEBUG_PPM_ALLOC_PAGES < cycle )
    280280printk("\n[DBG] in %s : thread %x exit / %d page(s) allocated / ppn = %x / cycle %d\n",
    281281__FUNCTION__, CURRENT_THREAD, 1<<order, ppm_page2ppn(XPTR( local_cxy , block )), cycle );
     
    292292        ppm_t * ppm = &LOCAL_CLUSTER->ppm;
    293293
    294 #if CONFIG_DEBUG_PPM_FREE_PAGES
     294#if DEBUG_PPM_FREE_PAGES
    295295uint32_t cycle = (uint32_t)hal_get_cycles();
    296 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )
     296if( DEBUG_PPM_FREE_PAGES < cycle )
    297297printk("\n[DBG] in %s : thread %x enter for %d page(s) / cycle %d\n",
    298298__FUNCTION__ , CURRENT_THREAD , 1<<page->order , cycle );
    299299#endif
    300300
    301 #if(CONFIG_DEBUG_PPM_FREE_PAGES & 0x1)
    302 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )
     301#if(DEBUG_PPM_FREE_PAGES & 0x1)
     302if( DEBUG_PPM_FREE_PAGES < cycle )
    303303ppm_print();
    304304#endif
     
    312312        spinlock_unlock( &ppm->free_lock );
    313313
    314 #if CONFIG_DEBUG_PPM_FREE_PAGES
     314#if DEBUG_PPM_FREE_PAGES
    315315cycle = (uint32_t)hal_get_cycles();
    316 if( CONFIG_DEBUG_PPM_FREE_PAGES < cycle )
     316if( DEBUG_PPM_FREE_PAGES < cycle )
    317317printk("\n[DBG] in %s : thread %x exit / %d page(s) released / ppn = %x / cycle %d\n",
    318318__FUNCTION__, CURRENT_THREAD, 1<<page->order, ppm_page2ppn(XPTR(local_cxy , page)), cycle );
Note: See TracChangeset for help on using the changeset viewer.