Ignore:
Timestamp:
Nov 20, 2020, 12:30:31 AM (4 years ago)
Author:
alain
Message:

Mainly cosmetic.

Location:
trunk/hal/tsar_mips32/drivers
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/hal/tsar_mips32/drivers/soclib_bdv.c

    r657 r679  
    8989    if     ( (cmd_type == IOC_READ)  || (cmd_type == IOC_SYNC_READ)  ) op = BDV_OP_READ;
    9090    else if( (cmd_type == IOC_WRITE) || (cmd_type == IOC_SYNC_WRITE) ) op = BDV_OP_WRITE;
    91     else     assert( false , "illegal command" );
     91    else     assert( __FUNCTION__, false , "illegal command" );
    9292
    9393    // get cluster and local pointer on IOC chdev
     
    317317    else
    318318    {
    319         assert( false , "illegal command %d", cmd_type );
     319        assert( __FUNCTION__, false , "illegal command %d", cmd_type );
    320320    }
    321321
  • trunk/hal/tsar_mips32/drivers/soclib_fbf.c

    r657 r679  
    6363    uint32_t   npixels;     // number of pixels to move
    6464    xptr_t     fbf_xp;      // extended pointer on FBF chdev descriptor
    65     uint32_t   status;      // I/0 operation status (from BDV)
    6665    void     * buffer;      // pointer on kernel or user buffer
    6766
  • trunk/hal/tsar_mips32/drivers/soclib_hba.c

    r570 r679  
    188188        {
    189189            // fatal if synchronous access
    190             assert( cmd_type == IOC_SYNC_READ, "no slot available for a IOC_SYNC_READ\n" );
     190            assert( __FUNCTION__, cmd_type == IOC_SYNC_READ, "no slot available for a IOC_SYNC_READ\n" );
    191191            sched_yield( "blocked on ISR" );
    192192        }
  • trunk/hal/tsar_mips32/drivers/soclib_memc.c

    r494 r679  
    172172        uint_t *dst;
    173173
    174         assert(rq->file != NULL, "rq->file should'nt be NULL.\n");
     174        assert( __FUNCTION__,rq->file != NULL, "rq->file should'nt be NULL.\n");
    175175
    176176        count = rq->count >> 2; /* 32 bits registers */
  • trunk/hal/tsar_mips32/drivers/soclib_mty.c

    r587 r679  
    230230    else
    231231    {
    232         assert( false , __FUNCTION__ , "illegal TXT command\n" );
     232        assert( __FUNCTION__, false , "illegal TXT command\n" );
    233233    }
    234234
     
    321321               
    322322                    // check process exist
    323                     assert( (owner_xp != XPTR_NULL) , __FUNCTION__,
    324                     "TXT owner process not found\n" );
     323                    assert( __FUNCTION__, (owner_xp != XPTR_NULL) , "TXT owner process not found\n" );
    325324
    326325                    // get relevant infos on TXT owner process
     
    376375
    377376                    // check process exist
    378                     assert( (owner_xp != XPTR_NULL) , __FUNCTION__,
    379                     "TXT owner process not found\n" );
     377                    assert( __FUNCTION__, (owner_xp != XPTR_NULL) , "TXT owner process not found\n" );
    380378
    381379                    // get relevant infos on TXT owner process
  • trunk/hal/tsar_mips32/drivers/soclib_nic.c

    r658 r679  
    268268
    269269// check calling thread == client thread
    270 assert( (thread_xp == XPTR( local_cxy , this )), "calling thread must be the client thread");
     270assert( __FUNCTION__, (thread_xp == XPTR( local_cxy , this )), "calling thread must be the client thread");
    271271 
    272272    // get command type
     
    286286
    287287// check chdev is local
    288 assert( (dev_cxy == local_cxy), "illegal cluster for a WRITE command");
     288assert( __FUNCTION__, (dev_cxy == local_cxy), "illegal cluster for a WRITE command");
    289289           
    290290            // get command arguments
     
    293293
    294294// check packet length
    295 assert( (length <= 2040), "packet length too large");
     295assert( __FUNCTION__, (length <= 2040), "packet length too large");
    296296
    297297            // get chbuf descriptor pointer
     
    377377
    378378// check chdev is local
    379 assert( (dev_cxy == local_cxy), "illegal cluster for a READ command");
     379assert( __FUNCTION__, (dev_cxy == local_cxy), "illegal cluster for a READ command");
    380380           
    381381            // get target buffer
     
    604604        default:
    605605        {
    606             assert( false, "Unknown command <%x>\n", type );
     606            assert( __FUNCTION__, false, "Unknown command <%x>\n", type );
    607607        }
    608608    }
  • trunk/hal/tsar_mips32/drivers/soclib_pic.c

    r635 r679  
    5858    soclib_pic_cluster_t * ext_ptr = LOCAL_CLUSTER->pic_extend;
    5959
    60     assert( (ext_ptr->first_free_wti < ext_ptr->wti_nr) ,
     60    assert( __FUNCTION__, (ext_ptr->first_free_wti < ext_ptr->wti_nr) ,
    6161            "no free WTI found : too much external IRQs\n");
    6262
     
    147147        if( index < LOCAL_CLUSTER->cores_nr )   // it is an IPI
    148148        {
    149             assert( (index == core->lid) , "illegal IPI index" );
     149            assert( __FUNCTION__, (index == core->lid) , "illegal IPI index" );
    150150
    151151#if DEBUG_HAL_IRQS
     
    230230        index = pti_status - 1;
    231231
    232         assert( (index == core->lid) , "unconsistent PTI index\n");
     232        assert( __FUNCTION__, (index == core->lid) , "unconsistent PTI index\n");
    233233
    234234#if DEBUG_HAL_IRQS
     
    319319    }
    320320   
    321 assert( (cluster_ext_ptr != NULL) , "cannot allocate memory for cluster extension");
     321assert( __FUNCTION__, (cluster_ext_ptr != NULL) , "cannot allocate memory for cluster extension");
    322322
    323323    // get XCU characteristics from the XCU config register
     
    381381
    382382    if( (func == DEV_FUNC_IOC && impl == IMPL_IOC_BDV) || (func == DEV_FUNC_NIC) ||
    383         (func == DEV_FUNC_TXT && impl == IMPL_TXT_TTY) || (func == DEV_FUNC_IOB) )          // external IRQ => WTI
     383        (func == DEV_FUNC_TXT && impl == IMPL_TXT_TTY) || (func == DEV_FUNC_IOB) ) // external IRQ => WTI
    384384    {
    385385        // get external IRQ index
    386         uint32_t  hwi_id;   
     386        uint32_t  hwi_id = 0;   
    387387        if     (  func == DEV_FUNC_IOC            ) hwi_id = iopic_input.ioc[channel];
    388388        else if(  func == DEV_FUNC_TXT  &&  is_rx ) hwi_id = iopic_input.txt_rx[channel];
     
    391391        else if( (func == DEV_FUNC_NIC) && !is_rx ) hwi_id = iopic_input.nic_tx[channel];
    392392        else if(  func == DEV_FUNC_IOB            ) hwi_id = iopic_input.iob;
    393         else      assert( false , "illegal device functionnal type\n");
     393        else      assert( __FUNCTION__, false , "illegal device functionnal type\n");
    394394
    395395        // get a WTI mailbox from local XCU descriptor 
     
    453453    else
    454454    {
    455         assert( false , "illegal device functionnal type\n" );
     455        assert( __FUNCTION__, false , "illegal device functionnal type\n" );
    456456    }
    457457}  // end soclib_pic_bind_irq();
     
    488488    else
    489489    {
    490         assert( false , "illegal IRQ type\n" );
     490        assert( __FUNCTION__, false , "illegal IRQ type\n" );
    491491    }
    492492} // end soclib_pic_enable_irq()
     
    523523    else
    524524    {
    525         assert( false , "illegal IRQ type\n" );
     525        assert( __FUNCTION__, false , "illegal IRQ type\n" );
    526526    }
    527527} // end soclib_pic_enable_irq()
  • trunk/hal/tsar_mips32/drivers/soclib_sdc.c

    r619 r679  
    3636static void _sdc_enable(sdcard_dev_t *sdcard)
    3737{
    38     spi_ss_assert(sdcard->spi, sdcard->slave_id);
     38    spi_ss_assert( __FUNCTION__,sdcard->spi, sdcard->slave_id);
    3939}
    4040
     
    4444static void _sdc_disable(sdcard_dev_t *sdcard)
    4545{
    46     spi_ss_deassert(sdcard->spi, sdcard->slave_id);
     46    spi_ss_deassert( __FUNCTION__,sdcard->spi, sdcard->slave_id);
    4747}
    4848
     
    375375        if (++iter >= SDCARD_RESET_ITER_MAX)
    376376        {
    377             assert( false, __FUNCTION__, "\n[SDC ERROR] During SD card reset / card response = %x \n", sdcard_rsp);
     377            assert( __FUNCTION__, false, __FUNCTION__, "\n[SDC ERROR] During SD card reset / card response = %x \n", sdcard_rsp);
    378378        }
    379379    }
     
    383383    if (sdcard_rsp)
    384384    {
    385         assert( false, __FUNCTION__, "[SDC ERROR] During SD card block size initialization\n");
     385        assert( __FUNCTION__, false, __FUNCTION__, "[SDC ERROR] During SD card block size initialization\n");
    386386    }
    387387
     
    465465    else            // write access
    466466    {
    467         assert( false, __FUNCTION__, "[SDC ERROR] function _sdc_write() not iplemented yet\n");
     467        assert( __FUNCTION__, false, __FUNCTION__, "[SDC ERROR] function _sdc_write() not iplemented yet\n");
    468468    }
    469469}  // _end sdc_access()
     
    474474void __attribute__ ((noinline)) soclib_sdc_isr( chdev_t * chdev )
    475475{
    476     assert( false, __FUNCTION__, "\n[GIET ERROR] _sdc_isr() not implemented\n");
     476    assert( __FUNCTION__, false, __FUNCTION__, "\n[GIET ERROR] _sdc_isr() not implemented\n");
    477477}
    478478
  • trunk/hal/tsar_mips32/drivers/soclib_spi.c

    r619 r679  
    197197
    198198///////////////////////////////////////////////////////////////////////////////
    199 //      spi_ss_assert()
     199//      spi_ss_assert( __FUNCTION__,)
    200200// This function enables a SPI slave
    201201// - spi   : initialized pointer to the SPI controller
    202202// - index : slave index
    203203///////////////////////////////////////////////////////////////////////////////
    204 void spi_ss_assert(struct spi_dev * spi, int index)
     204void spi_ss_assert( __FUNCTION__,struct spi_dev * spi, int index)
    205205{
    206206    unsigned int spi_ss = ioread32(&spi->ss);
     
    210210
    211211///////////////////////////////////////////////////////////////////////////////
    212 //      spi_ss_deassert()
     212//      spi_ss_deassert( __FUNCTION__,)
    213213// This function disables a SPI slave
    214214// - spi   : initialized pointer to the SPI controller
    215215// - index : slave index
    216216///////////////////////////////////////////////////////////////////////////////
    217 void spi_ss_deassert(struct spi_dev * spi, int index)
     217void spi_ss_deassert( __FUNCTION__,struct spi_dev * spi, int index)
    218218{
    219219    unsigned int spi_ss = ioread32(&spi->ss);
  • trunk/hal/tsar_mips32/drivers/soclib_tty.c

    r658 r679  
    243243    else
    244244    {
    245         assert( false , "illegal TXT command\n" );
     245        assert( __FUNCTION__, false , "illegal TXT command\n" );
    246246    }
    247247
     
    338338               
    339339                // check process exist
    340                 assert( (owner_xp != XPTR_NULL) ,
     340                assert( __FUNCTION__, (owner_xp != XPTR_NULL) ,
    341341                "TXT owner process not found\n" );
    342342
     
    347347
    348348// TXT owner cannot be the INIT process
    349 assert( (owner_pid != 1) , "INIT process cannot be the TXT owner" );
     349assert( __FUNCTION__, (owner_pid != 1) , "INIT process cannot be the TXT owner" );
    350350
    351351                // get parent process descriptor pointers
     
    390390
    391391// check process exist
    392 assert( (owner_xp != XPTR_NULL) , "TXT owner process not found\n" );
     392assert( __FUNCTION__, (owner_xp != XPTR_NULL) , "TXT owner process not found\n" );
    393393
    394394                // get relevant infos on TXT owner process
     
    398398
    399399// TXT owner cannot be the INIT process
    400 assert( (owner_pid != 1) , "INIT process cannot be the TXT owner" );
     400assert( __FUNCTION__, (owner_pid != 1) , "INIT process cannot be the TXT owner" );
    401401
    402402#if DEBUG_HAL_TXT_RX
Note: See TracChangeset for help on using the changeset viewer.