Changeset 492 for trunk/hal/tsar_mips32
- Timestamp:
- Aug 22, 2018, 11:55:48 PM (6 years ago)
- Location:
- trunk/hal/tsar_mips32
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/hal/tsar_mips32/core/hal_context.c
r459 r492 119 119 error_t hal_cpu_context_alloc( thread_t * thread ) 120 120 { 121 assert( (sizeof(hal_cpu_context_t) <= CONFIG_CPU_CTX_SIZE) , __FUNCTION__ ,121 assert( (sizeof(hal_cpu_context_t) <= CONFIG_CPU_CTX_SIZE) , 122 122 "illegal CPU context size" ); 123 123 … … 146 146 hal_cpu_context_t * context = (hal_cpu_context_t *)thread->cpu_context; 147 147 148 assert( (context != NULL ), __FUNCTION__,"CPU context not allocated" );148 assert( (context != NULL ), "CPU context not allocated" ); 149 149 150 150 // initialisation depends on thread type … … 235 235 else // current == child thread 236 236 { 237 assert( (current == child_ptr) , __FUNCTION__ ,"current = %x / child = %x\n");237 assert( (current == child_ptr) , "current = %x / child = %x\n"); 238 238 } 239 239 } // end hal_cpu_context_fork() … … 300 300 error_t hal_fpu_context_alloc( thread_t * thread ) 301 301 { 302 assert( (sizeof(hal_fpu_context_t) <= CONFIG_FPU_CTX_SIZE) , __FUNCTION__ ,302 assert( (sizeof(hal_fpu_context_t) <= CONFIG_FPU_CTX_SIZE) , 303 303 "illegal CPU context size" ); 304 304 … … 322 322 hal_fpu_context_t * context = thread->fpu_context; 323 323 324 assert( (context != NULL) , __FUNCTION__ , "fpu context not allocated" );324 assert( (context != NULL) , "fpu context not allocated" ); 325 325 326 326 memset( context , 0 , sizeof(hal_fpu_context_t) ); … … 331 331 thread_t * src ) 332 332 { 333 assert( (src != NULL) , __FUNCTION__ , "src thread pointer is NULL\n");334 assert( (dst != NULL) , __FUNCTION__ , "dst thread pointer is NULL\n");333 assert( (src != NULL) , "src thread pointer is NULL\n"); 334 assert( (dst != NULL) , "dst thread pointer is NULL\n"); 335 335 336 336 // get fpu context pointers -
trunk/hal/tsar_mips32/core/hal_drivers.c
r457 r492 49 49 uint32_t impl ) 50 50 { 51 assert( (impl == IMPL_TXT_TTY), __FUNCTION__ ,"bad implementation" );51 assert( (impl == IMPL_TXT_TTY), "bad implementation" ); 52 52 53 53 soclib_tty_init( txt ); … … 62 62 uint32_t impl ) 63 63 { 64 assert( (impl == IMPL_PIC_SCL), __FUNCTION__,"bad implementation" );64 assert( (impl == IMPL_PIC_SCL), "bad implementation" ); 65 65 66 66 soclib_pic_init( pic ); … … 85 85 uint32_t impl ) 86 86 { 87 assert( (impl == IMPL_IOB_TSR), __FUNCTION__ ,"bad implementation" );87 assert( (impl == IMPL_IOB_TSR), "bad implementation" ); 88 88 89 89 soclib_iob_init( iob ); … … 116 116 else 117 117 { 118 assert( false , __FUNCTION__ ,"undefined IOC device implementation" );118 assert( false , "undefined IOC device implementation" ); 119 119 } 120 120 } … … 128 128 uint32_t impl ) 129 129 { 130 assert( (impl == IMPL_MMC_TSR), __FUNCTION__ ,"bad implementation" );130 assert( (impl == IMPL_MMC_TSR), "bad implementation" ); 131 131 132 132 soclib_mmc_init( mmc ); … … 141 141 uint32_t impl ) 142 142 { 143 assert( (impl == IMPL_NIC_CBF), __FUNCTION__ ,"bad implementation" );143 assert( (impl == IMPL_NIC_CBF), "bad implementation" ); 144 144 145 145 soclib_nic_init( nic ); … … 154 154 uint32_t impl ) 155 155 { 156 assert( (impl == IMPL_DMA_SCL), __FUNCTION__ ,"bad implementation" );156 assert( (impl == IMPL_DMA_SCL), "bad implementation" ); 157 157 158 158 soclib_dma_init( dma ); -
trunk/hal/tsar_mips32/core/hal_exception.c
r481 r492 500 500 hal_exception_dump( this , uzone , error ); 501 501 502 assert( false , __FUNCTION__ , "core[%x,%d] blocked\n", local_cxy, this->core->lid);502 assert( false , "Exception raised kernel panic see information below.\n" ); 503 503 } 504 504 -
trunk/hal/tsar_mips32/core/hal_gpt.c
r457 r492 140 140 141 141 // check page size 142 assert( (CONFIG_PPM_PAGE_SIZE == 4096) , __FUNCTION__ ,142 assert( (CONFIG_PPM_PAGE_SIZE == 4096) , 143 143 "for TSAR, the page size must be 4 Kbytes\n" ); 144 144 … … 283 283 vpn_t vpn; 284 284 285 assert( (process != NULL) , __FUNCTION__ ,"NULL process pointer\n");285 assert( (process != NULL) , "NULL process pointer\n"); 286 286 287 287 // get pointer on gpt … … 387 387 pte1 = *pte1_ptr; 388 388 389 assert( (pte1 == 0) , __FUNCTION__ ,389 assert( (pte1 == 0) , 390 390 "try to set a big page in a mapped PT1 entry / PT1[%d] = %x\n", ix1 , pte1 ); 391 391 … … 441 441 { 442 442 // This valid entry must be a PTD1 443 assert( (pte1 & TSAR_MMU_SMALL) , __FUNCTION__ ,443 assert( (pte1 & TSAR_MMU_SMALL) , 444 444 "try to set a small page in a big PT1 entry / PT1[%d] = %x\n", ix1 , pte1 ); 445 445 … … 792 792 793 793 // check src_pt1 and dst_pt1 existence 794 assert( (src_pt1 != NULL) , __FUNCTION__ ,"src_pt1 does not exist\n");795 assert( (dst_pt1 != NULL) , __FUNCTION__ ,"dst_pt1 does not exist\n");794 assert( (src_pt1 != NULL) , "src_pt1 does not exist\n"); 795 assert( (dst_pt1 != NULL) , "dst_pt1 does not exist\n"); 796 796 797 797 ix1 = TSAR_MMU_IX1_FROM_VPN( vpn ); … … 1010 1010 pt2 = (uint32_t*)GET_PTR( ppm_ppn2base( pt2_ppn ) ); 1011 1011 1012 assert( (GET_CXY( ppm_ppn2base( pt2_ppn ) ) == gpt_cxy ), __FUNCTION__,1012 assert( (GET_CXY( ppm_ppn2base( pt2_ppn ) ) == gpt_cxy ), 1013 1013 "PT2 and PT1 must be in the same cluster\n"); 1014 1014 -
trunk/hal/tsar_mips32/drivers/soclib_bdv.c
r451 r492 219 219 else 220 220 { 221 assert( false , __FUNCTION__ ,"IOC_SYNC_READ should not use IRQ" );221 assert( false , "IOC_SYNC_READ should not use IRQ" ); 222 222 } 223 223 -
trunk/hal/tsar_mips32/drivers/soclib_nic.c
r451 r492 53 53 54 54 // allocate memory for chbuf descriptor (one page) 55 assert( (sizeof(nic_chbuf_t) <= CONFIG_PPM_PAGE_SIZE ) , __FUNCTION__ ,55 assert( (sizeof(nic_chbuf_t) <= CONFIG_PPM_PAGE_SIZE ) , 56 56 "chbuf descriptor exceeds one page" ); 57 57 … … 62 62 nic_chbuf_t * chbuf = (nic_chbuf_t *)kmem_alloc( &req ); 63 63 64 assert( (chbuf != NULL) , __FUNCTION__ ,64 assert( (chbuf != NULL) , 65 65 "cannot allocate chbuf descriptor" ); 66 66 … … 72 72 // allocate containers (one page per container) 73 73 // and complete chbuf descriptor initialization 74 assert( (CONFIG_PPM_PAGE_SIZE == 4096) , __FUNCTION__ ,74 assert( (CONFIG_PPM_PAGE_SIZE == 4096) , 75 75 "chbuf container must be 4 Kbytes" ); 76 76 … … 79 79 uint32_t * container = (uint32_t *)kmem_alloc( &req ); 80 80 81 assert( (container != NULL) , __FUNCTION__ ,81 assert( (container != NULL) , 82 82 "cannot allocate container" ); 83 83 -
trunk/hal/tsar_mips32/drivers/soclib_pic.c
r481 r492 57 57 soclib_pic_cluster_t * ext_ptr = LOCAL_CLUSTER->pic_extend; 58 58 59 assert( (ext_ptr->first_free_wti < ext_ptr->wti_nr) , __FUNCTION__ ,59 assert( (ext_ptr->first_free_wti < ext_ptr->wti_nr) , 60 60 "no free WTI found : too much external IRQs\n"); 61 61 … … 146 146 if( index < LOCAL_CLUSTER->cores_nr ) // it is an IPI 147 147 { 148 assert( (index == core->lid) , __FUNCTION__ ,"illegal IPI index" );148 assert( (index == core->lid) , "illegal IPI index" ); 149 149 150 150 #if DEBUG_HAL_IRQS … … 229 229 index = pti_status - 1; 230 230 231 assert( (index == core->lid) , __FUNCTION__ ,"unconsistent PTI index\n");231 assert( (index == core->lid) , "unconsistent PTI index\n"); 232 232 233 233 #if DEBUG_HAL_IRQS … … 292 292 core_ext_ptr = kmem_alloc( &req ); 293 293 294 assert( (core_ext_ptr != NULL) , __FUNCTION__ ,294 assert( (core_ext_ptr != NULL) , 295 295 "cannot allocate memory for core extension\n"); 296 296 … … 309 309 cluster_ext_ptr = kmem_alloc( &req ); 310 310 311 assert( (cluster_ext_ptr != NULL) , __FUNCTION__ ,311 assert( (cluster_ext_ptr != NULL) , 312 312 "cannot allocate memory for cluster extension\n"); 313 313 … … 381 381 else if( (func == DEV_FUNC_NIC) && !is_rx ) hwi_id = iopic_input.nic_tx[channel]; 382 382 else if( func == DEV_FUNC_IOB ) hwi_id = iopic_input.iob; 383 else assert( false , __FUNCTION__ ,"illegal device functionnal type\n");383 else assert( false , "illegal device functionnal type\n"); 384 384 385 385 // get a WTI mailbox from local XCU descriptor … … 439 439 else 440 440 { 441 assert( false , __FUNCTION__ ,"illegal device functionnal type\n" );441 assert( false , "illegal device functionnal type\n" ); 442 442 } 443 443 } // end soclib_pic_bind_irq(); … … 474 474 else 475 475 { 476 assert( false , __FUNCTION__ ,"illegal IRQ type\n" );476 assert( false , "illegal IRQ type\n" ); 477 477 } 478 478 } // end soclib_pic_enable_irq() … … 509 509 else 510 510 { 511 assert( false , __FUNCTION__ ,"illegal IRQ type\n" );511 assert( false , "illegal IRQ type\n" ); 512 512 } 513 513 } // end soclib_pic_enable_irq() -
trunk/hal/tsar_mips32/drivers/soclib_tty.c
r457 r492 233 233 else 234 234 { 235 assert( false , __FUNCTION__ ,"illegal TXT command\n" );235 assert( false , "illegal TXT command\n" ); 236 236 } 237 237 … … 329 329 330 330 // check process exist 331 assert( (owner_xp != XPTR_NULL) , __FUNCTION__,331 assert( (owner_xp != XPTR_NULL) , 332 332 "TXT owner process not found\n" ); 333 333 … … 387 387 388 388 // check process exist 389 assert( (owner_xp != XPTR_NULL) , __FUNCTION__,389 assert( (owner_xp != XPTR_NULL) , 390 390 "TXT owner process not found\n" ); 391 391
Note: See TracChangeset
for help on using the changeset viewer.