Changeset 598 for trunk/kernel/fs/vfs.c


Ignore:
Timestamp:
Nov 10, 2018, 3:06:00 PM (3 years ago)
Author:
alain
Message:

1) Modify the devfs_user_move() function to support large user buffer transfer to/from TXT device.
2) Cosmetic: Improve debug.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/fs/vfs.c

    r568 r598  
    126126//////////////////////////////////////////////////////////////////////////////////////////
    127127
    128 static const char * vfs_inode_type_str( vfs_inode_type_t type )
    129 {
    130     switch ( type ) {
    131     case INODE_TYPE_FILE: return "FILE";
    132     case INODE_TYPE_DIR:  return "DIR ";
    133     case INODE_TYPE_FIFO: return "FIFO";
    134     case INODE_TYPE_PIPE: return "PIPE";
    135     case INODE_TYPE_SOCK: return "SOCK";
    136     case INODE_TYPE_DEV:  return "DEV ";
    137     case INODE_TYPE_SYML: return "SYML";
    138     default:              return "undefined";
     128const char * vfs_inode_type_str( vfs_inode_type_t type )
     129{
     130    switch ( type )
     131    {
     132        case INODE_TYPE_FILE: return "FILE";
     133        case INODE_TYPE_DIR:  return "DIR ";
     134        case INODE_TYPE_FIFO: return "FIFO";
     135        case INODE_TYPE_PIPE: return "PIPE";
     136        case INODE_TYPE_SOCK: return "SOCK";
     137        case INODE_TYPE_DEV:  return "DEV ";
     138        case INODE_TYPE_SYML: return "SYML";
     139        default:              return "undefined";
    139140    }
    140141}
     
    168169else                         strcpy( name , "/" );
    169170if( DEBUG_VFS_INODE_CREATE < cycle )
    170 printk("\n[DBG] %s : thread %x in process %x enter for <%s> / cycle %d\n",
    171 __FUNCTION__, this->trdid, this->process->pid, name, cycle );
     171printk("\n[%s] thread[%x,%x] enter for <%s> / cycle %d\n",
     172__FUNCTION__, this->process->pid, this->trdid, name, cycle );
    172173#endif
    173174 
     
    247248cycle      = (uint32_t)hal_get_cycles();
    248249if( DEBUG_VFS_INODE_CREATE < cycle )
    249 printk("\n[DBG] %s : thread %x in process %x exit for <%s> / inode [%x,%x] / cycle %d\n",
    250 __FUNCTION__, this->trdid, this->process->pid, name, local_cxy, inode, cycle );
     250printk("\n[%s] thread[%x,%x] exit for <%s> / inode [%x,%x] / cycle %d\n",
     251__FUNCTION__, this->process->pid, this->trdid, name, local_cxy, inode, cycle );
    251252#endif
    252253 
     
    284285uint32_t cycle = (uint32_t)hal_get_cycles();
    285286if( DEBUG_VFS_INODE_LOAD < cycle )
    286 printk("\n[DBG] %s : thread %x enter for <%s> / cycle %d\n",
     287printk("\n[%s] thread %x enter for <%s> / cycle %d\n",
    287288__FUNCTION__, CURRENT_THREAD , name , cycle );
    288289#endif
     
    318319cycle = (uint32_t)hal_get_cycles();
    319320if( DEBUG_VFS_INODE_LOAD < cycle )
    320 printk("\n[DBG] %s : thread %x exit for <%s> / cycle %d\n",
     321printk("\n[%s] thread %x exit for <%s> / cycle %d\n",
    321322__FUNCTION__, CURRENT_THREAD , name , cycle );
    322323#endif
     
    444445
    445446#if DEBUG_VFS_DENTRY_CREATE
     447thread_t * this = CURRENT_THREAD;
    446448uint32_t cycle = (uint32_t)hal_get_cycles();
    447449if( DEBUG_VFS_DENTRY_CREATE < cycle )
    448 printk("\n[DBG] %s : thread %x in process %x enter for <%s> / parent_inode %x / cycle %d\n",
    449 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, name, parent, cycle );
     450printk("\n[%s] thread[%x,%x] enter for <%s> / parent_inode %x / cycle %d\n",
     451__FUNCTION__, this->process->pid, this->trdid, name, parent, cycle );
    450452#endif
    451453
     
    483485cycle = (uint32_t)hal_get_cycles();
    484486if( DEBUG_VFS_DENTRY_CREATE < cycle )
    485 printk("\n[DBG] %s : thread %x in process %x / dentry <%s> initialised / cycle %d\n",
    486 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, dentry->name, cycle );
     487printk("\n[%s] thread[%x,%x] / dentry <%s> initialised / cycle %d\n",
     488__FUNCTION__, this->process->pid, this->trdid, dentry->name, cycle );
    487489#endif
    488490
     
    497499cycle = (uint32_t)hal_get_cycles();
    498500if( DEBUG_VFS_DENTRY_CREATE < cycle )
    499 printk("\n[DBG] %s : thread %x in process %x / dentry <%s> registered / cycle %d\n",
    500 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, dentry->name, cycle );
     501printk("\n[%s] thread[%x,%x] / dentry <%s> registered / cycle %d\n",
     502__FUNCTION__, this->process->pid, this->trdid, dentry->name, cycle );
    501503#endif
    502504
     
    507509cycle = (uint32_t)hal_get_cycles();
    508510if( DEBUG_VFS_DENTRY_CREATE < cycle )
    509 printk("\n[DBG] %s : thread %x in process %x exit for <%s> / dentry %x / cycle %d\n",
    510 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, name, dentry, cycle );
     511printk("\n[%s] thread[%x,%x] exit for <%s> / dentry %x / cycle %d\n",
     512__FUNCTION__, this->process->pid, this->trdid, name, dentry, cycle );
    511513#endif
    512514
     
    556558
    557559#if DEBUG_VFS_FILE_CREATE
     560thread_t * this = CURRENT_THREAD;
    558561uint32_t cycle = (uint32_t)hal_get_cycles();
    559562if( DEBUG_VFS_OPEN < cycle )
    560 printk("\n[DBG] %s : thread %x in process %x enter for inode %x in cluster %x / cycle %d\n",
    561 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, inode, local_cxy, cycle );
     563printk("\n[%s] thread[%x,%x] enter for inode %x in cluster %x / cycle %d\n",
     564__FUNCTION__, this->process->pid, this->trdid, inode, local_cxy, cycle );
    562565#endif
    563566
     
    587590cycle = (uint32_t)hal_get_cycles();
    588591if( DEBUG_VFS_OPEN < cycle )
    589 printk("\n[DBG] %s : thread %x in process %x created file %x in cluster %x / cycle %d\n",
    590 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, file, local_cxy, cycle );
     592printk("\n[%s] thread[%x,%x] created file %x in cluster %x / cycle %d\n",
     593__FUNCTION__, this->process->pid, this->trdid, file, local_cxy, cycle );
    591594#endif
    592595
     
    609612
    610613#if DEBUG_VFS_CLOSE
     614thread_t * this = CURRENT_THREAD;
    611615uint32_t cycle = (uint32_t)hal_get_cycles();
    612616if( DEBUG_VFS_CLOSE < cycle )
    613 printk("\n[DBG] %s : thread %x in process %x deleted file %x in cluster %x / cycle %d\n",
    614 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, file, local_cxy, cycle );
     617printk("\n[%s] thread[%x,%x] deleted file %x in cluster %x / cycle %d\n",
     618__FUNCTION__, this->process->pid, this->trdid, file, local_cxy, cycle );
    615619#endif
    616620
     
    665669
    666670#if DEBUG_VFS_OPEN
     671thread_t * this = CURRENT_THREAD;
    667672uint32_t cycle = (uint32_t)hal_get_cycles();
    668673if( DEBUG_VFS_OPEN < cycle )
    669 printk("\n[DBG] %s :  thread %x in process %x enter for <%s> / cycle %d\n",
    670 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, path, cycle );
     674printk("\n[%s]   thread[%x,%x] enter for <%s> / cycle %d\n",
     675__FUNCTION__, this->process->pid, this->trdid, path, cycle );
    671676#endif
    672677
     
    714719cycle = (uint32_t)hal_get_cycles();
    715720if( DEBUG_VFS_OPEN < cycle )
    716 printk("\n[DBG] %s :  thread %x in process %x exit for <%s> / fdid %d / cluster %x / cycle %d\n",
    717 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_THREAD->process->pid, path,
    718 file_id, GET_CXY( file_xp ), cycle );
     721printk("\n[%s]   thread[%x,%x] exit for <%s> / fdid %d / cluster %x / cycle %d\n",
     722__FUNCTION__, this->process->pid, this->trdid, path, file_id, GET_CXY( file_xp ), cycle );
    719723#endif
    720724
     
    928932uint32_t cycle = (uint32_t)hal_get_cycles();
    929933if( DEBUG_VFS_CLOSE < cycle )
    930 printk("\n[DBG] %s : thread %x in process %x enter / fdid %d / cycle %d\n",
    931 __FUNCTION__, this->trdid, process->pid, file_id, cycle );
     934printk("\n[%s] thread[%x,%x] enter / fdid %d / cycle %d\n",
     935__FUNCTION__, process->pid, this->trdid, file_id, cycle );
    932936#endif
    933937
     
    956960#if (DEBUG_VFS_CLOSE & 1 )
    957961if( DEBUG_VFS_CLOSE < cycle )
    958 printk("\n[DBG] %s : reset fd_array[%d] for process %x in cluster %x\n",
     962printk("\n[%s] reset fd_array[%d] for process %x in cluster %x\n",
    959963__FUNCTION__, file_id, process_ptr, process_cxy );
    960964#endif
     
    981985#if (DEBUG_VFS_CLOSE & 1)
    982986if( DEBUG_VFS_CLOSE < cycle )
    983 printk("\n[DBG] %s : thread %x in process %x reset all fd-array copies\n",
    984 __FUNCTION__, this->trdid, process->pid );
     987printk("\n[%s] thread[%x,%x] reset all fd-array copies\n",
     988__FUNCTION__, process->pid, this->trdid );
    985989#endif
    986990
     
    10031007cycle = (uint32_t)hal_get_cycles();
    10041008if( DEBUG_VFS_CLOSE < cycle )
    1005 printk("\n[DBG] %s : thread %x in process %x exit / fdid %d closed / cycle %d\n",
    1006 __FUNCTION__, this->trdid, process->pid, file_id, cycle );
     1009printk("\n[%s] thread[%x,%x] exit / fdid %d closed / cycle %d\n",
     1010__FUNCTION__, process->pid, this->trdid, file_id, cycle );
    10071011#endif
    10081012
     
    10201024}
    10211025
    1022 ////////////////////////////////////////
    1023 error_t vfs_stat( xptr_t        file_xp,
    1024                   struct stat * k_stat )
    1025 {
    1026     assert( false , "not implemented file_xp: %x, k_stat ptr %x\n",
    1027       file_xp, k_stat );
     1026//////////////////////////////////////
     1027error_t vfs_stat( xptr_t     inode_xp,
     1028                  stat_t   * st )
     1029{
     1030    // get cluster and local pointer on inode descriptor
     1031    vfs_inode_t * inode_ptr = GET_PTR( inode_xp );
     1032    cxy_t         inode_cxy = GET_CXY( inode_xp );
     1033
     1034    // get relevant infos from inode descriptor
     1035    uint32_t inum   = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->inum   ) );
     1036    uint32_t size   = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->size   ) );
     1037    uint32_t uid    = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->uid    ) );
     1038    uint32_t gid    = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->gid    ) );
     1039    uint32_t type   = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->type   ) );
     1040    uint32_t rights = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->rights ) );
     1041
     1042    // set stat structure fields
     1043    st->st_ino  = inum;
     1044    st->st_gid  = gid;
     1045    st->st_uid  = uid;
     1046    st->st_size = size;
     1047    st->st_mode = (type << 16) | rights;
     1048
     1049#if DEBUG_VFS_STAT
     1050uint32_t cycle  = (uint32_t)hal_get_cycles();
     1051thread_t * this = CURRENT_THREAD;
     1052if( DEBUG_VFS_STAT < cycle )
     1053printk("\n[%s] thread[%x,%x] set stat %x for inode %x in cluster %x / cycle %d\n"
     1054       " %s / inum %d / size %d\n",
     1055__FUNCTION__, this->process->pid, this->trdid, st, inode_ptr, inode_cxy, cycle,
     1056vfs_inode_type_str( type ), inum, size );
     1057#endif
     1058
    10281059    return 0;
    10291060}
     
    11551186    vfs_inode_t      * inode_ptr;
    11561187    vfs_inode_type_t   inode_type;
     1188    uint32_t           inode_size;
     1189    uint32_t           inode_inum;
     1190    uint32_t           inode_attr;
     1191    uint32_t           inode_dirty;
    11571192    xptr_t             children_xp;    // extended pointer on children xhtab
    11581193
     
    11621197    xptr_t             child_inode_xp;
    11631198    xptr_t             child_dentry_name_xp;
     1199    mapper_t         * mapper_ptr;
    11641200
    11651201    char               name[CONFIG_VFS_MAX_NAME_LENGTH];
     
    11821218                                        "                              " };  // level 15
    11831219
    1184     assert( (inode_xp != XPTR_NULL) , "inode_xp cannot be NULL\n" );
    1185     assert( (name_xp  != XPTR_NULL) , "name_xp cannot be NULL\n" );
    1186     assert( (indent < 16)           , "depth cannot be larger than 15\n" );
     1220assert( (inode_xp != XPTR_NULL) , "inode_xp cannot be NULL\n" );
     1221assert( (name_xp  != XPTR_NULL) , "name_xp cannot be NULL\n" );
     1222assert( (indent < 16)           , "depth cannot be larger than 15\n" );
    11871223   
    11881224    // get inode cluster and local pointer
     
    11901226    inode_ptr = GET_PTR( inode_xp );
    11911227
    1192     // get inode type
    1193     inode_type = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->type ) );
    1194 
    1195     // get local pointer on associated mapper
    1196     mapper_t * mapper_ptr = hal_remote_lpt( XPTR( inode_cxy , &inode_ptr->mapper ) );
     1228    // get inode type, size, attr, mapper, and inum
     1229    inode_type = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->type   ) );
     1230    inode_size = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->size   ) );
     1231    inode_inum = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->inum   ) );
     1232    inode_attr = hal_remote_l32( XPTR( inode_cxy , &inode_ptr->attr   ) );
     1233    mapper_ptr = hal_remote_lpt( XPTR( inode_cxy , &inode_ptr->mapper ) );
    11971234
    11981235    // make a local copy of node name
    11991236    hal_remote_strcpy( XPTR( local_cxy , name ) , name_xp );
    12001237
     1238    // compute dirty
     1239    inode_dirty = ((inode_attr & INODE_ATTR_DIRTY) != 0);
     1240
    12011241    // display inode
    1202     nolock_printk("%s%s <%s> : inode = %x / mapper = %x / cluster %x\n",
     1242    nolock_printk("%s%s <%s> : inum %d / %d bytes / dirty %d / cxy %x (inode %x / mapper %x)\n",
    12031243                  indent_str[indent], vfs_inode_type_str( inode_type ), name,
    1204                   inode_ptr , mapper_ptr , inode_cxy );
     1244                  inode_inum, inode_size, inode_dirty, inode_cxy, inode_ptr, mapper_ptr );
    12051245
    12061246    // scan directory entries 
     
    14471487uint32_t cycle = (uint32_t)hal_get_cycles();
    14481488if( DEBUG_VFS_LOOKUP < cycle )
    1449 printk("\n[DBG] %s : thread %x in process %x enter for <%s> / cycle %d\n",
    1450 __FUNCTION__, this->trdid, process->pid, pathname, cycle );
     1489printk("\n[%s] thread[%x,%x] enter for <%s> / cycle %d\n",
     1490__FUNCTION__, process->pid, this->trdid, pathname, cycle );
    14511491#endif
    14521492
     
    14791519#if (DEBUG_VFS_LOOKUP & 1)
    14801520if( DEBUG_VFS_LOOKUP < cycle )
    1481 printk("\n[DBG] %s : look for <%s> / last = %d\n",
     1521printk("\n[%s] look for <%s> / last = %d\n",
    14821522__FUNCTION__ , name , last );
    14831523#endif
     
    14931533#if (DEBUG_VFS_LOOKUP & 1)
    14941534if( DEBUG_VFS_LOOKUP < cycle )
    1495 printk("\n[DBG] %s : miss <%s> node => try to create it\n",
     1535printk("\n[%s] miss <%s> node => try to create it\n",
    14961536__FUNCTION__ , name );
    14971537#endif
     
    15401580#if (DEBUG_VFS_LOOKUP & 1)
    15411581if( DEBUG_VFS_LOOKUP < cycle )
    1542 printk("\n[DBG] %s : missing <%s> inode speculatively created / cxy %x / ptr %x\n",
     1582printk("\n[%s] missing <%s> inode speculatively created / cxy %x / ptr %x\n",
    15431583__FUNCTION__ , name , child_cxy, child_ptr );
    15441584#endif
     
    15671607#if (DEBUG_VFS_LOOKUP & 1)
    15681608if( DEBUG_VFS_LOOKUP < cycle )
    1569 printk("\n[DBG] %s : created node <%s> in path %s / type DIR\n",
     1609printk("\n[%s] created node <%s> in path %s / type DIR\n",
    15701610__FUNCTION__ , name, pathname );
    15711611#endif
     
    15771617#if (DEBUG_VFS_LOOKUP & 1)
    15781618if( DEBUG_VFS_LOOKUP < cycle )
    1579 printk("\n[DBG] %s : created node <%s> in path %s / type FILE\n",
     1619printk("\n[%s] created node <%s> in path %s / type FILE\n",
    15801620__FUNCTION__ , name, pathname );
    15811621#endif
     
    16141654#if (DEBUG_VFS_LOOKUP & 1)
    16151655if( DEBUG_VFS_LOOKUP < cycle )
    1616 printk("\n[DBG] %s : load mapper from device for node <%s> in path %s\n",
     1656printk("\n[%s] load mapper from device for node <%s> in path %s\n",
    16171657__FUNCTION__ , name, pathname );
    16181658#endif
     
    16281668#if (DEBUG_VFS_LOOKUP & 1)
    16291669if( DEBUG_VFS_LOOKUP < cycle )
    1630 printk("\n[DBG] %s : found <%s> / inode %x in cluster %x\n",
     1670printk("\n[%s] found <%s> / inode %x in cluster %x\n",
    16311671__FUNCTION__ , name , GET_PTR(child_xp) , GET_CXY(child_xp) );
    16321672#endif
     
    16701710cycle = (uint32_t)hal_get_cycles();
    16711711if( DEBUG_VFS_LOOKUP < cycle )
    1672 printk("\n[DBG] %s : thread %x in process %x exit for <%s>\n"
     1712printk("\n[%s] thread[%x,%x] exit for <%s>\n"
    16731713"     parent %x in cluster %x / child %x in cluster %x / cycle %d\n",
    1674 __FUNCTION__ , this->trdid, process->pid, pathname,
     1714__FUNCTION__ , process->pid, this->trdid, pathname,
    16751715parent_ptr, parent_cxy, child_ptr, child_cxy, cycle );
    16761716#endif
     
    17771817thread_t * this = CURRENT_THREAD;
    17781818if( DEBUG_VFS_ADD_CHILD < cycle )
    1779 printk("\n[DBG] %s : thread %x in process %x enter for <%s>\n"
    1780 "      child_cxy = %x / parent_cxy = %x / cycle %d\n",
    1781 __FUNCTION__, this->trdid, this->process->pid, name,
     1819printk("\n[%s] thread[%x,%x] enter for <%s> / child_cxy %x / parent_cxy %x / cycle %d\n",
     1820__FUNCTION__, this->process->pid, this->trdid, name,
    17821821child_cxy, parent_cxy, (uint32_t)hal_get_cycles() );
    17831822#endif
     
    18101849#if(DEBUG_VFS_ADD_CHILD & 1)
    18111850if( DEBUG_VFS_ADD_CHILD < cycle )
    1812 printk("\n[DBG] %s : thread %x in process %x / dentry <%s> created in cluster %x\n",
    1813 __FUNCTION__, this->trdid, this->process->pid, name, parent_cxy );
     1851printk("\n[%s] thread[%x,%x] / dentry <%s> created in cluster %x\n",
     1852__FUNCTION__, this->process->pid, this->trdid, name, parent_cxy );
    18141853#endif
    18151854
     
    18601899#if(DEBUG_VFS_ADD_CHILD & 1)
    18611900if( DEBUG_VFS_ADD_CHILD < cycle )
    1862 printk("\n[DBG] %s : thread %x in process %x / inode <%s> created in cluster %x\n",
    1863 __FUNCTION__ , this->trdid, this->process->pid, name , child_cxy );
     1901printk("\n[%s] thread[%x,%x] / inode <%s> created in cluster %x\n",
     1902__FUNCTION__ , this->process->pid, this->trdid, name , child_cxy );
    18641903#endif
    18651904
     
    18721911cycle = (uint32_t)hal_get_cycles();
    18731912if( DEBUG_VFS_ADD_CHILD < cycle )
    1874 printk("\n[DBG] %s : thread %x in process %x exit for <%s> / cycle %d\n",
    1875 __FUNCTION__, this->trdid, this->process->pid, name, (uint32_t)hal_get_cycles() );
     1913printk("\n[%s] thread[%x,%x] exit for <%s> / cycle %d\n",
     1914__FUNCTION__, this->process->pid, this->trdid, name, (uint32_t)hal_get_cycles() );
    18761915#endif
    18771916
     
    19521991
    19531992#if DEBUG_VFS_MAPPER_MOVE
    1954 uint32_t cycle = (uint32_t)hal_get_cycles();
     1993uint32_t   cycle = (uint32_t)hal_get_cycles();
     1994thread_t * this  = CURRENT_THREAD;
    19551995if( DEBUG_VFS_MAPPER_MOVE < cycle )
    1956 printk("\n[DBG] %s : thread %x enter for page %d / mapper %x / inode %x / cycle %d\n",
    1957 __FUNCTION__, CURRENT_THREAD, page->index, mapper, mapper->inode, cycle );
     1996printk("\n[%s] thread[%x,%x] enter for page %d / mapper %x / inode %x / cycle %d\n",
     1997__FUNCTION__, this->process->pid, this->trdid, page->index, mapper, mapper->inode, cycle );
    19581998#endif
    19591999
     
    19892029cycle = (uint32_t)hal_get_cycles();
    19902030if( DEBUG_VFS_MAPPER_MOVE < cycle )
    1991 printk("\n[DBG] %s : thread %x exit for page %d / mapper %x / inode %x / cycle %d\n",
    1992 __FUNCTION__, CURRENT_THREAD, page->index, mapper, mapper->inode, cycle );
     2031printk("\n[%s] thread[%x,%x] exit for page %d / mapper %x / inode %x / cycle %d\n",
     2032__FUNCTION__, this->process->pid, this->trdid, page->index, mapper, mapper->inode, cycle );
    19932033#endif
    19942034
     
    20082048    uint32_t   size   = inode->size;
    20092049
    2010     assert( (mapper != NULL) , "mapper pointer is NULL\n" );
     2050assert( (mapper != NULL) , "mapper pointer is NULL\n" );
    20112051
    20122052#if DEBUG_VFS_MAPPER_LOAD
    2013 uint32_t cycle = (uint32_t)hal_get_cycles();
     2053uint32_t   cycle = (uint32_t)hal_get_cycles();
     2054thread_t * this  = CURRENT_THREAD;
    20142055if( DEBUG_VFS_MAPPER_MOVE < cycle )
    2015 printk("\n[DBG] %s : thread %x enter for inode %x in cluster %x / cycle %d\n",
    2016 __FUNCTION__, CURRENT_THREAD, inode, local_cxy, cycle );
     2056printk("\n[%s] thread[%x,%x] enter for inode %x in cluster %x / cycle %d\n",
     2057__FUNCTION__, this->process->pid, this->trdid, inode, local_cxy, cycle );
    20172058#endif
    20182059
     
    20342075cycle = (uint32_t)hal_get_cycles();
    20352076if( DEBUG_VFS_MAPPER_MOVE < cycle )
    2036 printk("\n[DBG] %s : thread %x exit for inode %x in cluster %x / cycle %d\n",
    2037 __FUNCTION__, CURRENT_THREAD, inode, local_cxy, cycle );
     2077printk("\n[%s] thread[%x,%x] exit for inode %x in cluster %x / cycle %d\n",
     2078__FUNCTION__, this->process->pid, this->trdid, inode, local_cxy, cycle );
    20382079#endif
    20392080
Note: See TracChangeset for help on using the changeset viewer.