Changeset 492 for trunk/kernel/fs/vfs.c
- Timestamp:
- Aug 22, 2018, 11:55:48 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/fs/vfs.c
r484 r492 171 171 { 172 172 ctx = NULL; 173 assert( false , __FUNCTION__ ,"illegal file system type = %d\n" , fs_type );173 assert( false , "illegal file system type = %d\n" , fs_type ); 174 174 } 175 175 … … 250 250 error_t vfs_inode_destroy( vfs_inode_t * inode ) 251 251 { 252 assert( (inode->refcount == 0) , __FUNCTION__, "inode refcount non zero\n" );252 assert( (inode->refcount == 0) , "inode refcount non zero\n" ); 253 253 254 254 // release memory allocated for mapper … … 280 280 error_t error = 0; 281 281 282 assert( (parent != NULL) , __FUNCTION__ ,"parent pointer is NULL\n");283 284 assert( (child_xp != XPTR_NULL) , __FUNCTION__ ,"child pointer is NULL\n");282 assert( (parent != NULL) , "parent pointer is NULL\n"); 283 284 assert( (child_xp != XPTR_NULL) , "child pointer is NULL\n"); 285 285 286 286 // get parent inode FS type … … 294 294 else if( fs_type == FS_TYPE_RAMFS ) 295 295 { 296 assert( false , __FUNCTION__ ,"should not be called for RAMFS\n" );296 assert( false , "should not be called for RAMFS\n" ); 297 297 } 298 298 else if( fs_type == FS_TYPE_DEVFS ) 299 299 { 300 assert( false , __FUNCTION__ ,"should not be called for DEVFS\n" );300 assert( false , "should not be called for DEVFS\n" ); 301 301 } 302 302 else 303 303 { 304 assert( false , __FUNCTION__ ,"undefined file system type\n" );304 assert( false , "undefined file system type\n" ); 305 305 } 306 306 … … 581 581 if( file->refcount ) 582 582 { 583 assert( false , __FUNCTION__ ,"refcount non zero\n" );583 assert( false , "refcount non zero\n" ); 584 584 } 585 585 … … 713 713 uint32_t size ) 714 714 { 715 assert( ( file_xp != XPTR_NULL ) , __FUNCTION__ ,"file_xp == XPTR_NULL" );715 assert( ( file_xp != XPTR_NULL ) , "file_xp == XPTR_NULL" ); 716 716 717 717 cxy_t file_cxy; // remote file descriptor cluster … … 729 729 inode_type = hal_remote_lw( XPTR( file_cxy , &file_ptr->type ) ); 730 730 731 assert( (inode_type == INODE_TYPE_FILE) , __FUNCTION__ ,731 assert( (inode_type == INODE_TYPE_FILE) , 732 732 "inode type is not INODE_TYPE_FILE" ); 733 733 … … 768 768 uint32_t size ) 769 769 { 770 assert( ( file_xp != XPTR_NULL ) , __FUNCTION__ ,"file_xp == XPTR_NULL" );770 assert( ( file_xp != XPTR_NULL ) , "file_xp == XPTR_NULL" ); 771 771 772 772 cxy_t file_cxy; // remote file descriptor cluster … … 835 835 uint32_t new; 836 836 837 assert( (file_xp != XPTR_NULL) , __FUNCTION__ ,"file_xp == XPTR_NULL" );837 assert( (file_xp != XPTR_NULL) , "file_xp == XPTR_NULL" ); 838 838 839 839 // get cluster and local pointer on remote file descriptor … … 899 899 process_t * process_ptr; // process copy local pointer 900 900 901 assert( (file_xp != XPTR_NULL) , __FUNCTION__ ,"file_xp == XPTR_NULL" );902 903 assert( (file_id < CONFIG_PROCESS_FILE_MAX_NR) , __FUNCTION__ ,"illegal file_id" );901 assert( (file_xp != XPTR_NULL) , "file_xp == XPTR_NULL" ); 902 903 assert( (file_id < CONFIG_PROCESS_FILE_MAX_NR) , "illegal file_id" ); 904 904 905 905 thread_t * this = CURRENT_THREAD; … … 996 996 char * path ) 997 997 { 998 assert( false , __FUNCTION__ , "not implemented\n", cwd_xp, path ); 998 assert( false , "not implemented cwd_xp %x, path <%s> \n", 999 cwd_xp, path ); 999 1000 return 0; 1000 1001 } … … 1004 1005 struct stat * k_stat ) 1005 1006 { 1006 assert( false , __FUNCTION__ , "not implemented\n", file_xp, k_stat ); 1007 assert( false , "not implemented file_xp: %x, k_stat ptr %x\n", 1008 file_xp, k_stat ); 1007 1009 return 0; 1008 1010 } … … 1012 1014 struct dirent * k_dirent ) 1013 1015 { 1014 assert( false , __FUNCTION__ , "not implemented\n", file_xp, k_dirent ); 1016 assert( false , "not implemented file_xp: %x, k_dirent ptr %x\n", 1017 file_xp, k_dirent ); 1015 1018 return 0; 1016 1019 } … … 1021 1024 uint32_t mode ) 1022 1025 { 1023 assert( false , __FUNCTION__ , "not implemented\n", file_xp, path, mode ); 1026 assert( false , "not implemented file_xp: %x, path <%s>, mode: %x\n", 1027 file_xp, path, mode ); 1024 1028 return 0; 1025 1029 } … … 1029 1033 char * path ) 1030 1034 { 1031 assert( false , __FUNCTION__ , "not implemented\n", file_xp, path ); 1035 assert( false , "not implemented file_xp: %x, path <%s>\n", 1036 file_xp, path ); 1032 1037 return 0; 1033 1038 } … … 1065 1070 } 1066 1071 1067 assert( false , __FUNCTION__ ,"not implemented\n" );1072 assert( false , "not implemented\n" ); 1068 1073 return 0; 1069 1074 } … … 1097 1102 1098 1103 1099 assert( false , __FUNCTION__ ,"not implemented\n" );1104 assert( false , "not implemented\n" ); 1100 1105 return 0; 1101 1106 } … … 1106 1111 uint32_t rights ) 1107 1112 { 1108 assert( false , __FUNCTION__ , "not implemented\n", cwd_xp, path, rights ); 1113 assert( false , "not implemented cwd_xp: %x, path <%s>, rights %x\n", 1114 cwd_xp, path, rights ); 1109 1115 return 0; 1110 1116 } … … 1168 1174 " " }; // level 15 1169 1175 1170 assert( (inode_xp != XPTR_NULL) , __FUNCTION__ ,"inode_xp cannot be NULL\n" );1171 assert( (name_xp != XPTR_NULL) , __FUNCTION__ ,"name_xp cannot be NULL\n" );1172 assert( (indent < 16) , __FUNCTION__ ,"depth cannot be larger than 15\n" );1176 assert( (inode_xp != XPTR_NULL) , "inode_xp cannot be NULL\n" ); 1177 assert( (name_xp != XPTR_NULL) , "name_xp cannot be NULL\n" ); 1178 assert( (indent < 16) , "depth cannot be larger than 15\n" ); 1173 1179 1174 1180 // get inode cluster and local pointer … … 1944 1950 error_t error = 0; 1945 1951 1946 assert( (page != NULL) , __FUNCTION__ ,"page pointer is NULL\n" );1952 assert( (page != NULL) , "page pointer is NULL\n" ); 1947 1953 1948 1954 mapper_t * mapper = page->mapper; 1949 1955 1950 assert( (mapper != NULL) , __FUNCTION__ ,"no mapper for page\n" );1956 assert( (mapper != NULL) , "no mapper for page\n" ); 1951 1957 1952 1958 #if DEBUG_VFS_MAPPER_MOVE … … 1969 1975 else if( fs_type == FS_TYPE_RAMFS ) 1970 1976 { 1971 assert( false , __FUNCTION__ ,"should not be called for RAMFS\n" );1977 assert( false , "should not be called for RAMFS\n" ); 1972 1978 } 1973 1979 else if( fs_type == FS_TYPE_DEVFS ) 1974 1980 { 1975 assert( false , __FUNCTION__ ,"should not be called for DEVFS\n" );1981 assert( false , "should not be called for DEVFS\n" ); 1976 1982 } 1977 1983 else 1978 1984 { 1979 assert( false , __FUNCTION__ ,"undefined file system type\n" );1985 assert( false , "undefined file system type\n" ); 1980 1986 } 1981 1987 … … 1994 2000 error_t vfs_mapper_load_all( vfs_inode_t * inode ) 1995 2001 { 1996 assert( (inode != NULL) , __FUNCTION__ ,"inode pointer is NULL\n" );2002 assert( (inode != NULL) , "inode pointer is NULL\n" ); 1997 2003 1998 2004 uint32_t index; … … 2002 2008 uint32_t size = inode->size; 2003 2009 2004 assert( (mapper != NULL) , __FUNCTION__ ,"mapper pointer is NULL\n" );2010 assert( (mapper != NULL) , "mapper pointer is NULL\n" ); 2005 2011 2006 2012 #if DEBUG_VFS_MAPPER_LOAD
Note: See TracChangeset
for help on using the changeset viewer.