tag | line | file | source code |
dir | 204 | arch/alpha/kernel/traps.c | long dir, size; |
dir | 225 | arch/alpha/kernel/traps.c | dir = VERIFY_READ; |
dir | 228 | arch/alpha/kernel/traps.c | dir = VERIFY_WRITE; |
dir | 235 | arch/alpha/kernel/traps.c | if (verify_area(dir, va, size)) { |
dir | 276 | arch/alpha/kernel/traps.c | if (reg == 30 && dir == VERIFY_WRITE) { |
dir | 225 | arch/sparc/mm/srmmu.c | srmmu_pmd_offset(pgd_t * dir, unsigned long address) |
dir | 227 | arch/sparc/mm/srmmu.c | return ((pmd_t *) pgd_page(*dir)) + |
dir | 233 | arch/sparc/mm/srmmu.c | srmmu_pte_offset(pmd_t * dir, unsigned long address) |
dir | 235 | arch/sparc/mm/srmmu.c | return ((pte_t *) pmd_page(*dir)) + |
dir | 215 | arch/sparc/mm/sun4c.c | sun4c_pmd_offset(pgd_t * dir, unsigned long address) |
dir | 217 | arch/sparc/mm/sun4c.c | return (pmd_t *) dir; |
dir | 222 | arch/sparc/mm/sun4c.c | sun4c_pte_offset(pmd_t * dir, unsigned long address) |
dir | 224 | arch/sparc/mm/sun4c.c | return (pte_t *) sun4c_pmd_page(*dir) + ((address >> PAGE_SHIFT) & (SUN4C_PTRS_PER_PTE - 1)); |
dir | 358 | drivers/scsi/aha1740.c | ecb[ecbno].dir= direction; |
dir | 125 | drivers/scsi/aha1740.h | dir:1, /* Direction of transfer 1 = datain */ |
dir | 738 | drivers/scsi/buslogic.c | ccb->dir = direction; |
dir | 162 | drivers/scsi/buslogic.h | unsigned char dir; |
dir | 45 | fs/dcache.c | unsigned long dir; |
dir | 73 | fs/dcache.c | #define hash_fn(dev,dir,namehash) ((HASHDEV(dev) ^ (dir) ^ (namehash)) % DCACHE_HASH_QUEUES) |
dir | 133 | fs/dcache.c | static struct dir_cache_entry * find_entry(struct inode * dir, const char * name, int len, struct hash_list * hash) |
dir | 138 | fs/dcache.c | if (de->dc_dev != dir->i_dev) |
dir | 140 | fs/dcache.c | if (de->dir != dir->i_ino) |
dir | 142 | fs/dcache.c | if (de->version != dir->i_version) |
dir | 172 | fs/dcache.c | int dcache_lookup(struct inode * dir, const char * name, int len, unsigned long * ino) |
dir | 179 | fs/dcache.c | hash = hash_table + hash_fn(dir->i_dev, dir->i_ino, namehash(name,len)); |
dir | 180 | fs/dcache.c | de = find_entry(dir, name, len, hash); |
dir | 188 | fs/dcache.c | void dcache_add(struct inode * dir, const char * name, int len, unsigned long ino) |
dir | 195 | fs/dcache.c | hash = hash_table + hash_fn(dir->i_dev, dir->i_ino, namehash(name,len)); |
dir | 196 | fs/dcache.c | if ((de = find_entry(dir, name, len, hash)) != NULL) { |
dir | 204 | fs/dcache.c | de->dc_dev = dir->i_dev; |
dir | 205 | fs/dcache.c | de->dir = dir->i_ino; |
dir | 206 | fs/dcache.c | de->version = dir->i_version; |
dir | 239 | fs/ext/freelists.c | struct inode * ext_new_inode(const struct inode * dir) |
dir | 247 | fs/ext/freelists.c | if (!dir || !(inode=get_empty_inode())) |
dir | 249 | fs/ext/freelists.c | sb = dir->i_sb; |
dir | 286 | fs/ext/freelists.c | inode->i_gid = (dir->i_mode & S_ISGID) ? dir->i_gid : current->fsgid; |
dir | 79 | fs/ext/namei.c | static struct buffer_head * ext_find_entry(struct inode * dir, |
dir | 88 | fs/ext/namei.c | if (!dir) |
dir | 97 | fs/ext/namei.c | bh = ext_bread(dir,0,0); |
dir | 106 | fs/ext/namei.c | while (offset < dir->i_size) { |
dir | 110 | fs/ext/namei.c | bh = ext_bread(dir,offset>>BLOCK_SIZE_BITS,0); |
dir | 123 | fs/ext/namei.c | kdevname(dir->i_dev), dir->i_ino, offset, |
dir | 134 | fs/ext/namei.c | if (offset + de->rec_len < dir->i_size && |
dir | 151 | fs/ext/namei.c | int ext_lookup(struct inode * dir,const char * name, int len, |
dir | 159 | fs/ext/namei.c | if (!dir) |
dir | 161 | fs/ext/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 162 | fs/ext/namei.c | iput(dir); |
dir | 165 | fs/ext/namei.c | if (!(bh = ext_find_entry(dir,name,len,&de,NULL,NULL))) { |
dir | 166 | fs/ext/namei.c | iput(dir); |
dir | 171 | fs/ext/namei.c | if (!(*result = iget(dir->i_sb,ino))) { |
dir | 172 | fs/ext/namei.c | iput(dir); |
dir | 175 | fs/ext/namei.c | iput(dir); |
dir | 189 | fs/ext/namei.c | static struct buffer_head * ext_add_entry(struct inode * dir, |
dir | 199 | fs/ext/namei.c | if (!dir) |
dir | 210 | fs/ext/namei.c | bh = ext_bread(dir,0,0); |
dir | 217 | fs/ext/namei.c | if ((char *)de >= BLOCK_SIZE+bh->b_data && offset < dir->i_size) { |
dir | 223 | fs/ext/namei.c | bh = ext_bread(dir,offset>>BLOCK_SIZE_BITS,0); |
dir | 228 | fs/ext/namei.c | if (offset >= dir->i_size) { |
dir | 241 | fs/ext/namei.c | dir->i_size += de->rec_len; |
dir | 242 | fs/ext/namei.c | dir->i_dirt = 1; |
dir | 244 | fs/ext/namei.c | dir->i_ctime = CURRENT_TIME; |
dir | 253 | fs/ext/namei.c | bh = ext_bread(dir,offset>>BLOCK_SIZE_BITS,1); |
dir | 261 | fs/ext/namei.c | dir->i_size += de->rec_len; |
dir | 262 | fs/ext/namei.c | dir->i_dirt = 1; |
dir | 264 | fs/ext/namei.c | dir->i_ctime = CURRENT_TIME; |
dir | 273 | fs/ext/namei.c | kdevname(dir->i_dev), dir->i_ino, offset, |
dir | 291 | fs/ext/namei.c | dir->i_mtime = dir->i_ctime = CURRENT_TIME; |
dir | 292 | fs/ext/namei.c | dir->i_dirt = 1; |
dir | 307 | fs/ext/namei.c | int ext_create(struct inode * dir,const char * name, int len, int mode, |
dir | 315 | fs/ext/namei.c | if (!dir) |
dir | 317 | fs/ext/namei.c | inode = ext_new_inode(dir); |
dir | 319 | fs/ext/namei.c | iput(dir); |
dir | 325 | fs/ext/namei.c | bh = ext_add_entry(dir,name,len,&de); |
dir | 330 | fs/ext/namei.c | iput(dir); |
dir | 336 | fs/ext/namei.c | iput(dir); |
dir | 341 | fs/ext/namei.c | int ext_mknod(struct inode * dir, const char * name, int len, int mode, int rdev) |
dir | 347 | fs/ext/namei.c | if (!dir) |
dir | 349 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,NULL,NULL); |
dir | 352 | fs/ext/namei.c | iput(dir); |
dir | 355 | fs/ext/namei.c | inode = ext_new_inode(dir); |
dir | 357 | fs/ext/namei.c | iput(dir); |
dir | 367 | fs/ext/namei.c | if (dir->i_mode & S_ISGID) |
dir | 384 | fs/ext/namei.c | bh = ext_add_entry(dir,name,len,&de); |
dir | 389 | fs/ext/namei.c | iput(dir); |
dir | 395 | fs/ext/namei.c | iput(dir); |
dir | 400 | fs/ext/namei.c | int ext_mkdir(struct inode * dir, const char * name, int len, int mode) |
dir | 406 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,NULL,NULL); |
dir | 409 | fs/ext/namei.c | iput(dir); |
dir | 412 | fs/ext/namei.c | inode = ext_new_inode(dir); |
dir | 414 | fs/ext/namei.c | iput(dir); |
dir | 428 | fs/ext/namei.c | iput(dir); |
dir | 440 | fs/ext/namei.c | de->inode = dir->i_ino; |
dir | 448 | fs/ext/namei.c | if (dir->i_mode & S_ISGID) |
dir | 451 | fs/ext/namei.c | bh = ext_add_entry(dir,name,len,&de); |
dir | 453 | fs/ext/namei.c | iput(dir); |
dir | 460 | fs/ext/namei.c | dir->i_nlink++; |
dir | 461 | fs/ext/namei.c | dir->i_dirt = 1; |
dir | 462 | fs/ext/namei.c | iput(dir); |
dir | 532 | fs/ext/namei.c | int ext_rmdir(struct inode * dir, const char * name, int len) |
dir | 540 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,&pde,&nde); |
dir | 545 | fs/ext/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 547 | fs/ext/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 549 | fs/ext/namei.c | current->fsuid != dir->i_uid) |
dir | 551 | fs/ext/namei.c | if (inode->i_dev != dir->i_dev) |
dir | 553 | fs/ext/namei.c | if (inode == dir) /* we may not delete ".", but "../dir" is ok */ |
dir | 575 | fs/ext/namei.c | dir->i_nlink--; |
dir | 576 | fs/ext/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 577 | fs/ext/namei.c | dir->i_dirt=1; |
dir | 580 | fs/ext/namei.c | iput(dir); |
dir | 586 | fs/ext/namei.c | int ext_unlink(struct inode * dir, const char * name, int len) |
dir | 595 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,&pde,&nde); |
dir | 598 | fs/ext/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 601 | fs/ext/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 603 | fs/ext/namei.c | current->fsuid != dir->i_uid) |
dir | 620 | fs/ext/namei.c | dir->i_ctime = dir->i_mtime = inode->i_ctime; |
dir | 621 | fs/ext/namei.c | dir->i_dirt = 1; |
dir | 626 | fs/ext/namei.c | iput(dir); |
dir | 630 | fs/ext/namei.c | int ext_symlink(struct inode * dir, const char * name, int len, const char * symname) |
dir | 638 | fs/ext/namei.c | if (!(inode = ext_new_inode(dir))) { |
dir | 639 | fs/ext/namei.c | iput(dir); |
dir | 646 | fs/ext/namei.c | iput(dir); |
dir | 660 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,NULL,NULL); |
dir | 666 | fs/ext/namei.c | iput(dir); |
dir | 669 | fs/ext/namei.c | bh = ext_add_entry(dir,name,len,&de); |
dir | 674 | fs/ext/namei.c | iput(dir); |
dir | 680 | fs/ext/namei.c | iput(dir); |
dir | 685 | fs/ext/namei.c | int ext_link(struct inode * oldinode, struct inode * dir, const char * name, int len) |
dir | 692 | fs/ext/namei.c | iput(dir); |
dir | 697 | fs/ext/namei.c | iput(dir); |
dir | 700 | fs/ext/namei.c | bh = ext_find_entry(dir,name,len,&de,NULL,NULL); |
dir | 703 | fs/ext/namei.c | iput(dir); |
dir | 707 | fs/ext/namei.c | bh = ext_add_entry(dir,name,len,&de); |
dir | 709 | fs/ext/namei.c | iput(dir); |
dir | 716 | fs/ext/namei.c | iput(dir); |
dir | 47 | fs/ext/symlink.c | static int ext_follow_link(struct inode * dir, struct inode * inode, |
dir | 54 | fs/ext/symlink.c | if (!dir) { |
dir | 55 | fs/ext/symlink.c | dir = current->fs->root; |
dir | 56 | fs/ext/symlink.c | dir->i_count++; |
dir | 59 | fs/ext/symlink.c | iput(dir); |
dir | 63 | fs/ext/symlink.c | iput(dir); |
dir | 68 | fs/ext/symlink.c | iput(dir); |
dir | 74 | fs/ext/symlink.c | iput(dir); |
dir | 79 | fs/ext/symlink.c | error = open_namei(bh->b_data,flag,mode,res_inode,dir); |
dir | 72 | fs/ext2/dir.c | int ext2_check_dir_entry (const char * function, struct inode * dir, |
dir | 84 | fs/ext2/dir.c | else if (dir && ((char *) de - bh->b_data) + de->rec_len > |
dir | 85 | fs/ext2/dir.c | dir->i_sb->s_blocksize) |
dir | 87 | fs/ext2/dir.c | else if (dir && de->inode > dir->i_sb->u.ext2_sb.s_es->s_inodes_count) |
dir | 91 | fs/ext2/dir.c | ext2_error (dir->i_sb, function, "bad entry in directory #%lu: %s - " |
dir | 93 | fs/ext2/dir.c | dir->i_ino, error_msg, offset, (unsigned long) de->inode, |
dir | 306 | fs/ext2/ialloc.c | struct inode * ext2_new_inode (const struct inode * dir, int mode) |
dir | 318 | fs/ext2/ialloc.c | if (!dir || !(inode = get_empty_inode ())) |
dir | 320 | fs/ext2/ialloc.c | sb = dir->i_sb; |
dir | 364 | fs/ext2/ialloc.c | i = dir->u.ext2_i.i_block_group; |
dir | 389 | fs/ext2/ialloc.c | i = dir->u.ext2_i.i_block_group + 1; |
dir | 456 | fs/ext2/ialloc.c | inode->i_gid = dir->i_gid; |
dir | 457 | fs/ext2/ialloc.c | else if (dir->i_mode & S_ISGID) { |
dir | 458 | fs/ext2/ialloc.c | inode->i_gid = dir->i_gid; |
dir | 468 | fs/ext2/ialloc.c | inode->u.ext2_i.i_flags = dir->u.ext2_i.i_flags; |
dir | 68 | fs/ext2/namei.c | static struct buffer_head * ext2_find_entry (struct inode * dir, |
dir | 79 | fs/ext2/namei.c | if (!dir) |
dir | 81 | fs/ext2/namei.c | sb = dir->i_sb; |
dir | 96 | fs/ext2/namei.c | if ((block << EXT2_BLOCK_SIZE_BITS (sb)) >= dir->i_size) |
dir | 98 | fs/ext2/namei.c | bh = ext2_getblk (dir, block, 0, &err); |
dir | 104 | fs/ext2/namei.c | for (block = 0, offset = 0; offset < dir->i_size; block++) { |
dir | 117 | fs/ext2/namei.c | dir->i_ino, offset); |
dir | 132 | fs/ext2/namei.c | if (!ext2_check_dir_entry ("ext2_find_entry", dir, |
dir | 150 | fs/ext2/namei.c | dir->i_size) |
dir | 153 | fs/ext2/namei.c | bh = ext2_getblk (dir, block + NAMEI_RA_SIZE, 0, &err); |
dir | 165 | fs/ext2/namei.c | int ext2_lookup (struct inode * dir, const char * name, int len, |
dir | 173 | fs/ext2/namei.c | if (!dir) |
dir | 175 | fs/ext2/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 176 | fs/ext2/namei.c | iput (dir); |
dir | 179 | fs/ext2/namei.c | if (dcache_lookup(dir, name, len, &ino)) { |
dir | 181 | fs/ext2/namei.c | iput(dir); |
dir | 184 | fs/ext2/namei.c | if (!(*result = iget (dir->i_sb, ino))) { |
dir | 185 | fs/ext2/namei.c | iput (dir); |
dir | 188 | fs/ext2/namei.c | iput (dir); |
dir | 191 | fs/ext2/namei.c | ino = dir->i_version; |
dir | 192 | fs/ext2/namei.c | if (!(bh = ext2_find_entry (dir, name, len, &de))) { |
dir | 193 | fs/ext2/namei.c | if (ino == dir->i_version) |
dir | 194 | fs/ext2/namei.c | dcache_add(dir, name, len, 0); |
dir | 195 | fs/ext2/namei.c | iput (dir); |
dir | 199 | fs/ext2/namei.c | dcache_add(dir, name, len, ino); |
dir | 201 | fs/ext2/namei.c | if (!(*result = iget (dir->i_sb, ino))) { |
dir | 202 | fs/ext2/namei.c | iput (dir); |
dir | 205 | fs/ext2/namei.c | iput (dir); |
dir | 219 | fs/ext2/namei.c | static struct buffer_head * ext2_add_entry (struct inode * dir, |
dir | 232 | fs/ext2/namei.c | if (!dir) |
dir | 234 | fs/ext2/namei.c | sb = dir->i_sb; |
dir | 247 | fs/ext2/namei.c | if (dir->i_size == 0) |
dir | 252 | fs/ext2/namei.c | bh = ext2_bread (dir, 0, 0, err); |
dir | 263 | fs/ext2/namei.c | bh = ext2_bread (dir, offset >> EXT2_BLOCK_SIZE_BITS(sb), 1, err); |
dir | 266 | fs/ext2/namei.c | if (dir->i_size <= offset) { |
dir | 267 | fs/ext2/namei.c | if (dir->i_size == 0) { |
dir | 277 | fs/ext2/namei.c | dir->i_size = offset + sb->s_blocksize; |
dir | 278 | fs/ext2/namei.c | dir->i_dirt = 1; |
dir | 286 | fs/ext2/namei.c | if (!ext2_check_dir_entry ("ext2_add_entry", dir, de, bh, |
dir | 322 | fs/ext2/namei.c | dir->i_mtime = dir->i_ctime = CURRENT_TIME; |
dir | 323 | fs/ext2/namei.c | dir->i_dirt = 1; |
dir | 324 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 341 | fs/ext2/namei.c | static int ext2_delete_entry (struct ext2_dir_entry * dir, |
dir | 354 | fs/ext2/namei.c | if (de == dir) { |
dir | 356 | fs/ext2/namei.c | pde->rec_len += dir->rec_len; |
dir | 357 | fs/ext2/namei.c | dir->inode = 0; |
dir | 367 | fs/ext2/namei.c | int ext2_create (struct inode * dir,const char * name, int len, int mode, |
dir | 376 | fs/ext2/namei.c | if (!dir) |
dir | 378 | fs/ext2/namei.c | inode = ext2_new_inode (dir, mode); |
dir | 380 | fs/ext2/namei.c | iput (dir); |
dir | 386 | fs/ext2/namei.c | bh = ext2_add_entry (dir, name, len, &de, &err); |
dir | 391 | fs/ext2/namei.c | iput (dir); |
dir | 395 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 396 | fs/ext2/namei.c | dcache_add(dir, de->name, de->name_len, de->inode); |
dir | 398 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 403 | fs/ext2/namei.c | iput (dir); |
dir | 408 | fs/ext2/namei.c | int ext2_mknod (struct inode * dir, const char * name, int len, int mode, |
dir | 416 | fs/ext2/namei.c | if (!dir) |
dir | 418 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 421 | fs/ext2/namei.c | iput (dir); |
dir | 424 | fs/ext2/namei.c | inode = ext2_new_inode (dir, mode); |
dir | 426 | fs/ext2/namei.c | iput (dir); |
dir | 436 | fs/ext2/namei.c | if (dir->i_mode & S_ISGID) |
dir | 450 | fs/ext2/namei.c | bh = ext2_add_entry (dir, name, len, &de, &err); |
dir | 455 | fs/ext2/namei.c | iput (dir); |
dir | 459 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 460 | fs/ext2/namei.c | dcache_add(dir, de->name, de->name_len, de->inode); |
dir | 462 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 467 | fs/ext2/namei.c | iput (dir); |
dir | 472 | fs/ext2/namei.c | int ext2_mkdir (struct inode * dir, const char * name, int len, int mode) |
dir | 479 | fs/ext2/namei.c | if (!dir) |
dir | 481 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 484 | fs/ext2/namei.c | iput (dir); |
dir | 487 | fs/ext2/namei.c | if (dir->i_nlink >= EXT2_LINK_MAX) { |
dir | 488 | fs/ext2/namei.c | iput (dir); |
dir | 491 | fs/ext2/namei.c | inode = ext2_new_inode (dir, S_IFDIR); |
dir | 493 | fs/ext2/namei.c | iput (dir); |
dir | 500 | fs/ext2/namei.c | iput (dir); |
dir | 513 | fs/ext2/namei.c | de->inode = dir->i_ino; |
dir | 521 | fs/ext2/namei.c | if (dir->i_mode & S_ISGID) |
dir | 524 | fs/ext2/namei.c | bh = ext2_add_entry (dir, name, len, &de, &err); |
dir | 526 | fs/ext2/namei.c | iput (dir); |
dir | 533 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 534 | fs/ext2/namei.c | dcache_add(dir, de->name, de->name_len, de->inode); |
dir | 536 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 540 | fs/ext2/namei.c | dir->i_nlink++; |
dir | 541 | fs/ext2/namei.c | dir->i_dirt = 1; |
dir | 542 | fs/ext2/namei.c | iput (dir); |
dir | 607 | fs/ext2/namei.c | int ext2_rmdir (struct inode * dir, const char * name, int len) |
dir | 615 | fs/ext2/namei.c | if (!dir) |
dir | 618 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 623 | fs/ext2/namei.c | if (!(inode = iget (dir->i_sb, de->inode))) |
dir | 625 | fs/ext2/namei.c | if (inode->i_dev != dir->i_dev) |
dir | 634 | fs/ext2/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 636 | fs/ext2/namei.c | current->fsuid != dir->i_uid) |
dir | 638 | fs/ext2/namei.c | if (inode == dir) /* we may not delete ".", but "../dir" is ok */ |
dir | 661 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 667 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 678 | fs/ext2/namei.c | dir->i_nlink--; |
dir | 679 | fs/ext2/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 680 | fs/ext2/namei.c | dir->i_dirt = 1; |
dir | 682 | fs/ext2/namei.c | iput (dir); |
dir | 688 | fs/ext2/namei.c | int ext2_unlink (struct inode * dir, const char * name, int len) |
dir | 696 | fs/ext2/namei.c | if (!dir) |
dir | 700 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 703 | fs/ext2/namei.c | if (!(inode = iget (dir->i_sb, de->inode))) |
dir | 717 | fs/ext2/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 719 | fs/ext2/namei.c | current->fsuid != dir->i_uid) |
dir | 730 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 732 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 736 | fs/ext2/namei.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 737 | fs/ext2/namei.c | dir->i_dirt = 1; |
dir | 740 | fs/ext2/namei.c | inode->i_ctime = dir->i_ctime; |
dir | 745 | fs/ext2/namei.c | iput (dir); |
dir | 749 | fs/ext2/namei.c | int ext2_symlink (struct inode * dir, const char * name, int len, |
dir | 760 | fs/ext2/namei.c | if (!(inode = ext2_new_inode (dir, S_IFLNK))) { |
dir | 761 | fs/ext2/namei.c | iput (dir); |
dir | 775 | fs/ext2/namei.c | iput (dir); |
dir | 798 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 804 | fs/ext2/namei.c | iput (dir); |
dir | 807 | fs/ext2/namei.c | bh = ext2_add_entry (dir, name, len, &de, &err); |
dir | 812 | fs/ext2/namei.c | iput (dir); |
dir | 816 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 817 | fs/ext2/namei.c | dcache_add(dir, de->name, de->name_len, de->inode); |
dir | 819 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 824 | fs/ext2/namei.c | iput (dir); |
dir | 829 | fs/ext2/namei.c | int ext2_link (struct inode * oldinode, struct inode * dir, |
dir | 838 | fs/ext2/namei.c | iput (dir); |
dir | 843 | fs/ext2/namei.c | iput (dir); |
dir | 848 | fs/ext2/namei.c | iput (dir); |
dir | 851 | fs/ext2/namei.c | bh = ext2_find_entry (dir, name, len, &de); |
dir | 854 | fs/ext2/namei.c | iput (dir); |
dir | 858 | fs/ext2/namei.c | bh = ext2_add_entry (dir, name, len, &de, &err); |
dir | 860 | fs/ext2/namei.c | iput (dir); |
dir | 865 | fs/ext2/namei.c | dir->i_version = ++event; |
dir | 866 | fs/ext2/namei.c | dcache_add(dir, de->name, de->name_len, de->inode); |
dir | 868 | fs/ext2/namei.c | if (IS_SYNC(dir)) { |
dir | 873 | fs/ext2/namei.c | iput (dir); |
dir | 52 | fs/ext2/symlink.c | static int ext2_follow_link(struct inode * dir, struct inode * inode, |
dir | 60 | fs/ext2/symlink.c | if (!dir) { |
dir | 61 | fs/ext2/symlink.c | dir = current->fs->root; |
dir | 62 | fs/ext2/symlink.c | dir->i_count++; |
dir | 65 | fs/ext2/symlink.c | iput (dir); |
dir | 69 | fs/ext2/symlink.c | iput (dir); |
dir | 74 | fs/ext2/symlink.c | iput (dir); |
dir | 80 | fs/ext2/symlink.c | iput (dir); |
dir | 88 | fs/ext2/symlink.c | error = open_namei (link, flag, mode, res_inode, dir); |
dir | 1116 | fs/hpfs/hpfs_fs.c | static int hpfs_lookup(struct inode *dir, const char *name, int len, |
dir | 1127 | fs/hpfs/hpfs_fs.c | if (dir == 0) |
dir | 1129 | fs/hpfs/hpfs_fs.c | if (!S_ISDIR(dir->i_mode)) |
dir | 1138 | fs/hpfs/hpfs_fs.c | de = map_dirent(dir, dir->i_hpfs_dno, "\001\001", 2, &qbh); |
dir | 1140 | fs/hpfs/hpfs_fs.c | de = map_dirent(dir, |
dir | 1141 | fs/hpfs/hpfs_fs.c | fnode_dno(dir->i_dev, dir->i_hpfs_parent_dir), |
dir | 1144 | fs/hpfs/hpfs_fs.c | de = map_dirent(dir, dir->i_hpfs_dno, name, len, &qbh); |
dir | 1166 | fs/hpfs/hpfs_fs.c | if (!(inode = iget(dir->i_sb, ino))) |
dir | 1199 | fs/hpfs/hpfs_fs.c | iput(dir); |
dir | 1208 | fs/hpfs/hpfs_fs.c | iput(dir); |
dir | 65 | fs/isofs/namei.c | static struct buffer_head * isofs_find_entry(struct inode * dir, |
dir | 68 | fs/isofs/namei.c | unsigned long bufsize = ISOFS_BUFFER_SIZE(dir); |
dir | 69 | fs/isofs/namei.c | unsigned char bufbits = ISOFS_BUFFER_BITS(dir); |
dir | 81 | fs/isofs/namei.c | if (!dir) return NULL; |
dir | 83 | fs/isofs/namei.c | if (!(block = dir->u.isofs_i.i_first_extent)) return NULL; |
dir | 88 | fs/isofs/namei.c | block = isofs_bmap(dir,f_pos >> bufbits); |
dir | 90 | fs/isofs/namei.c | if (!block || !(bh = bread(dir->i_dev,block,bufsize))) return NULL; |
dir | 92 | fs/isofs/namei.c | while (f_pos < dir->i_size) { |
dir | 94 | fs/isofs/namei.c | backlink = dir->i_ino; |
dir | 105 | fs/isofs/namei.c | block = isofs_bmap(dir,f_pos>>bufbits); |
dir | 106 | fs/isofs/namei.c | if (!block || !(bh = bread(dir->i_dev,block,bufsize))) |
dir | 127 | fs/isofs/namei.c | block = isofs_bmap(dir,f_pos>>bufbits); |
dir | 128 | fs/isofs/namei.c | if (!block || !(bh = bread(dir->i_dev,block,bufsize))) { |
dir | 138 | fs/isofs/namei.c | inode_number = dir->i_ino; |
dir | 147 | fs/isofs/namei.c | dir->i_sb->s_firstdatazone, |
dir | 148 | fs/isofs/namei.c | dir->i_ino); |
dir | 150 | fs/isofs/namei.c | if((dir->i_sb->u.isofs_sb.s_firstdatazone) != dir->i_ino) |
dir | 151 | fs/isofs/namei.c | inode_number = dir->u.isofs_i.i_backlink; |
dir | 153 | fs/isofs/namei.c | inode_number = dir->i_ino; |
dir | 160 | fs/isofs/namei.c | rrflag = get_rock_ridge_filename(de, &dpnt, &dlen, dir); |
dir | 164 | fs/isofs/namei.c | if(dir->i_sb->u.isofs_sb.s_mapping == 'n') { |
dir | 185 | fs/isofs/namei.c | if( !(de->flags[-dir->i_sb->u.isofs_sb.s_high_sierra] & 5) |
dir | 186 | fs/isofs/namei.c | || dir->i_sb->u.isofs_sb.s_unhide == 'y' ) |
dir | 202 | fs/isofs/namei.c | isofs_lookup_grandparent(dir, |
dir | 203 | fs/isofs/namei.c | find_rock_ridge_relocation(de,dir)); |
dir | 222 | fs/isofs/namei.c | int isofs_lookup(struct inode * dir,const char * name, int len, |
dir | 229 | fs/isofs/namei.c | printk("lookup: %x %d\n",dir->i_ino, len); |
dir | 232 | fs/isofs/namei.c | if (!dir) |
dir | 235 | fs/isofs/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 236 | fs/isofs/namei.c | iput(dir); |
dir | 242 | fs/isofs/namei.c | if (dcache_lookup(dir, name, len, &ino)) ino_back = dir->i_ino; |
dir | 245 | fs/isofs/namei.c | if (!(bh = isofs_find_entry(dir,name,len, &ino, &ino_back))) { |
dir | 246 | fs/isofs/namei.c | iput(dir); |
dir | 249 | fs/isofs/namei.c | if (ino_back == dir->i_ino) |
dir | 250 | fs/isofs/namei.c | dcache_add(dir, name, len, ino); |
dir | 254 | fs/isofs/namei.c | if (!(*result = iget(dir->i_sb,ino))) { |
dir | 255 | fs/isofs/namei.c | iput(dir); |
dir | 265 | fs/isofs/namei.c | if (ino_back && !(*result)->i_pipe && (*result)->i_sb == dir->i_sb) { |
dir | 269 | fs/isofs/namei.c | iput(dir); |
dir | 49 | fs/isofs/symlink.c | static int isofs_follow_link(struct inode * dir, struct inode * inode, |
dir | 55 | fs/isofs/symlink.c | if (!dir) { |
dir | 56 | fs/isofs/symlink.c | dir = current->fs->root; |
dir | 57 | fs/isofs/symlink.c | dir->i_count++; |
dir | 60 | fs/isofs/symlink.c | iput(dir); |
dir | 65 | fs/isofs/symlink.c | iput(dir); |
dir | 71 | fs/isofs/symlink.c | iput(dir); |
dir | 78 | fs/isofs/symlink.c | error = open_namei(pnt,flag,mode,res_inode,dir); |
dir | 164 | fs/minix/bitmap.c | struct inode * minix_new_inode(const struct inode * dir) |
dir | 171 | fs/minix/bitmap.c | if (!dir || !(inode = get_empty_inode())) |
dir | 173 | fs/minix/bitmap.c | sb = dir->i_sb; |
dir | 200 | fs/minix/bitmap.c | inode->i_gid = (dir->i_mode & S_ISGID) ? dir->i_gid : current->fsgid; |
dir | 68 | fs/minix/namei.c | static struct buffer_head * minix_find_entry(struct inode * dir, |
dir | 76 | fs/minix/namei.c | if (!dir || !dir->i_sb) |
dir | 78 | fs/minix/namei.c | info = &dir->i_sb->u.minix_sb; |
dir | 88 | fs/minix/namei.c | while (block*BLOCK_SIZE+offset < dir->i_size) { |
dir | 90 | fs/minix/namei.c | bh = minix_bread(dir,block,0); |
dir | 111 | fs/minix/namei.c | int minix_lookup(struct inode * dir,const char * name, int len, |
dir | 119 | fs/minix/namei.c | if (!dir) |
dir | 121 | fs/minix/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 122 | fs/minix/namei.c | iput(dir); |
dir | 125 | fs/minix/namei.c | if (!(bh = minix_find_entry(dir,name,len,&de))) { |
dir | 126 | fs/minix/namei.c | iput(dir); |
dir | 131 | fs/minix/namei.c | if (!(*result = iget(dir->i_sb,ino))) { |
dir | 132 | fs/minix/namei.c | iput(dir); |
dir | 135 | fs/minix/namei.c | iput(dir); |
dir | 149 | fs/minix/namei.c | static int minix_add_entry(struct inode * dir, |
dir | 162 | fs/minix/namei.c | if (!dir || !dir->i_sb) |
dir | 164 | fs/minix/namei.c | info = &dir->i_sb->u.minix_sb; |
dir | 178 | fs/minix/namei.c | bh = minix_bread(dir,block,1); |
dir | 184 | fs/minix/namei.c | if (block*bh->b_size + offset > dir->i_size) { |
dir | 186 | fs/minix/namei.c | dir->i_size = block*bh->b_size + offset; |
dir | 187 | fs/minix/namei.c | dir->i_dirt = 1; |
dir | 195 | fs/minix/namei.c | dir->i_mtime = dir->i_ctime = CURRENT_TIME; |
dir | 196 | fs/minix/namei.c | dir->i_dirt = 1; |
dir | 199 | fs/minix/namei.c | dir->i_version = ++event; |
dir | 215 | fs/minix/namei.c | int minix_create(struct inode * dir,const char * name, int len, int mode, |
dir | 224 | fs/minix/namei.c | if (!dir) |
dir | 226 | fs/minix/namei.c | inode = minix_new_inode(dir); |
dir | 228 | fs/minix/namei.c | iput(dir); |
dir | 234 | fs/minix/namei.c | error = minix_add_entry(dir,name,len, &bh ,&de); |
dir | 239 | fs/minix/namei.c | iput(dir); |
dir | 245 | fs/minix/namei.c | iput(dir); |
dir | 250 | fs/minix/namei.c | int minix_mknod(struct inode * dir, const char * name, int len, int mode, int rdev) |
dir | 257 | fs/minix/namei.c | if (!dir) |
dir | 259 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 262 | fs/minix/namei.c | iput(dir); |
dir | 265 | fs/minix/namei.c | inode = minix_new_inode(dir); |
dir | 267 | fs/minix/namei.c | iput(dir); |
dir | 277 | fs/minix/namei.c | if (dir->i_mode & S_ISGID) |
dir | 291 | fs/minix/namei.c | error = minix_add_entry(dir, name, len, &bh, &de); |
dir | 296 | fs/minix/namei.c | iput(dir); |
dir | 302 | fs/minix/namei.c | iput(dir); |
dir | 307 | fs/minix/namei.c | int minix_mkdir(struct inode * dir, const char * name, int len, int mode) |
dir | 315 | fs/minix/namei.c | if (!dir || !dir->i_sb) { |
dir | 316 | fs/minix/namei.c | iput(dir); |
dir | 319 | fs/minix/namei.c | info = &dir->i_sb->u.minix_sb; |
dir | 320 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 323 | fs/minix/namei.c | iput(dir); |
dir | 326 | fs/minix/namei.c | if (dir->i_nlink >= MINIX_LINK_MAX) { |
dir | 327 | fs/minix/namei.c | iput(dir); |
dir | 330 | fs/minix/namei.c | inode = minix_new_inode(dir); |
dir | 332 | fs/minix/namei.c | iput(dir); |
dir | 339 | fs/minix/namei.c | iput(dir); |
dir | 349 | fs/minix/namei.c | de->inode = dir->i_ino; |
dir | 355 | fs/minix/namei.c | if (dir->i_mode & S_ISGID) |
dir | 358 | fs/minix/namei.c | error = minix_add_entry(dir, name, len, &bh, &de); |
dir | 360 | fs/minix/namei.c | iput(dir); |
dir | 367 | fs/minix/namei.c | dir->i_nlink++; |
dir | 368 | fs/minix/namei.c | dir->i_dirt = 1; |
dir | 369 | fs/minix/namei.c | iput(dir); |
dir | 434 | fs/minix/namei.c | int minix_rmdir(struct inode * dir, const char * name, int len) |
dir | 442 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 447 | fs/minix/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 449 | fs/minix/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 451 | fs/minix/namei.c | current->fsuid != dir->i_uid) |
dir | 453 | fs/minix/namei.c | if (inode->i_dev != dir->i_dev) |
dir | 455 | fs/minix/namei.c | if (inode == dir) /* we may not delete ".", but "../dir" is ok */ |
dir | 476 | fs/minix/namei.c | dir->i_version = ++event; |
dir | 480 | fs/minix/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 481 | fs/minix/namei.c | dir->i_nlink--; |
dir | 482 | fs/minix/namei.c | dir->i_dirt=1; |
dir | 485 | fs/minix/namei.c | iput(dir); |
dir | 491 | fs/minix/namei.c | int minix_unlink(struct inode * dir, const char * name, int len) |
dir | 501 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 504 | fs/minix/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 516 | fs/minix/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 518 | fs/minix/namei.c | current->fsuid != dir->i_uid) |
dir | 531 | fs/minix/namei.c | dir->i_version = ++event; |
dir | 533 | fs/minix/namei.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 534 | fs/minix/namei.c | dir->i_dirt = 1; |
dir | 536 | fs/minix/namei.c | inode->i_ctime = dir->i_ctime; |
dir | 542 | fs/minix/namei.c | iput(dir); |
dir | 546 | fs/minix/namei.c | int minix_symlink(struct inode * dir, const char * name, int len, const char * symname) |
dir | 554 | fs/minix/namei.c | if (!(inode = minix_new_inode(dir))) { |
dir | 555 | fs/minix/namei.c | iput(dir); |
dir | 562 | fs/minix/namei.c | iput(dir); |
dir | 576 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 582 | fs/minix/namei.c | iput(dir); |
dir | 585 | fs/minix/namei.c | i = minix_add_entry(dir, name, len, &bh, &de); |
dir | 590 | fs/minix/namei.c | iput(dir); |
dir | 596 | fs/minix/namei.c | iput(dir); |
dir | 601 | fs/minix/namei.c | int minix_link(struct inode * oldinode, struct inode * dir, const char * name, int len) |
dir | 609 | fs/minix/namei.c | iput(dir); |
dir | 614 | fs/minix/namei.c | iput(dir); |
dir | 617 | fs/minix/namei.c | bh = minix_find_entry(dir,name,len,&de); |
dir | 620 | fs/minix/namei.c | iput(dir); |
dir | 624 | fs/minix/namei.c | error = minix_add_entry(dir, name, len, &bh, &de); |
dir | 626 | fs/minix/namei.c | iput(dir); |
dir | 633 | fs/minix/namei.c | iput(dir); |
dir | 45 | fs/minix/symlink.c | static int minix_follow_link(struct inode * dir, struct inode * inode, |
dir | 52 | fs/minix/symlink.c | if (!dir) { |
dir | 53 | fs/minix/symlink.c | dir = current->fs->root; |
dir | 54 | fs/minix/symlink.c | dir->i_count++; |
dir | 57 | fs/minix/symlink.c | iput(dir); |
dir | 61 | fs/minix/symlink.c | iput(dir); |
dir | 67 | fs/minix/symlink.c | iput(dir); |
dir | 72 | fs/minix/symlink.c | iput(dir); |
dir | 77 | fs/minix/symlink.c | error = open_namei(bh->b_data,flag,mode,res_inode,dir); |
dir | 287 | fs/msdos/misc.c | int msdos_get_entry(struct inode *dir, loff_t *pos,struct buffer_head **bh, |
dir | 290 | fs/msdos/misc.c | struct super_block *sb = dir->i_sb; |
dir | 296 | fs/msdos/misc.c | if ((sector = msdos_smap(dir,offset >> SECTOR_BITS)) == -1) |
dir | 305 | fs/msdos/misc.c | if (!(*bh = bread(dir->i_dev,sector,SECTOR_SIZE))) { |
dir | 480 | fs/msdos/misc.c | int msdos_parent_ino(struct inode *dir,int locked) |
dir | 485 | fs/msdos/misc.c | if (!S_ISDIR(dir->i_mode)) panic("Non-directory fed to m_p_i"); |
dir | 486 | fs/msdos/misc.c | if (dir->i_ino == MSDOS_ROOT_INO) return dir->i_ino; |
dir | 488 | fs/msdos/misc.c | if ((current = raw_scan(dir->i_sb,MSDOS_I(dir)->i_start,MSDOS_DOTDOT, |
dir | 495 | fs/msdos/misc.c | if ((prev = raw_scan(dir->i_sb,current,MSDOS_DOTDOT,&zero,NULL, |
dir | 500 | fs/msdos/misc.c | if ((error = raw_scan(dir->i_sb,prev,NULL,¤t,&nr,NULL, |
dir | 516 | fs/msdos/misc.c | int msdos_subdirs(struct inode *dir) |
dir | 521 | fs/msdos/misc.c | if (dir->i_ino == MSDOS_ROOT_INO) |
dir | 522 | fs/msdos/misc.c | (void) raw_scan_root(dir->i_sb,NULL,&count,NULL,NULL,NULL); |
dir | 524 | fs/msdos/misc.c | if (!MSDOS_I(dir)->i_start) return 0; /* in mkdir */ |
dir | 525 | fs/msdos/misc.c | else (void) raw_scan_nonroot(dir->i_sb,MSDOS_I(dir)->i_start, |
dir | 537 | fs/msdos/misc.c | int msdos_scan(struct inode *dir,const char *name,struct buffer_head **res_bh, |
dir | 543 | fs/msdos/misc.c | res = raw_scan(dir->i_sb,MSDOS_I(dir)->i_start,name,NULL,ino, |
dir | 545 | fs/msdos/misc.c | else res = raw_scan(dir->i_sb,MSDOS_I(dir)->i_start,NULL,NULL,ino, |
dir | 102 | fs/msdos/namei.c | static int msdos_find(struct inode *dir,const char *name,int len, |
dir | 108 | fs/msdos/namei.c | res = msdos_format_name(MSDOS_SB(dir->i_sb)->name_check,name,len, msdos_name,1); |
dir | 111 | fs/msdos/namei.c | return msdos_scan(dir,msdos_name,bh,de,ino); |
dir | 115 | fs/msdos/namei.c | int msdos_lookup(struct inode *dir,const char *name,int len, |
dir | 118 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 127 | fs/msdos/namei.c | if (!dir) return -ENOENT; |
dir | 128 | fs/msdos/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 129 | fs/msdos/namei.c | iput(dir); |
dir | 134 | fs/msdos/namei.c | *result = dir; |
dir | 138 | fs/msdos/namei.c | ino = msdos_parent_ino(dir,0); |
dir | 139 | fs/msdos/namei.c | iput(dir); |
dir | 141 | fs/msdos/namei.c | if (!(*result = iget(dir->i_sb,ino))) return -EACCES; |
dir | 145 | fs/msdos/namei.c | if ((res = msdos_find(dir,name,len,&bh,&de,&ino)) < 0) { |
dir | 146 | fs/msdos/namei.c | iput(dir); |
dir | 153 | fs/msdos/namei.c | if (!(*result = iget(dir->i_sb,ino))) { |
dir | 154 | fs/msdos/namei.c | iput(dir); |
dir | 160 | fs/msdos/namei.c | iput(dir); |
dir | 168 | fs/msdos/namei.c | fs_panic(dir->i_sb,"msdos_lookup: Can't happen"); |
dir | 169 | fs/msdos/namei.c | iput(dir); |
dir | 174 | fs/msdos/namei.c | iput(dir); |
dir | 182 | fs/msdos/namei.c | static int msdos_create_entry(struct inode *dir,const char *name,int is_dir, |
dir | 185 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 190 | fs/msdos/namei.c | if ((res = msdos_scan(dir,NULL,&bh,&de,&ino)) < 0) { |
dir | 192 | fs/msdos/namei.c | if (dir->i_ino == MSDOS_ROOT_INO) return -ENOSPC; |
dir | 193 | fs/msdos/namei.c | if ((res = msdos_add_cluster(dir)) < 0) return res; |
dir | 194 | fs/msdos/namei.c | if ((res = msdos_scan(dir,NULL,&bh,&de,&ino)) < 0) return res; |
dir | 199 | fs/msdos/namei.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 200 | fs/msdos/namei.c | dir->i_dirt = 1; |
dir | 205 | fs/msdos/namei.c | date_unix2dos(dir->i_mtime,&de->time,&de->date); |
dir | 208 | fs/msdos/namei.c | if ((*result = iget(dir->i_sb,ino)) != NULL) |
dir | 219 | fs/msdos/namei.c | int msdos_create(struct inode *dir,const char *name,int len,int mode, |
dir | 222 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 228 | fs/msdos/namei.c | if (!dir) return -ENOENT; |
dir | 229 | fs/msdos/namei.c | if ((res = msdos_format_name(MSDOS_SB(dir->i_sb)->name_check,name,len, |
dir | 231 | fs/msdos/namei.c | iput(dir); |
dir | 235 | fs/msdos/namei.c | if (msdos_scan(dir,msdos_name,&bh,&de,&ino) >= 0) { |
dir | 238 | fs/msdos/namei.c | iput(dir); |
dir | 241 | fs/msdos/namei.c | res = msdos_create_entry(dir,msdos_name,S_ISDIR(mode),result); |
dir | 243 | fs/msdos/namei.c | iput(dir); |
dir | 268 | fs/msdos/namei.c | int msdos_mkdir(struct inode *dir,const char *name,int len,int mode) |
dir | 270 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 277 | fs/msdos/namei.c | if ((res = msdos_format_name(MSDOS_SB(dir->i_sb)->name_check,name,len, |
dir | 279 | fs/msdos/namei.c | iput(dir); |
dir | 283 | fs/msdos/namei.c | if (msdos_scan(dir,msdos_name,&bh,&de,&ino) >= 0) { |
dir | 286 | fs/msdos/namei.c | iput(dir); |
dir | 289 | fs/msdos/namei.c | if ((res = msdos_create_entry(dir,msdos_name,1,&inode)) < 0) { |
dir | 291 | fs/msdos/namei.c | iput(dir); |
dir | 294 | fs/msdos/namei.c | dir->i_nlink++; |
dir | 308 | fs/msdos/namei.c | dot->i_size = dir->i_size; |
dir | 309 | fs/msdos/namei.c | MSDOS_I(dot)->i_start = MSDOS_I(dir)->i_start; |
dir | 310 | fs/msdos/namei.c | dot->i_nlink = dir->i_nlink; |
dir | 315 | fs/msdos/namei.c | iput(dir); |
dir | 319 | fs/msdos/namei.c | if (msdos_rmdir(dir,name,len) < 0) |
dir | 320 | fs/msdos/namei.c | fs_panic(dir->i_sb,"rmdir in mkdir failed"); |
dir | 326 | fs/msdos/namei.c | static int msdos_empty(struct inode *dir) |
dir | 328 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 333 | fs/msdos/namei.c | if (dir->i_count > 1) |
dir | 335 | fs/msdos/namei.c | if (MSDOS_I(dir)->i_start) { /* may be zero in mkdir */ |
dir | 338 | fs/msdos/namei.c | while (msdos_get_entry(dir,&pos,&bh,&de) > -1) |
dir | 352 | fs/msdos/namei.c | int msdos_rmdir(struct inode *dir,const char *name,int len) |
dir | 354 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 365 | fs/msdos/namei.c | if ((res = msdos_find(dir,name,len,&bh,&de,&ino)) < 0) goto rmdir_done; |
dir | 367 | fs/msdos/namei.c | if (!(inode = iget(dir->i_sb,ino))) goto rmdir_done; |
dir | 371 | fs/msdos/namei.c | if (dir->i_dev != inode->i_dev || dir == inode) |
dir | 377 | fs/msdos/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 378 | fs/msdos/namei.c | dir->i_nlink--; |
dir | 379 | fs/msdos/namei.c | inode->i_dirt = dir->i_dirt = 1; |
dir | 385 | fs/msdos/namei.c | iput(dir); |
dir | 392 | fs/msdos/namei.c | struct inode *dir, |
dir | 397 | fs/msdos/namei.c | struct super_block *sb = dir->i_sb; |
dir | 405 | fs/msdos/namei.c | if ((res = msdos_find(dir,name,len,&bh,&de,&ino)) < 0) |
dir | 407 | fs/msdos/namei.c | if (!(inode = iget(dir->i_sb,ino))) { |
dir | 416 | fs/msdos/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 418 | fs/msdos/namei.c | inode->i_dirt = dir->i_dirt = 1; |
dir | 424 | fs/msdos/namei.c | iput(dir); |
dir | 428 | fs/msdos/namei.c | int msdos_unlink(struct inode *dir,const char *name,int len) |
dir | 430 | fs/msdos/namei.c | return msdos_unlinkx (dir,name,len,1); |
dir | 435 | fs/msdos/namei.c | int msdos_unlink_umsdos(struct inode *dir,const char *name,int len) |
dir | 437 | fs/msdos/namei.c | return msdos_unlinkx (dir,name,len,0); |
dir | 153 | fs/namei.c | int lookup(struct inode * dir,const char * name, int len, |
dir | 160 | fs/namei.c | if (!dir) |
dir | 163 | fs/namei.c | perm = permission(dir,MAY_EXEC); |
dir | 165 | fs/namei.c | if (dir == current->fs->root) { |
dir | 166 | fs/namei.c | *result = dir; |
dir | 168 | fs/namei.c | } else if ((sb = dir->i_sb) && (dir == sb->s_mounted)) { |
dir | 169 | fs/namei.c | iput(dir); |
dir | 170 | fs/namei.c | dir = sb->s_covered; |
dir | 171 | fs/namei.c | if (!dir) |
dir | 173 | fs/namei.c | dir->i_count++; |
dir | 176 | fs/namei.c | if (!dir->i_op || !dir->i_op->lookup) { |
dir | 177 | fs/namei.c | iput(dir); |
dir | 181 | fs/namei.c | iput(dir); |
dir | 185 | fs/namei.c | *result = dir; |
dir | 188 | fs/namei.c | return dir->i_op->lookup(dir,name,len,result); |
dir | 191 | fs/namei.c | int follow_link(struct inode * dir, struct inode * inode, |
dir | 194 | fs/namei.c | if (!dir || !inode) { |
dir | 195 | fs/namei.c | iput(dir); |
dir | 201 | fs/namei.c | iput(dir); |
dir | 205 | fs/namei.c | return inode->i_op->follow_link(dir,inode,flag,mode,res_inode); |
dir | 337 | fs/namei.c | struct inode * dir, *inode; |
dir | 341 | fs/namei.c | error = dir_namei(pathname,&namelen,&basename,base,&dir); |
dir | 346 | fs/namei.c | iput(dir); |
dir | 350 | fs/namei.c | if ((error = permission(dir,ACC_MODE(flag))) != 0) { |
dir | 351 | fs/namei.c | iput(dir); |
dir | 354 | fs/namei.c | *res_inode=dir; |
dir | 357 | fs/namei.c | dir->i_count++; /* lookup eats the dir */ |
dir | 359 | fs/namei.c | down(&dir->i_sem); |
dir | 360 | fs/namei.c | error = lookup(dir,basename,namelen,&inode); |
dir | 366 | fs/namei.c | } else if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) |
dir | 368 | fs/namei.c | else if (!dir->i_op || !dir->i_op->create) |
dir | 370 | fs/namei.c | else if (IS_RDONLY(dir)) |
dir | 373 | fs/namei.c | dir->i_count++; /* create eats the dir */ |
dir | 374 | fs/namei.c | error = dir->i_op->create(dir,basename,namelen,mode,res_inode); |
dir | 375 | fs/namei.c | up(&dir->i_sem); |
dir | 376 | fs/namei.c | iput(dir); |
dir | 379 | fs/namei.c | up(&dir->i_sem); |
dir | 381 | fs/namei.c | error = lookup(dir,basename,namelen,&inode); |
dir | 383 | fs/namei.c | iput(dir); |
dir | 386 | fs/namei.c | error = follow_link(dir,inode,flag,mode,&inode); |
dir | 444 | fs/namei.c | struct inode * dir; |
dir | 447 | fs/namei.c | error = dir_namei(filename,&namelen,&basename, NULL, &dir); |
dir | 451 | fs/namei.c | iput(dir); |
dir | 454 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 455 | fs/namei.c | iput(dir); |
dir | 458 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 459 | fs/namei.c | iput(dir); |
dir | 462 | fs/namei.c | if (!dir->i_op || !dir->i_op->mknod) { |
dir | 463 | fs/namei.c | iput(dir); |
dir | 466 | fs/namei.c | dir->i_count++; |
dir | 467 | fs/namei.c | down(&dir->i_sem); |
dir | 468 | fs/namei.c | error = dir->i_op->mknod(dir,basename,namelen,mode,dev); |
dir | 469 | fs/namei.c | up(&dir->i_sem); |
dir | 470 | fs/namei.c | iput(dir); |
dir | 502 | fs/namei.c | struct inode * dir; |
dir | 504 | fs/namei.c | error = dir_namei(pathname,&namelen,&basename,NULL,&dir); |
dir | 508 | fs/namei.c | iput(dir); |
dir | 511 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 512 | fs/namei.c | iput(dir); |
dir | 515 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 516 | fs/namei.c | iput(dir); |
dir | 519 | fs/namei.c | if (!dir->i_op || !dir->i_op->mkdir) { |
dir | 520 | fs/namei.c | iput(dir); |
dir | 523 | fs/namei.c | dir->i_count++; |
dir | 524 | fs/namei.c | down(&dir->i_sem); |
dir | 525 | fs/namei.c | error = dir->i_op->mkdir(dir, basename, namelen, mode & 0777 & ~current->fs->umask); |
dir | 526 | fs/namei.c | up(&dir->i_sem); |
dir | 527 | fs/namei.c | iput(dir); |
dir | 548 | fs/namei.c | struct inode * dir; |
dir | 550 | fs/namei.c | error = dir_namei(name,&namelen,&basename,NULL,&dir); |
dir | 554 | fs/namei.c | iput(dir); |
dir | 557 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 558 | fs/namei.c | iput(dir); |
dir | 561 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 562 | fs/namei.c | iput(dir); |
dir | 568 | fs/namei.c | if (IS_APPEND(dir)) { |
dir | 569 | fs/namei.c | iput(dir); |
dir | 572 | fs/namei.c | if (!dir->i_op || !dir->i_op->rmdir) { |
dir | 573 | fs/namei.c | iput(dir); |
dir | 576 | fs/namei.c | return dir->i_op->rmdir(dir,basename,namelen); |
dir | 596 | fs/namei.c | struct inode * dir; |
dir | 598 | fs/namei.c | error = dir_namei(name,&namelen,&basename,NULL,&dir); |
dir | 602 | fs/namei.c | iput(dir); |
dir | 605 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 606 | fs/namei.c | iput(dir); |
dir | 609 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 610 | fs/namei.c | iput(dir); |
dir | 616 | fs/namei.c | if (IS_APPEND(dir)) { |
dir | 617 | fs/namei.c | iput(dir); |
dir | 620 | fs/namei.c | if (!dir->i_op || !dir->i_op->unlink) { |
dir | 621 | fs/namei.c | iput(dir); |
dir | 624 | fs/namei.c | return dir->i_op->unlink(dir,basename,namelen); |
dir | 642 | fs/namei.c | struct inode * dir; |
dir | 646 | fs/namei.c | error = dir_namei(newname,&namelen,&basename,NULL,&dir); |
dir | 650 | fs/namei.c | iput(dir); |
dir | 653 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 654 | fs/namei.c | iput(dir); |
dir | 657 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 658 | fs/namei.c | iput(dir); |
dir | 661 | fs/namei.c | if (!dir->i_op || !dir->i_op->symlink) { |
dir | 662 | fs/namei.c | iput(dir); |
dir | 665 | fs/namei.c | dir->i_count++; |
dir | 666 | fs/namei.c | down(&dir->i_sem); |
dir | 667 | fs/namei.c | error = dir->i_op->symlink(dir,basename,namelen,oldname); |
dir | 668 | fs/namei.c | up(&dir->i_sem); |
dir | 669 | fs/namei.c | iput(dir); |
dir | 692 | fs/namei.c | struct inode * dir; |
dir | 696 | fs/namei.c | error = dir_namei(newname,&namelen,&basename,NULL,&dir); |
dir | 703 | fs/namei.c | iput(dir); |
dir | 706 | fs/namei.c | if (IS_RDONLY(dir)) { |
dir | 708 | fs/namei.c | iput(dir); |
dir | 711 | fs/namei.c | if (dir->i_dev != oldinode->i_dev) { |
dir | 712 | fs/namei.c | iput(dir); |
dir | 716 | fs/namei.c | if ((error = permission(dir,MAY_WRITE | MAY_EXEC)) != 0) { |
dir | 717 | fs/namei.c | iput(dir); |
dir | 725 | fs/namei.c | iput(dir); |
dir | 729 | fs/namei.c | if (!dir->i_op || !dir->i_op->link) { |
dir | 730 | fs/namei.c | iput(dir); |
dir | 734 | fs/namei.c | dir->i_count++; |
dir | 735 | fs/namei.c | down(&dir->i_sem); |
dir | 736 | fs/namei.c | error = dir->i_op->link(oldinode, dir, basename, namelen); |
dir | 737 | fs/namei.c | up(&dir->i_sem); |
dir | 738 | fs/namei.c | iput(dir); |
dir | 28 | fs/nfs/dir.c | static int nfs_lookup(struct inode *dir, const char *name, int len, |
dir | 30 | fs/nfs/dir.c | static int nfs_create(struct inode *dir, const char *name, int len, int mode, |
dir | 32 | fs/nfs/dir.c | static int nfs_mkdir(struct inode *dir, const char *name, int len, int mode); |
dir | 33 | fs/nfs/dir.c | static int nfs_rmdir(struct inode *dir, const char *name, int len); |
dir | 34 | fs/nfs/dir.c | static int nfs_unlink(struct inode *dir, const char *name, int len); |
dir | 37 | fs/nfs/dir.c | static int nfs_link(struct inode *oldinode, struct inode *dir, |
dir | 39 | fs/nfs/dir.c | static int nfs_mknod(struct inode *dir, const char *name, int len, int mode, |
dir | 226 | fs/nfs/dir.c | static struct nfs_lookup_cache_entry *nfs_lookup_cache_index(struct inode *dir, |
dir | 234 | fs/nfs/dir.c | if (entry->dev == dir->i_dev |
dir | 235 | fs/nfs/dir.c | && entry->inode == dir->i_ino |
dir | 242 | fs/nfs/dir.c | static int nfs_lookup_cache_lookup(struct inode *dir, const char *filename, |
dir | 254 | fs/nfs/dir.c | if ((entry = nfs_lookup_cache_index(dir, filename))) { |
dir | 266 | fs/nfs/dir.c | static void nfs_lookup_cache_add(struct inode *dir, const char *filename, |
dir | 277 | fs/nfs/dir.c | if (!(entry = nfs_lookup_cache_index(dir, filename))) { |
dir | 282 | fs/nfs/dir.c | entry->dev = dir->i_dev; |
dir | 283 | fs/nfs/dir.c | entry->inode = dir->i_ino; |
dir | 288 | fs/nfs/dir.c | ? NFS_SERVER(dir)->acdirmin : NFS_SERVER(dir)->acregmin); |
dir | 291 | fs/nfs/dir.c | static void nfs_lookup_cache_remove(struct inode *dir, struct inode *inode, |
dir | 303 | fs/nfs/dir.c | else if ((entry = nfs_lookup_cache_index(dir, filename))) { |
dir | 331 | fs/nfs/dir.c | static int nfs_lookup(struct inode *dir, const char *__name, int len, |
dir | 340 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 342 | fs/nfs/dir.c | iput(dir); |
dir | 346 | fs/nfs/dir.c | iput(dir); |
dir | 352 | fs/nfs/dir.c | *result = dir; |
dir | 355 | fs/nfs/dir.c | if ((NFS_SERVER(dir)->flags & NFS_MOUNT_NOAC) |
dir | 356 | fs/nfs/dir.c | || !nfs_lookup_cache_lookup(dir, name, &fhandle, &fattr)) { |
dir | 357 | fs/nfs/dir.c | if ((error = nfs_proc_lookup(NFS_SERVER(dir), NFS_FH(dir), |
dir | 359 | fs/nfs/dir.c | iput(dir); |
dir | 362 | fs/nfs/dir.c | nfs_lookup_cache_add(dir, name, &fhandle, &fattr); |
dir | 364 | fs/nfs/dir.c | if (!(*result = nfs_fhget(dir->i_sb, &fhandle, &fattr))) { |
dir | 365 | fs/nfs/dir.c | iput(dir); |
dir | 368 | fs/nfs/dir.c | iput(dir); |
dir | 372 | fs/nfs/dir.c | static int nfs_create(struct inode *dir, const char *name, int len, int mode, |
dir | 381 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 383 | fs/nfs/dir.c | iput(dir); |
dir | 387 | fs/nfs/dir.c | iput(dir); |
dir | 393 | fs/nfs/dir.c | if ((error = nfs_proc_create(NFS_SERVER(dir), NFS_FH(dir), |
dir | 395 | fs/nfs/dir.c | iput(dir); |
dir | 398 | fs/nfs/dir.c | if (!(*result = nfs_fhget(dir->i_sb, &fhandle, &fattr))) { |
dir | 399 | fs/nfs/dir.c | iput(dir); |
dir | 402 | fs/nfs/dir.c | nfs_lookup_cache_add(dir, name, &fhandle, &fattr); |
dir | 403 | fs/nfs/dir.c | iput(dir); |
dir | 407 | fs/nfs/dir.c | static int nfs_mknod(struct inode *dir, const char *name, int len, |
dir | 415 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 417 | fs/nfs/dir.c | iput(dir); |
dir | 421 | fs/nfs/dir.c | iput(dir); |
dir | 431 | fs/nfs/dir.c | error = nfs_proc_create(NFS_SERVER(dir), NFS_FH(dir), |
dir | 434 | fs/nfs/dir.c | nfs_lookup_cache_add(dir, name, &fhandle, &fattr); |
dir | 435 | fs/nfs/dir.c | iput(dir); |
dir | 439 | fs/nfs/dir.c | static int nfs_mkdir(struct inode *dir, const char *name, int len, int mode) |
dir | 446 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 448 | fs/nfs/dir.c | iput(dir); |
dir | 452 | fs/nfs/dir.c | iput(dir); |
dir | 458 | fs/nfs/dir.c | error = nfs_proc_mkdir(NFS_SERVER(dir), NFS_FH(dir), |
dir | 461 | fs/nfs/dir.c | nfs_lookup_cache_add(dir, name, &fhandle, &fattr); |
dir | 462 | fs/nfs/dir.c | iput(dir); |
dir | 466 | fs/nfs/dir.c | static int nfs_rmdir(struct inode *dir, const char *name, int len) |
dir | 470 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 472 | fs/nfs/dir.c | iput(dir); |
dir | 476 | fs/nfs/dir.c | iput(dir); |
dir | 479 | fs/nfs/dir.c | error = nfs_proc_rmdir(NFS_SERVER(dir), NFS_FH(dir), name); |
dir | 481 | fs/nfs/dir.c | nfs_lookup_cache_remove(dir, NULL, name); |
dir | 482 | fs/nfs/dir.c | iput(dir); |
dir | 486 | fs/nfs/dir.c | static int nfs_unlink(struct inode *dir, const char *name, int len) |
dir | 490 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 492 | fs/nfs/dir.c | iput(dir); |
dir | 496 | fs/nfs/dir.c | iput(dir); |
dir | 499 | fs/nfs/dir.c | error = nfs_proc_remove(NFS_SERVER(dir), NFS_FH(dir), name); |
dir | 501 | fs/nfs/dir.c | nfs_lookup_cache_remove(dir, NULL, name); |
dir | 502 | fs/nfs/dir.c | iput(dir); |
dir | 506 | fs/nfs/dir.c | static int nfs_symlink(struct inode *dir, const char *name, int len, |
dir | 512 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 514 | fs/nfs/dir.c | iput(dir); |
dir | 518 | fs/nfs/dir.c | iput(dir); |
dir | 522 | fs/nfs/dir.c | iput(dir); |
dir | 528 | fs/nfs/dir.c | error = nfs_proc_symlink(NFS_SERVER(dir), NFS_FH(dir), |
dir | 530 | fs/nfs/dir.c | iput(dir); |
dir | 534 | fs/nfs/dir.c | static int nfs_link(struct inode *oldinode, struct inode *dir, |
dir | 542 | fs/nfs/dir.c | iput(dir); |
dir | 545 | fs/nfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 548 | fs/nfs/dir.c | iput(dir); |
dir | 553 | fs/nfs/dir.c | iput(dir); |
dir | 557 | fs/nfs/dir.c | NFS_FH(dir), name); |
dir | 559 | fs/nfs/dir.c | nfs_lookup_cache_remove(dir, oldinode, NULL); |
dir | 561 | fs/nfs/dir.c | iput(dir); |
dir | 302 | fs/nfs/proc.c | int nfs_proc_lookup(struct nfs_server *server, struct nfs_fh *dir, const char *name, |
dir | 318 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 465 | fs/nfs/proc.c | int nfs_proc_create(struct nfs_server *server, struct nfs_fh *dir, |
dir | 478 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 505 | fs/nfs/proc.c | int nfs_proc_remove(struct nfs_server *server, struct nfs_fh *dir, const char *name) |
dir | 516 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 580 | fs/nfs/proc.c | struct nfs_fh *dir, const char *name) |
dir | 592 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 616 | fs/nfs/proc.c | int nfs_proc_symlink(struct nfs_server *server, struct nfs_fh *dir, |
dir | 628 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 654 | fs/nfs/proc.c | int nfs_proc_mkdir(struct nfs_server *server, struct nfs_fh *dir, |
dir | 667 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 694 | fs/nfs/proc.c | int nfs_proc_rmdir(struct nfs_server *server, struct nfs_fh *dir, const char *name) |
dir | 705 | fs/nfs/proc.c | p = xdr_encode_fhandle(p, dir); |
dir | 50 | fs/nfs/symlink.c | static int nfs_follow_link(struct inode *dir, struct inode *inode, |
dir | 58 | fs/nfs/symlink.c | if (!dir) { |
dir | 59 | fs/nfs/symlink.c | dir = current->fs->root; |
dir | 60 | fs/nfs/symlink.c | dir->i_count++; |
dir | 63 | fs/nfs/symlink.c | iput(dir); |
dir | 67 | fs/nfs/symlink.c | iput(dir); |
dir | 73 | fs/nfs/symlink.c | iput(dir); |
dir | 80 | fs/nfs/symlink.c | iput(dir); |
dir | 92 | fs/nfs/symlink.c | error = open_namei(res2, flag, mode, res_inode, dir); |
dir | 53 | fs/proc/fd.c | static int proc_lookupfd(struct inode * dir,const char * name, int len, |
dir | 62 | fs/proc/fd.c | ino = dir->i_ino; |
dir | 65 | fs/proc/fd.c | if (!dir) |
dir | 67 | fs/proc/fd.c | sb = dir->i_sb; |
dir | 68 | fs/proc/fd.c | if (!pid || ino != PROC_PID_FD || !S_ISDIR(dir->i_mode)) { |
dir | 69 | fs/proc/fd.c | iput(dir); |
dir | 75 | fs/proc/fd.c | *result = dir; |
dir | 79 | fs/proc/fd.c | iput(dir); |
dir | 82 | fs/proc/fd.c | iput(dir); |
dir | 85 | fs/proc/fd.c | iput(dir); |
dir | 101 | fs/proc/link.c | static int proc_follow_link(struct inode * dir, struct inode * inode, |
dir | 110 | fs/proc/link.c | if (dir) |
dir | 111 | fs/proc/link.c | iput(dir); |
dir | 162 | fs/proc/link.c | if (dir) { |
dir | 135 | fs/proc/root.c | int proc_register(struct proc_dir_entry * dir, struct proc_dir_entry * dp) |
dir | 137 | fs/proc/root.c | dp->next = dir->subdir; |
dir | 138 | fs/proc/root.c | dp->parent = dir; |
dir | 139 | fs/proc/root.c | dir->subdir = dp; |
dir | 141 | fs/proc/root.c | dir->nlink++; |
dir | 145 | fs/proc/root.c | int proc_unregister(struct proc_dir_entry * dir, int ino) |
dir | 147 | fs/proc/root.c | struct proc_dir_entry **p = &dir->subdir, *dp; |
dir | 154 | fs/proc/root.c | dir->nlink--; |
dir | 165 | fs/proc/root.c | static int proc_self_followlink(struct inode * dir, struct inode * inode, |
dir | 168 | fs/proc/root.c | iput(dir); |
dir | 318 | fs/proc/root.c | int proc_lookup(struct inode * dir,const char * name, int len, |
dir | 325 | fs/proc/root.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 326 | fs/proc/root.c | iput(dir); |
dir | 330 | fs/proc/root.c | de = (struct proc_dir_entry *) dir->u.generic_ip; |
dir | 332 | fs/proc/root.c | iput(dir); |
dir | 337 | fs/proc/root.c | *result = dir; |
dir | 345 | fs/proc/root.c | inode = proc_get_inode(dir->i_sb, de->parent->low_ino, de->parent); |
dir | 346 | fs/proc/root.c | iput(dir); |
dir | 360 | fs/proc/root.c | iput(dir); |
dir | 364 | fs/proc/root.c | ino = de->low_ino | (dir->i_ino & ~(0xffff)); |
dir | 366 | fs/proc/root.c | if (!(*result = proc_get_inode(dir->i_sb, ino, de))) { |
dir | 367 | fs/proc/root.c | iput(dir); |
dir | 370 | fs/proc/root.c | iput(dir); |
dir | 374 | fs/proc/root.c | static int proc_root_lookup(struct inode * dir,const char * name, int len, |
dir | 380 | fs/proc/root.c | dir->i_count++; |
dir | 381 | fs/proc/root.c | retval = proc_lookup(dir, name, len, result); |
dir | 383 | fs/proc/root.c | iput(dir); |
dir | 406 | fs/proc/root.c | iput(dir); |
dir | 410 | fs/proc/root.c | if (!(*result = proc_get_inode(dir->i_sb, ino, &proc_pid))) { |
dir | 411 | fs/proc/root.c | iput(dir); |
dir | 414 | fs/proc/root.c | iput(dir); |
dir | 35 | fs/smbfs/dir.c | get_pname(struct inode *dir, const char *name, int len, |
dir | 39 | fs/smbfs/dir.c | get_pname_static(struct inode *dir, const char *name, int len, |
dir | 43 | fs/smbfs/dir.c | smb_iget(struct inode *dir, char *path, struct smb_dirent *finfo); |
dir | 52 | fs/smbfs/dir.c | smb_lookup(struct inode *dir, const char *__name, |
dir | 56 | fs/smbfs/dir.c | smb_create(struct inode *dir, const char *name, int len, int mode, |
dir | 60 | fs/smbfs/dir.c | smb_mkdir(struct inode *dir, const char *name, int len, int mode); |
dir | 63 | fs/smbfs/dir.c | smb_rmdir(struct inode *dir, const char *name, int len); |
dir | 66 | fs/smbfs/dir.c | smb_unlink(struct inode *dir, const char *name, int len); |
dir | 347 | fs/smbfs/dir.c | get_pname_static(struct inode *dir, const char *name, int len, |
dir | 350 | fs/smbfs/dir.c | char *parentname = SMB_INOP(dir)->finfo.path; |
dir | 351 | fs/smbfs/dir.c | int parentlen = SMB_INOP(dir)->finfo.len; |
dir | 416 | fs/smbfs/dir.c | switch (SMB_SERVER(dir)->case_handling) |
dir | 436 | fs/smbfs/dir.c | get_pname(struct inode *dir, const char *name, int len, |
dir | 443 | fs/smbfs/dir.c | if ((res = get_pname_static(dir,name,len,result,&result_len) != 0)) { |
dir | 468 | fs/smbfs/dir.c | smb_iget(struct inode *dir, char *path, struct smb_dirent *finfo) |
dir | 476 | fs/smbfs/dir.c | if (!dir) { |
dir | 489 | fs/smbfs/dir.c | error = smb_proc_getattr(&(SMB_SBP(dir->i_sb)->s_server), |
dir | 510 | fs/smbfs/dir.c | new_inode_info->dir = SMB_INOP(dir); |
dir | 517 | fs/smbfs/dir.c | SMB_INOP(dir)->nused += 1; |
dir | 523 | fs/smbfs/dir.c | root = &(SMB_SERVER(dir)->root); |
dir | 530 | fs/smbfs/dir.c | if (!(inode = iget(dir->i_sb, (int)new_inode_info))) { |
dir | 548 | fs/smbfs/dir.c | struct smb_inode_info *dir = i->dir; |
dir | 556 | fs/smbfs/dir.c | if (dir == NULL) return; |
dir | 558 | fs/smbfs/dir.c | (dir->nused)--; |
dir | 559 | fs/smbfs/dir.c | i = dir; |
dir | 574 | fs/smbfs/dir.c | root->dir = NULL; |
dir | 662 | fs/smbfs/dir.c | smb_lookup(struct inode *dir, const char *__name, int len, |
dir | 673 | fs/smbfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 675 | fs/smbfs/dir.c | iput(dir); |
dir | 683 | fs/smbfs/dir.c | *result = dir; |
dir | 688 | fs/smbfs/dir.c | if ((error = get_pname(dir, __name, len, &name, &len)) < 0) { |
dir | 689 | fs/smbfs/dir.c | iput(dir); |
dir | 693 | fs/smbfs/dir.c | result_info = smb_find_inode(SMB_SERVER(dir), name); |
dir | 705 | fs/smbfs/dir.c | *result = iget(dir->i_sb, (int)result_info); |
dir | 706 | fs/smbfs/dir.c | iput(dir); |
dir | 724 | fs/smbfs/dir.c | if (dir->i_ino == c_ino) { |
dir | 746 | fs/smbfs/dir.c | error = smb_proc_getattr(SMB_SERVER(dir), name, len, &finfo); |
dir | 749 | fs/smbfs/dir.c | iput(dir); |
dir | 754 | fs/smbfs/dir.c | if (!(*result = smb_iget(dir, name, &finfo))) { |
dir | 756 | fs/smbfs/dir.c | iput(dir); |
dir | 761 | fs/smbfs/dir.c | iput(dir); |
dir | 766 | fs/smbfs/dir.c | smb_create(struct inode *dir, const char *name, int len, int mode, |
dir | 775 | fs/smbfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 777 | fs/smbfs/dir.c | iput(dir); |
dir | 782 | fs/smbfs/dir.c | if ((error = get_pname(dir, name, len, &path, &len)) < 0) { |
dir | 783 | fs/smbfs/dir.c | iput(dir); |
dir | 793 | fs/smbfs/dir.c | error = smb_proc_create(SMB_SERVER(dir), path, len, &entry); |
dir | 796 | fs/smbfs/dir.c | iput(dir); |
dir | 800 | fs/smbfs/dir.c | smb_invalid_dir_cache(dir->i_ino); |
dir | 802 | fs/smbfs/dir.c | if (!(*result = smb_iget(dir, path, &entry)) < 0) { |
dir | 804 | fs/smbfs/dir.c | iput(dir); |
dir | 807 | fs/smbfs/dir.c | iput(dir); |
dir | 812 | fs/smbfs/dir.c | smb_mkdir(struct inode *dir, const char *name, int len, int mode) |
dir | 817 | fs/smbfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 819 | fs/smbfs/dir.c | iput(dir); |
dir | 824 | fs/smbfs/dir.c | if ((error = get_pname_static(dir, name, len, path, &len)) < 0) { |
dir | 825 | fs/smbfs/dir.c | iput(dir); |
dir | 829 | fs/smbfs/dir.c | if ((error = smb_proc_mkdir(SMB_SERVER(dir), path, len)) == 0) { |
dir | 830 | fs/smbfs/dir.c | smb_invalid_dir_cache(dir->i_ino); |
dir | 833 | fs/smbfs/dir.c | iput(dir); |
dir | 838 | fs/smbfs/dir.c | smb_rmdir(struct inode *dir, const char *name, int len) |
dir | 843 | fs/smbfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 845 | fs/smbfs/dir.c | iput(dir); |
dir | 848 | fs/smbfs/dir.c | if ((error = get_pname_static(dir, name, len, path, &len)) < 0) { |
dir | 849 | fs/smbfs/dir.c | iput(dir); |
dir | 852 | fs/smbfs/dir.c | if (smb_find_inode(SMB_SERVER(dir), path) != NULL) { |
dir | 855 | fs/smbfs/dir.c | if ((error = smb_proc_rmdir(SMB_SERVER(dir), path, len)) == 0) |
dir | 856 | fs/smbfs/dir.c | smb_invalid_dir_cache(dir->i_ino); |
dir | 858 | fs/smbfs/dir.c | iput(dir); |
dir | 863 | fs/smbfs/dir.c | smb_unlink(struct inode *dir, const char *name, int len) |
dir | 868 | fs/smbfs/dir.c | if (!dir || !S_ISDIR(dir->i_mode)) { |
dir | 870 | fs/smbfs/dir.c | iput(dir); |
dir | 873 | fs/smbfs/dir.c | if ((error = get_pname_static(dir, name, len, path, &len)) < 0) { |
dir | 874 | fs/smbfs/dir.c | iput(dir); |
dir | 877 | fs/smbfs/dir.c | if (smb_find_inode(SMB_SERVER(dir), path) != NULL) { |
dir | 880 | fs/smbfs/dir.c | if ((error = smb_proc_unlink(SMB_SERVER(dir), path, len)) == 0) |
dir | 881 | fs/smbfs/dir.c | smb_invalid_dir_cache(dir->i_ino); |
dir | 884 | fs/smbfs/dir.c | iput(dir); |
dir | 402 | fs/smbfs/inode.c | smb_invalid_dir_cache((unsigned long)(SMB_INOP(inode)->dir)); |
dir | 942 | fs/smbfs/proc.c | smb_proc_readdir_short(struct smb_server *server, struct inode *dir, int fpos, |
dir | 956 | fs/smbfs/proc.c | int dirlen = strlen(SMB_FINFO(dir)->path); |
dir | 959 | fs/smbfs/proc.c | strcpy(mask, SMB_FINFO(dir)->path); |
dir | 1146 | fs/smbfs/proc.c | smb_proc_readdir_long(struct smb_server *server, struct inode *dir, int fpos, |
dir | 1174 | fs/smbfs/proc.c | int dirlen = strlen(SMB_FINFO(dir)->path); |
dir | 1177 | fs/smbfs/proc.c | strcpy(mask, SMB_FINFO(dir)->path); |
dir | 1373 | fs/smbfs/proc.c | smb_proc_readdir(struct smb_server *server, struct inode *dir, int fpos, |
dir | 1377 | fs/smbfs/proc.c | return smb_proc_readdir_long(server, dir, fpos, cache_size, |
dir | 1380 | fs/smbfs/proc.c | return smb_proc_readdir_short(server, dir, fpos, cache_size, |
dir | 463 | fs/super.c | int do_mount(kdev_t dev, const char * dir, const char * type, int flags, void * data) |
dir | 469 | fs/super.c | error = namei(dir,&dir_i); |
dir | 526 | fs/super.c | static int do_remount(const char *dir,int flags,char *data) |
dir | 531 | fs/super.c | retval = namei(dir,&dir_i); |
dir | 107 | fs/sysv/ialloc.c | struct inode * sysv_new_inode(const struct inode * dir) |
dir | 115 | fs/sysv/ialloc.c | if (!dir || !(inode = get_empty_inode())) |
dir | 117 | fs/sysv/ialloc.c | sb = dir->i_sb; |
dir | 160 | fs/sysv/ialloc.c | inode->i_gid = (dir->i_mode & S_ISGID) ? dir->i_gid : current->fsgid; |
dir | 64 | fs/sysv/namei.c | static struct buffer_head * sysv_find_entry(struct inode * dir, |
dir | 72 | fs/sysv/namei.c | if (!dir) |
dir | 74 | fs/sysv/namei.c | sb = dir->i_sb; |
dir | 82 | fs/sysv/namei.c | while (pos < dir->i_size) { |
dir | 84 | fs/sysv/namei.c | bh = sysv_file_bread(dir,block,0); |
dir | 107 | fs/sysv/namei.c | int sysv_lookup(struct inode * dir,const char * name, int len, |
dir | 115 | fs/sysv/namei.c | if (!dir) |
dir | 117 | fs/sysv/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 118 | fs/sysv/namei.c | iput(dir); |
dir | 121 | fs/sysv/namei.c | if (!(bh = sysv_find_entry(dir,name,len,&de))) { |
dir | 122 | fs/sysv/namei.c | iput(dir); |
dir | 127 | fs/sysv/namei.c | if (!(*result = iget(dir->i_sb,ino))) { |
dir | 128 | fs/sysv/namei.c | iput(dir); |
dir | 131 | fs/sysv/namei.c | iput(dir); |
dir | 145 | fs/sysv/namei.c | static int sysv_add_entry(struct inode * dir, |
dir | 158 | fs/sysv/namei.c | if (!dir) |
dir | 160 | fs/sysv/namei.c | sb = dir->i_sb; |
dir | 172 | fs/sysv/namei.c | bh = sysv_file_bread(dir,block,1); |
dir | 179 | fs/sysv/namei.c | if (pos > dir->i_size) { |
dir | 181 | fs/sysv/namei.c | dir->i_size = pos; |
dir | 182 | fs/sysv/namei.c | dir->i_dirt = 1; |
dir | 190 | fs/sysv/namei.c | dir->i_mtime = dir->i_ctime = CURRENT_TIME; |
dir | 191 | fs/sysv/namei.c | dir->i_dirt = 1; |
dir | 208 | fs/sysv/namei.c | int sysv_create(struct inode * dir,const char * name, int len, int mode, |
dir | 217 | fs/sysv/namei.c | if (!dir) |
dir | 219 | fs/sysv/namei.c | inode = sysv_new_inode(dir); |
dir | 221 | fs/sysv/namei.c | iput(dir); |
dir | 227 | fs/sysv/namei.c | error = sysv_add_entry(dir,name,len, &bh ,&de); |
dir | 232 | fs/sysv/namei.c | iput(dir); |
dir | 238 | fs/sysv/namei.c | iput(dir); |
dir | 243 | fs/sysv/namei.c | int sysv_mknod(struct inode * dir, const char * name, int len, int mode, int rdev) |
dir | 250 | fs/sysv/namei.c | if (!dir) |
dir | 252 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 255 | fs/sysv/namei.c | iput(dir); |
dir | 258 | fs/sysv/namei.c | inode = sysv_new_inode(dir); |
dir | 260 | fs/sysv/namei.c | iput(dir); |
dir | 270 | fs/sysv/namei.c | if (dir->i_mode & S_ISGID) |
dir | 284 | fs/sysv/namei.c | error = sysv_add_entry(dir, name, len, &bh, &de); |
dir | 289 | fs/sysv/namei.c | iput(dir); |
dir | 295 | fs/sysv/namei.c | iput(dir); |
dir | 300 | fs/sysv/namei.c | int sysv_mkdir(struct inode * dir, const char * name, int len, int mode) |
dir | 307 | fs/sysv/namei.c | if (!dir) { |
dir | 308 | fs/sysv/namei.c | iput(dir); |
dir | 311 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 314 | fs/sysv/namei.c | iput(dir); |
dir | 317 | fs/sysv/namei.c | if (dir->i_nlink >= dir->i_sb->sv_link_max) { |
dir | 318 | fs/sysv/namei.c | iput(dir); |
dir | 321 | fs/sysv/namei.c | inode = sysv_new_inode(dir); |
dir | 323 | fs/sysv/namei.c | iput(dir); |
dir | 330 | fs/sysv/namei.c | iput(dir); |
dir | 340 | fs/sysv/namei.c | de->inode = dir->i_ino; |
dir | 346 | fs/sysv/namei.c | if (dir->i_mode & S_ISGID) |
dir | 349 | fs/sysv/namei.c | error = sysv_add_entry(dir, name, len, &bh, &de); |
dir | 351 | fs/sysv/namei.c | iput(dir); |
dir | 358 | fs/sysv/namei.c | dir->i_nlink++; |
dir | 359 | fs/sysv/namei.c | dir->i_dirt = 1; |
dir | 360 | fs/sysv/namei.c | iput(dir); |
dir | 426 | fs/sysv/namei.c | int sysv_rmdir(struct inode * dir, const char * name, int len) |
dir | 434 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 439 | fs/sysv/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 441 | fs/sysv/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 443 | fs/sysv/namei.c | current->fsuid != dir->i_uid) |
dir | 445 | fs/sysv/namei.c | if (inode->i_dev != dir->i_dev) |
dir | 447 | fs/sysv/namei.c | if (inode == dir) /* we may not delete ".", but "../dir" is ok */ |
dir | 471 | fs/sysv/namei.c | dir->i_nlink--; |
dir | 472 | fs/sysv/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 473 | fs/sysv/namei.c | dir->i_dirt=1; |
dir | 476 | fs/sysv/namei.c | iput(dir); |
dir | 482 | fs/sysv/namei.c | int sysv_unlink(struct inode * dir, const char * name, int len) |
dir | 492 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 495 | fs/sysv/namei.c | if (!(inode = iget(dir->i_sb, de->inode))) |
dir | 507 | fs/sysv/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 509 | fs/sysv/namei.c | current->fsuid != dir->i_uid) |
dir | 523 | fs/sysv/namei.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 524 | fs/sysv/namei.c | dir->i_dirt = 1; |
dir | 526 | fs/sysv/namei.c | inode->i_ctime = dir->i_ctime; |
dir | 532 | fs/sysv/namei.c | iput(dir); |
dir | 536 | fs/sysv/namei.c | int sysv_symlink(struct inode * dir, const char * name, int len, const char * symname) |
dir | 547 | fs/sysv/namei.c | if (!(inode = sysv_new_inode(dir))) { |
dir | 548 | fs/sysv/namei.c | iput(dir); |
dir | 555 | fs/sysv/namei.c | iput(dir); |
dir | 571 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 577 | fs/sysv/namei.c | iput(dir); |
dir | 580 | fs/sysv/namei.c | i = sysv_add_entry(dir, name, len, &bh, &de); |
dir | 585 | fs/sysv/namei.c | iput(dir); |
dir | 591 | fs/sysv/namei.c | iput(dir); |
dir | 596 | fs/sysv/namei.c | int sysv_link(struct inode * oldinode, struct inode * dir, const char * name, int len) |
dir | 604 | fs/sysv/namei.c | iput(dir); |
dir | 609 | fs/sysv/namei.c | iput(dir); |
dir | 612 | fs/sysv/namei.c | bh = sysv_find_entry(dir,name,len,&de); |
dir | 615 | fs/sysv/namei.c | iput(dir); |
dir | 619 | fs/sysv/namei.c | error = sysv_add_entry(dir, name, len, &bh, &de); |
dir | 621 | fs/sysv/namei.c | iput(dir); |
dir | 628 | fs/sysv/namei.c | iput(dir); |
dir | 51 | fs/sysv/symlink.c | static int sysv_follow_link(struct inode * dir, struct inode * inode, |
dir | 58 | fs/sysv/symlink.c | if (!dir) { |
dir | 59 | fs/sysv/symlink.c | dir = current->fs->root; |
dir | 60 | fs/sysv/symlink.c | dir->i_count++; |
dir | 63 | fs/sysv/symlink.c | iput(dir); |
dir | 67 | fs/sysv/symlink.c | iput(dir); |
dir | 73 | fs/sysv/symlink.c | iput(dir); |
dir | 78 | fs/sysv/symlink.c | iput(dir); |
dir | 83 | fs/sysv/symlink.c | error = open_namei(bh->b_data,flag,mode,res_inode,dir); |
dir | 84 | fs/umsdos/dir.c | struct inode *dir, /* Point to a description of the super block */ |
dir | 95 | fs/umsdos/dir.c | umsdos_startlookup(dir); |
dir | 97 | fs/umsdos/dir.c | && dir == pseudo_root |
dir | 110 | fs/umsdos/dir.c | ,dir->i_sb->s_mounted->i_ino) == 0){ |
dir | 114 | fs/umsdos/dir.c | || (dir != dir->i_sb->s_mounted && filp->f_pos == 32)){ |
dir | 159 | fs/umsdos/dir.c | ret = msdos_readdir(dir,filp,&bufk,umsdos_dir_once); |
dir | 163 | fs/umsdos/dir.c | struct inode *emd_dir = umsdos_emd_dir_lookup(dir,0); |
dir | 200 | fs/umsdos/dir.c | lret = umsdos_real_lookup (dir,info.fake.fname |
dir | 239 | fs/umsdos/dir.c | ret = umsdos_writeentry (dir,emd_dir,&info,1); |
dir | 256 | fs/umsdos/dir.c | umsdos_endlookup(dir); |
dir | 257 | fs/umsdos/dir.c | PRINTK (("read dir %p pos %Ld ret %d\n",dir,filp->f_pos,ret)); |
dir | 266 | fs/umsdos/dir.c | struct inode *dir, /* Point to a description of the super block */ |
dir | 281 | fs/umsdos/dir.c | ret = umsdos_readdir_x (dir,filp,&bufk,0,&entry,1,umsdos_dir_once); |
dir | 293 | fs/umsdos/dir.c | struct inode *dir, |
dir | 327 | fs/umsdos/dir.c | if (inode->i_sb == dir->i_sb && !umsdos_isinit(inode)){ |
dir | 406 | fs/umsdos/dir.c | umsdos_patch_inode(inode,dir,emd_pos); |
dir | 467 | fs/umsdos/dir.c | struct inode *dir, |
dir | 481 | fs/umsdos/dir.c | struct inode *emddir = umsdos_emd_dir_lookup(dir,0); |
dir | 491 | fs/umsdos/dir.c | msdos_readdir (dir,&filp,&bufk,umsdos_dir_search); |
dir | 494 | fs/umsdos/dir.c | inode->u.umsdos_i.i_dir_owner = dir->i_ino; |
dir | 505 | fs/umsdos/dir.c | if (umsdos_readdir_x(dir,&filp,&bufk |
dir | 512 | fs/umsdos/dir.c | umsdos_lookup_patch (dir,inode,entry,bufk.f_pos); |
dir | 525 | fs/umsdos/dir.c | struct inode *dir, |
dir | 530 | fs/umsdos/dir.c | umsdos_patch_inode (dir,NULL,0); |
dir | 531 | fs/umsdos/dir.c | ret = umsdos_real_lookup (dir,"..",2,result); |
dir | 535 | fs/umsdos/dir.c | ret = umsdos_inode2entry (adir,dir,entry); |
dir | 551 | fs/umsdos/dir.c | struct inode *dir = inode; |
dir | 561 | fs/umsdos/dir.c | ret = umsdos_get_dirowner (inode,&dir); |
dir | 564 | fs/umsdos/dir.c | ret = umsdos_inode2entry (dir,inode,&entry); |
dir | 572 | fs/umsdos/dir.c | dir->i_count++; |
dir | 575 | fs/umsdos/dir.c | while (dir != dir->i_sb->s_mounted){ |
dir | 577 | fs/umsdos/dir.c | ret = umsdos_locate_ancestor (dir,&adir,&entry); |
dir | 578 | fs/umsdos/dir.c | iput (dir); |
dir | 579 | fs/umsdos/dir.c | dir = NULL; |
dir | 585 | fs/umsdos/dir.c | dir = adir; |
dir | 596 | fs/umsdos/dir.c | iput (dir); |
dir | 604 | fs/umsdos/dir.c | struct inode *dir, |
dir | 615 | fs/umsdos/dir.c | return dir == pseudo_root |
dir | 624 | fs/umsdos/dir.c | struct inode *dir, |
dir | 632 | fs/umsdos/dir.c | umsdos_startlookup(dir); |
dir | 634 | fs/umsdos/dir.c | *result = dir; |
dir | 635 | fs/umsdos/dir.c | dir->i_count++; |
dir | 638 | fs/umsdos/dir.c | if (pseudo_root != NULL && dir == pseudo_root->i_sb->s_mounted){ |
dir | 658 | fs/umsdos/dir.c | ret = umsdos_real_lookup (dir,"..",2,result); |
dir | 659 | fs/umsdos/dir.c | PRINTK (("ancestor ret %d dir %p *result %p ",ret,dir,*result)); |
dir | 661 | fs/umsdos/dir.c | && *result != dir->i_sb->s_mounted |
dir | 669 | fs/umsdos/dir.c | }else if (umsdos_is_pseudodos(dir,name,len)){ |
dir | 674 | fs/umsdos/dir.c | *result = dir->i_sb->s_mounted; |
dir | 680 | fs/umsdos/dir.c | if (ret == 0) ret = umsdos_findentry (dir,&info,0); |
dir | 694 | fs/umsdos/dir.c | ret = umsdos_real_lookup (dir,info.fake.fname,info.fake.len,result); |
dir | 699 | fs/umsdos/dir.c | umsdos_delentry (dir,&info,S_ISDIR(info.entry.mode)); |
dir | 701 | fs/umsdos/dir.c | umsdos_lookup_patch (dir,inode,&info.entry,info.f_pos); |
dir | 724 | fs/umsdos/dir.c | umsdos_endlookup(dir); |
dir | 725 | fs/umsdos/dir.c | iput (dir); |
dir | 733 | fs/umsdos/dir.c | struct inode *dir, |
dir | 738 | fs/umsdos/dir.c | return umsdos_lookup_x(dir,name,len,result,0); |
dir | 759 | fs/umsdos/dir.c | struct inode *dir; |
dir | 761 | fs/umsdos/dir.c | dir = hlink->i_sb->s_mounted; |
dir | 764 | fs/umsdos/dir.c | dir->i_count++; |
dir | 771 | fs/umsdos/dir.c | if (dir->u.umsdos_i.i_emd_dir == 0){ |
dir | 773 | fs/umsdos/dir.c | ret = umsdos_rlookup_x(dir,start,len,result,1); |
dir | 775 | fs/umsdos/dir.c | ret = umsdos_lookup_x(dir,start,len,result,1); |
dir | 779 | fs/umsdos/dir.c | dir = *result; |
dir | 104 | fs/umsdos/emd.c | struct inode *umsdos_emd_dir_lookup(struct inode *dir, int creat) |
dir | 107 | fs/umsdos/emd.c | if (dir->u.umsdos_i.i_emd_dir != 0){ |
dir | 108 | fs/umsdos/emd.c | ret = iget (dir->i_sb,dir->u.umsdos_i.i_emd_dir); |
dir | 110 | fs/umsdos/emd.c | ,dir->u.umsdos_i.i_emd_dir,ret,ret->i_count)); |
dir | 112 | fs/umsdos/emd.c | umsdos_real_lookup (dir,UMSDOS_EMD_FILE,UMSDOS_EMD_NAMELEN,&ret); |
dir | 116 | fs/umsdos/emd.c | dir->u.umsdos_i.i_emd_dir = ret->i_ino; |
dir | 120 | fs/umsdos/emd.c | dir->i_count++; |
dir | 121 | fs/umsdos/emd.c | code = msdos_create (dir,UMSDOS_EMD_FILE,UMSDOS_EMD_NAMELEN |
dir | 125 | fs/umsdos/emd.c | dir->u.umsdos_i.i_emd_dir = ret->i_ino; |
dir | 165 | fs/umsdos/emd.c | struct inode *dir, |
dir | 200 | fs/umsdos/emd.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 201 | fs/umsdos/emd.c | dir->i_dirt = 1; |
dir | 268 | fs/umsdos/emd.c | struct inode *dir, |
dir | 280 | fs/umsdos/emd.c | struct inode *emd_dir = umsdos_emd_dir_lookup(dir,1); |
dir | 368 | fs/umsdos/emd.c | struct inode *dir, |
dir | 372 | fs/umsdos/emd.c | int ret = umsdos_find (dir,info,&emd_dir); |
dir | 376 | fs/umsdos/emd.c | ret = umsdos_writeentry(dir,emd_dir,info,0); |
dir | 387 | fs/umsdos/emd.c | struct inode *dir, |
dir | 394 | fs/umsdos/emd.c | ret = umsdos_find (dir,info,&emd_dir); |
dir | 415 | fs/umsdos/emd.c | struct inode *dir, |
dir | 420 | fs/umsdos/emd.c | int ret = umsdos_find (dir,info,&emd_dir); |
dir | 430 | fs/umsdos/emd.c | ret = umsdos_writeentry(dir,emd_dir,info,1); |
dir | 445 | fs/umsdos/emd.c | int umsdos_isempty (struct inode *dir) |
dir | 448 | fs/umsdos/emd.c | struct inode *emd_dir = umsdos_emd_dir_lookup(dir,0); |
dir | 477 | fs/umsdos/emd.c | struct inode *dir, |
dir | 484 | fs/umsdos/emd.c | int ret = umsdos_find (dir,info,&emd_dir); |
dir | 75 | fs/umsdos/inode.c | struct inode *dir, |
dir | 81 | fs/umsdos/inode.c | dir->i_count++; |
dir | 82 | fs/umsdos/inode.c | ret = msdos_lookup (dir,name,len,result); |
dir | 108 | fs/umsdos/inode.c | struct inode *dir, |
dir | 111 | fs/umsdos/inode.c | struct inode *emd_owner = umsdos_emd_dir_lookup(dir,1); |
dir | 112 | fs/umsdos/inode.c | inode->u.umsdos_i.i_dir_owner = dir->i_ino; |
dir | 136 | fs/umsdos/inode.c | struct inode *dir, /* May be NULL */ |
dir | 164 | fs/umsdos/inode.c | if (dir != NULL){ |
dir | 176 | fs/umsdos/inode.c | if (dir != NULL){ |
dir | 187 | fs/umsdos/inode.c | umsdos_set_dirinfo (inode,dir,f_pos); |
dir | 189 | fs/umsdos/inode.c | }else if (dir != NULL){ |
dir | 194 | fs/umsdos/inode.c | struct inode *emd_owner = umsdos_emd_dir_lookup(dir,1); |
dir | 217 | fs/umsdos/inode.c | struct inode *dir = *result = iget(inode->i_sb,ino); |
dir | 218 | fs/umsdos/inode.c | if (dir != NULL){ |
dir | 219 | fs/umsdos/inode.c | umsdos_patch_inode (dir,NULL,0); |
dir | 59 | fs/umsdos/ioctl.c | struct inode *dir, |
dir | 124 | fs/umsdos/ioctl.c | msdos_readdir(dir,filp,&bufk,umsdos_ioctl_fill); |
dir | 138 | fs/umsdos/ioctl.c | struct inode *emd_dir = umsdos_emd_dir_lookup (dir,0); |
dir | 182 | fs/umsdos/ioctl.c | struct inode *emd_dir = umsdos_emd_dir_lookup (dir,1); |
dir | 186 | fs/umsdos/ioctl.c | dir->i_op = ret |
dir | 208 | fs/umsdos/ioctl.c | ret = umsdos_newentry (dir,&info); |
dir | 219 | fs/umsdos/ioctl.c | dir->i_count += 2; |
dir | 220 | fs/umsdos/ioctl.c | ret = msdos_rename (dir |
dir | 222 | fs/umsdos/ioctl.c | ,dir |
dir | 240 | fs/umsdos/ioctl.c | ret = umsdos_delentry (dir,&info |
dir | 250 | fs/umsdos/ioctl.c | dir->i_count++; |
dir | 251 | fs/umsdos/ioctl.c | ret = msdos_unlink (dir,data.dos_dirent.d_name |
dir | 261 | fs/umsdos/ioctl.c | dir->i_count++; |
dir | 262 | fs/umsdos/ioctl.c | ret = msdos_rmdir (dir,data.dos_dirent.d_name |
dir | 276 | fs/umsdos/ioctl.c | ret = umsdos_real_lookup (dir,data.dos_dirent.d_name |
dir | 308 | fs/umsdos/ioctl.c | dir->i_sb->u.msdos_sb.fs_uid = data.umsdos_dirent.uid; |
dir | 309 | fs/umsdos/ioctl.c | dir->i_sb->u.msdos_sb.fs_gid = data.umsdos_dirent.gid; |
dir | 310 | fs/umsdos/ioctl.c | dir->i_sb->u.msdos_sb.fs_umask = data.umsdos_dirent.mode; |
dir | 35 | fs/umsdos/namei.c | static int umsdos_waitcreate(struct inode *dir) |
dir | 38 | fs/umsdos/namei.c | if (dir->u.umsdos_i.u.dir_info.creating |
dir | 39 | fs/umsdos/namei.c | && dir->u.umsdos_i.u.dir_info.pid != current->pid){ |
dir | 40 | fs/umsdos/namei.c | sleep_on(&dir->u.umsdos_i.u.dir_info.p); |
dir | 48 | fs/umsdos/namei.c | static void umsdos_waitlookup (struct inode *dir) |
dir | 50 | fs/umsdos/namei.c | while (dir->u.umsdos_i.u.dir_info.looking){ |
dir | 51 | fs/umsdos/namei.c | sleep_on(&dir->u.umsdos_i.u.dir_info.p); |
dir | 57 | fs/umsdos/namei.c | void umsdos_lockcreate (struct inode *dir) |
dir | 91 | fs/umsdos/namei.c | while (umsdos_waitcreate(dir)!=0); |
dir | 92 | fs/umsdos/namei.c | dir->u.umsdos_i.u.dir_info.creating++; |
dir | 93 | fs/umsdos/namei.c | dir->u.umsdos_i.u.dir_info.pid = current->pid; |
dir | 94 | fs/umsdos/namei.c | umsdos_waitlookup (dir); |
dir | 124 | fs/umsdos/namei.c | void umsdos_startlookup (struct inode *dir) |
dir | 126 | fs/umsdos/namei.c | while (umsdos_waitcreate (dir) != 0); |
dir | 127 | fs/umsdos/namei.c | dir->u.umsdos_i.u.dir_info.looking++; |
dir | 133 | fs/umsdos/namei.c | void umsdos_unlockcreate (struct inode *dir) |
dir | 135 | fs/umsdos/namei.c | dir->u.umsdos_i.u.dir_info.creating--; |
dir | 136 | fs/umsdos/namei.c | if (dir->u.umsdos_i.u.dir_info.creating < 0){ |
dir | 138 | fs/umsdos/namei.c | ,dir->u.umsdos_i.u.dir_info.creating); |
dir | 140 | fs/umsdos/namei.c | wake_up (&dir->u.umsdos_i.u.dir_info.p); |
dir | 145 | fs/umsdos/namei.c | void umsdos_endlookup (struct inode *dir) |
dir | 147 | fs/umsdos/namei.c | dir->u.umsdos_i.u.dir_info.looking--; |
dir | 148 | fs/umsdos/namei.c | if (dir->u.umsdos_i.u.dir_info.looking < 0){ |
dir | 150 | fs/umsdos/namei.c | ,dir->u.umsdos_i.u.dir_info.looking); |
dir | 152 | fs/umsdos/namei.c | wake_up (&dir->u.umsdos_i.u.dir_info.p); |
dir | 155 | fs/umsdos/namei.c | static void umsdos_lockcreate (struct inode *dir){} |
dir | 157 | fs/umsdos/namei.c | void umsdos_startlookup (struct inode *dir){} |
dir | 158 | fs/umsdos/namei.c | static void umsdos_unlockcreate (struct inode *dir){} |
dir | 159 | fs/umsdos/namei.c | void umsdos_endlookup (struct inode *dir){} |
dir | 162 | fs/umsdos/namei.c | struct inode *dir, |
dir | 168 | fs/umsdos/namei.c | if (umsdos_is_pseudodos(dir,name,len)){ |
dir | 203 | fs/umsdos/namei.c | struct inode *dir, |
dir | 213 | fs/umsdos/namei.c | int ret = umsdos_nevercreat(dir,name,len,-EEXIST); |
dir | 223 | fs/umsdos/namei.c | info.entry.gid = (dir->i_mode & S_ISGID) |
dir | 224 | fs/umsdos/namei.c | ? dir->i_gid : current->fsgid; |
dir | 228 | fs/umsdos/namei.c | umsdos_lockcreate(dir); |
dir | 229 | fs/umsdos/namei.c | ret = umsdos_newentry (dir,&info); |
dir | 231 | fs/umsdos/namei.c | dir->i_count++; |
dir | 232 | fs/umsdos/namei.c | ret = msdos_create (dir,info.fake.fname,info.fake.len |
dir | 236 | fs/umsdos/namei.c | umsdos_lookup_patch (dir,inode,&info.entry,info.f_pos); |
dir | 238 | fs/umsdos/namei.c | PRINTK (("Creation OK: [%d] %s %d pos %d\n",dir->i_ino |
dir | 265 | fs/umsdos/namei.c | "deleting %s %d %d pos %ld\n",dir->i_ino |
dir | 268 | fs/umsdos/namei.c | umsdos_delentry (dir,&info,0); |
dir | 273 | fs/umsdos/namei.c | umsdos_unlockcreate(dir); |
dir | 276 | fs/umsdos/namei.c | iput (dir); |
dir | 424 | fs/umsdos/namei.c | struct inode * dir, |
dir | 443 | fs/umsdos/namei.c | dir->i_count++; /* We keep the inode in case we need it */ |
dir | 445 | fs/umsdos/namei.c | ret = umsdos_create_any (dir,name,len,mode,0,flags,&inode); |
dir | 464 | fs/umsdos/namei.c | UMSDOS_unlink (dir,name,len); |
dir | 465 | fs/umsdos/namei.c | dir = NULL; |
dir | 468 | fs/umsdos/namei.c | iput (dir); |
dir | 477 | fs/umsdos/namei.c | struct inode * dir, |
dir | 482 | fs/umsdos/namei.c | return umsdos_symlink_x (dir,name,len,symname,S_IFLNK|0777,0); |
dir | 489 | fs/umsdos/namei.c | struct inode * dir, |
dir | 570 | fs/umsdos/namei.c | }else if ((ret = umsdos_nevercreat(dir,name,len,-EPERM))==0){ |
dir | 577 | fs/umsdos/namei.c | umsdos_lockcreate2(dir,olddir); |
dir | 619 | fs/umsdos/namei.c | dir->i_count++; |
dir | 620 | fs/umsdos/namei.c | ret = umsdos_symlink_x (dir,name,len |
dir | 636 | fs/umsdos/namei.c | dir->i_count++; |
dir | 637 | fs/umsdos/namei.c | ret = umsdos_symlink_x (dir,name,len,path |
dir | 645 | fs/umsdos/namei.c | umsdos_unlockcreate(dir); |
dir | 656 | fs/umsdos/namei.c | iput (dir); |
dir | 668 | fs/umsdos/namei.c | struct inode *dir, |
dir | 675 | fs/umsdos/namei.c | return umsdos_create_any (dir,name,len,mode,0,0,result); |
dir | 681 | fs/umsdos/namei.c | struct inode * dir, |
dir | 686 | fs/umsdos/namei.c | int ret = umsdos_nevercreat(dir,name,len,-EEXIST); |
dir | 695 | fs/umsdos/namei.c | info.entry.gid = (dir->i_mode & S_ISGID) |
dir | 696 | fs/umsdos/namei.c | ? dir->i_gid : current->fsgid; |
dir | 700 | fs/umsdos/namei.c | umsdos_lockcreate(dir); |
dir | 702 | fs/umsdos/namei.c | ret = umsdos_newentry (dir,&info); |
dir | 705 | fs/umsdos/namei.c | dir->i_count++; |
dir | 706 | fs/umsdos/namei.c | ret = msdos_mkdir (dir,info.fake.fname,info.fake.len,mode); |
dir | 708 | fs/umsdos/namei.c | umsdos_delentry (dir,&info,1); |
dir | 721 | fs/umsdos/namei.c | ret = umsdos_real_lookup (dir,info.fake.fname |
dir | 736 | fs/umsdos/namei.c | umsdos_unlockcreate(dir); |
dir | 740 | fs/umsdos/namei.c | iput (dir); |
dir | 747 | fs/umsdos/namei.c | struct inode * dir, |
dir | 768 | fs/umsdos/namei.c | int ret = umsdos_create_any (dir,name,len,mode,rdev,0,&inode); |
dir | 777 | fs/umsdos/namei.c | struct inode * dir, |
dir | 868 | fs/umsdos/namei.c | int ret = umsdos_nevercreat(dir,name,len,-EPERM); |
dir | 871 | fs/umsdos/namei.c | dir->i_count++; |
dir | 872 | fs/umsdos/namei.c | ret = UMSDOS_lookup (dir,name,len,&sdir); |
dir | 876 | fs/umsdos/namei.c | umsdos_lockcreate(dir); |
dir | 882 | fs/umsdos/namei.c | if ( !(dir->i_mode & S_ISVTX) || fsuser() || |
dir | 884 | fs/umsdos/namei.c | current->fsuid == dir->i_uid ) { |
dir | 894 | fs/umsdos/namei.c | PRINTK (("isempty ret %d nlink %d ",ret,dir->i_nlink)); |
dir | 897 | fs/umsdos/namei.c | dir->i_count++; |
dir | 901 | fs/umsdos/namei.c | umsdos_findentry (dir,&info,2); |
dir | 902 | fs/umsdos/namei.c | ret = msdos_rmdir (dir,info.fake.fname |
dir | 905 | fs/umsdos/namei.c | ret = umsdos_delentry (dir,&info,1); |
dir | 920 | fs/umsdos/namei.c | umsdos_unlockcreate(dir); |
dir | 923 | fs/umsdos/namei.c | iput (dir); |
dir | 931 | fs/umsdos/namei.c | struct inode * dir, |
dir | 935 | fs/umsdos/namei.c | int ret = umsdos_nevercreat(dir,name,len,-EPERM); |
dir | 940 | fs/umsdos/namei.c | umsdos_lockcreate(dir); |
dir | 941 | fs/umsdos/namei.c | ret = umsdos_findentry(dir,&info,1); |
dir | 945 | fs/umsdos/namei.c | if ( !(dir->i_mode & S_ISVTX) || fsuser() || |
dir | 947 | fs/umsdos/namei.c | current->fsuid == dir->i_uid ) { |
dir | 962 | fs/umsdos/namei.c | dir->i_count++; |
dir | 963 | fs/umsdos/namei.c | ret = UMSDOS_lookup (dir,name,len,&inode); |
dir | 987 | fs/umsdos/namei.c | ret = umsdos_delentry (dir,&info,0); |
dir | 990 | fs/umsdos/namei.c | dir->i_count++; |
dir | 991 | fs/umsdos/namei.c | ret = msdos_unlink_umsdos (dir,info.fake.fname |
dir | 1003 | fs/umsdos/namei.c | umsdos_unlockcreate(dir); |
dir | 1006 | fs/umsdos/namei.c | iput (dir); |
dir | 68 | fs/umsdos/rdir.c | struct inode *dir, |
dir | 77 | fs/umsdos/rdir.c | && dir == dir->i_sb->s_mounted |
dir | 78 | fs/umsdos/rdir.c | && dir == pseudo_root->i_sb->s_mounted; |
dir | 79 | fs/umsdos/rdir.c | return msdos_readdir(dir,filp,&bufk,rdir_filldir); |
dir | 88 | fs/umsdos/rdir.c | struct inode *dir, |
dir | 100 | fs/umsdos/rdir.c | && dir == dir->i_sb->s_mounted |
dir | 101 | fs/umsdos/rdir.c | && dir == pseudo_root->i_sb->s_mounted){ |
dir | 110 | fs/umsdos/rdir.c | ret = umsdos_real_lookup (dir,name,len,result); |
dir | 128 | fs/umsdos/rdir.c | iput (dir); |
dir | 132 | fs/umsdos/rdir.c | struct inode *dir, |
dir | 137 | fs/umsdos/rdir.c | return umsdos_rlookup_x(dir,name,len,result,0); |
dir | 141 | fs/umsdos/rdir.c | struct inode *dir, |
dir | 160 | fs/umsdos/rdir.c | if (umsdos_is_pseudodos(dir,name,len)){ |
dir | 171 | fs/umsdos/rdir.c | umsdos_lockcreate (dir); |
dir | 172 | fs/umsdos/rdir.c | dir->i_count++; |
dir | 173 | fs/umsdos/rdir.c | ret = msdos_rmdir (dir,name,len); |
dir | 176 | fs/umsdos/rdir.c | dir->i_count++; |
dir | 177 | fs/umsdos/rdir.c | ret = UMSDOS_rlookup (dir,name,len,&sdir); |
dir | 195 | fs/umsdos/rdir.c | dir->i_count++; |
dir | 196 | fs/umsdos/rdir.c | ret = msdos_rmdir (dir,name,len); |
dir | 205 | fs/umsdos/rdir.c | umsdos_unlockcreate (dir); |
dir | 207 | fs/umsdos/rdir.c | iput (dir); |
dir | 54 | fs/umsdos/symlink.c | struct inode * dir, |
dir | 67 | fs/umsdos/symlink.c | if (!dir) { |
dir | 68 | fs/umsdos/symlink.c | dir = current->fs[1].root; |
dir | 69 | fs/umsdos/symlink.c | dir->i_count++; |
dir | 88 | fs/umsdos/symlink.c | ret = open_namei(path,flag,mode,res_inode,dir); |
dir | 90 | fs/umsdos/symlink.c | dir = NULL; |
dir | 99 | fs/umsdos/symlink.c | iput(dir); |
dir | 310 | fs/xiafs/bitmap.c | struct inode * xiafs_new_inode(struct inode * dir) |
dir | 316 | fs/xiafs/bitmap.c | sb = dir->i_sb; |
dir | 317 | fs/xiafs/bitmap.c | if (!dir || !(inode = get_empty_inode())) |
dir | 322 | fs/xiafs/bitmap.c | tmp=get_free_ibit(sb, dir->i_ino); |
dir | 331 | fs/xiafs/bitmap.c | inode->i_gid = (dir->i_mode & S_ISGID) ? dir->i_gid : current->fsgid; |
dir | 119 | fs/xiafs/namei.c | int xiafs_lookup(struct inode * dir, const char * name, int len, |
dir | 127 | fs/xiafs/namei.c | if (!dir) |
dir | 129 | fs/xiafs/namei.c | if (!S_ISDIR(dir->i_mode)) { |
dir | 130 | fs/xiafs/namei.c | iput(dir); |
dir | 133 | fs/xiafs/namei.c | if (!(bh = xiafs_find_entry(dir, name, len, &dep, NULL))) { |
dir | 134 | fs/xiafs/namei.c | iput(dir); |
dir | 139 | fs/xiafs/namei.c | if (!(*result = iget(dir->i_sb, ino))) { |
dir | 140 | fs/xiafs/namei.c | iput(dir); |
dir | 143 | fs/xiafs/namei.c | iput(dir); |
dir | 157 | fs/xiafs/namei.c | static struct buffer_head * xiafs_add_entry(struct inode * dir, |
dir | 166 | fs/xiafs/namei.c | if (!dir || !namelen || namelen > _XIAFS_NAME_LEN) |
dir | 169 | fs/xiafs/namei.c | if (dir->i_size & (XIAFS_ZSIZE(dir->i_sb) - 1)) { |
dir | 175 | fs/xiafs/namei.c | bh = xiafs_bread(dir, pos >> XIAFS_ZSIZE_BITS(dir->i_sb), pos ? 1:0); |
dir | 190 | fs/xiafs/namei.c | while (offset < XIAFS_ZSIZE(dir->i_sb)) { |
dir | 191 | fs/xiafs/namei.c | if (pos >= dir->i_size) { |
dir | 195 | fs/xiafs/namei.c | de->d_rec_len=XIAFS_ZSIZE(dir->i_sb); |
dir | 196 | fs/xiafs/namei.c | dir->i_size += XIAFS_ZSIZE(dir->i_sb); |
dir | 197 | fs/xiafs/namei.c | dir->i_dirt = 1; |
dir | 199 | fs/xiafs/namei.c | if (de->d_ino > dir->i_sb->u.xiafs_sb.s_ninodes || |
dir | 201 | fs/xiafs/namei.c | (char *)de+de->d_rec_len > bh->b_data+XIAFS_ZSIZE(dir->i_sb) || |
dir | 223 | fs/xiafs/namei.c | dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 224 | fs/xiafs/namei.c | dir->i_dirt = 1; |
dir | 239 | fs/xiafs/namei.c | if (offset > XIAFS_ZSIZE(dir->i_sb)) { |
dir | 243 | fs/xiafs/namei.c | pos+=XIAFS_ZSIZE(dir->i_sb); |
dir | 248 | fs/xiafs/namei.c | int xiafs_create(struct inode * dir, const char * name, int len, int mode, |
dir | 256 | fs/xiafs/namei.c | if (!dir) |
dir | 258 | fs/xiafs/namei.c | inode = xiafs_new_inode(dir); |
dir | 260 | fs/xiafs/namei.c | iput(dir); |
dir | 266 | fs/xiafs/namei.c | bh = xiafs_add_entry(dir, name, len, &de, NULL); |
dir | 271 | fs/xiafs/namei.c | iput(dir); |
dir | 277 | fs/xiafs/namei.c | iput(dir); |
dir | 282 | fs/xiafs/namei.c | int xiafs_mknod(struct inode *dir, const char *name, int len, int mode, int rdev) |
dir | 288 | fs/xiafs/namei.c | if (!dir) |
dir | 290 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir,name,len,&de, NULL); |
dir | 293 | fs/xiafs/namei.c | iput(dir); |
dir | 296 | fs/xiafs/namei.c | inode = xiafs_new_inode(dir); |
dir | 298 | fs/xiafs/namei.c | iput(dir); |
dir | 308 | fs/xiafs/namei.c | if (dir->i_mode & S_ISGID) |
dir | 323 | fs/xiafs/namei.c | bh = xiafs_add_entry(dir, name, len, &de, NULL); |
dir | 328 | fs/xiafs/namei.c | iput(dir); |
dir | 334 | fs/xiafs/namei.c | iput(dir); |
dir | 339 | fs/xiafs/namei.c | int xiafs_mkdir(struct inode * dir, const char * name, int len, int mode) |
dir | 345 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir,name,len,&de, NULL); |
dir | 348 | fs/xiafs/namei.c | iput(dir); |
dir | 351 | fs/xiafs/namei.c | if (dir->i_nlink > 64000) { |
dir | 352 | fs/xiafs/namei.c | iput(dir); |
dir | 355 | fs/xiafs/namei.c | inode = xiafs_new_inode(dir); |
dir | 357 | fs/xiafs/namei.c | iput(dir); |
dir | 361 | fs/xiafs/namei.c | inode->i_size = XIAFS_ZSIZE(dir->i_sb); |
dir | 366 | fs/xiafs/namei.c | iput(dir); |
dir | 378 | fs/xiafs/namei.c | de->d_ino = dir->i_ino; |
dir | 381 | fs/xiafs/namei.c | de->d_rec_len=XIAFS_ZSIZE(dir->i_sb)-12; |
dir | 386 | fs/xiafs/namei.c | if (dir->i_mode & S_ISGID) |
dir | 389 | fs/xiafs/namei.c | bh = xiafs_add_entry(dir, name, len, &de, NULL); |
dir | 391 | fs/xiafs/namei.c | iput(dir); |
dir | 398 | fs/xiafs/namei.c | dir->i_nlink++; |
dir | 399 | fs/xiafs/namei.c | dir->i_dirt = 1; |
dir | 400 | fs/xiafs/namei.c | iput(dir); |
dir | 489 | fs/xiafs/namei.c | int xiafs_rmdir(struct inode * dir, const char * name, int len) |
dir | 497 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir, name, len, &de, &de_pre); |
dir | 502 | fs/xiafs/namei.c | if (!(inode = iget(dir->i_sb, de->d_ino))) |
dir | 504 | fs/xiafs/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 506 | fs/xiafs/namei.c | current->fsuid != dir->i_uid) |
dir | 508 | fs/xiafs/namei.c | if (inode->i_dev != dir->i_dev) |
dir | 510 | fs/xiafs/namei.c | if (inode == dir) /* we may not delete ".", but "../dir" is ok */ |
dir | 530 | fs/xiafs/namei.c | dir->i_nlink--; |
dir | 531 | fs/xiafs/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 532 | fs/xiafs/namei.c | dir->i_dirt=1; |
dir | 535 | fs/xiafs/namei.c | iput(dir); |
dir | 541 | fs/xiafs/namei.c | int xiafs_unlink(struct inode * dir, const char * name, int len) |
dir | 551 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir, name, len, &de, &de_pre); |
dir | 554 | fs/xiafs/namei.c | if (!(inode = iget(dir->i_sb, de->d_ino))) |
dir | 566 | fs/xiafs/namei.c | if ((dir->i_mode & S_ISVTX) && !fsuser() && |
dir | 568 | fs/xiafs/namei.c | current->fsuid != dir->i_uid) |
dir | 576 | fs/xiafs/namei.c | inode->i_ctime = dir->i_ctime = dir->i_mtime = CURRENT_TIME; |
dir | 577 | fs/xiafs/namei.c | dir->i_dirt = 1; |
dir | 584 | fs/xiafs/namei.c | iput(dir); |
dir | 588 | fs/xiafs/namei.c | int xiafs_symlink(struct inode * dir, const char * name, |
dir | 597 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir,name,len, &de, NULL); |
dir | 600 | fs/xiafs/namei.c | iput(dir); |
dir | 603 | fs/xiafs/namei.c | if (!(inode = xiafs_new_inode(dir))) { |
dir | 604 | fs/xiafs/namei.c | iput(dir); |
dir | 611 | fs/xiafs/namei.c | iput(dir); |
dir | 624 | fs/xiafs/namei.c | bh = xiafs_add_entry(dir, name, len, &de, NULL); |
dir | 629 | fs/xiafs/namei.c | iput(dir); |
dir | 635 | fs/xiafs/namei.c | iput(dir); |
dir | 640 | fs/xiafs/namei.c | int xiafs_link(struct inode * oldinode, struct inode * dir, |
dir | 648 | fs/xiafs/namei.c | iput(dir); |
dir | 653 | fs/xiafs/namei.c | iput(dir); |
dir | 656 | fs/xiafs/namei.c | bh = xiafs_find_entry(dir, name, len, &de, NULL); |
dir | 659 | fs/xiafs/namei.c | iput(dir); |
dir | 663 | fs/xiafs/namei.c | bh = xiafs_add_entry(dir, name, len, &de, NULL); |
dir | 665 | fs/xiafs/namei.c | iput(dir); |
dir | 672 | fs/xiafs/namei.c | iput(dir); |
dir | 79 | fs/xiafs/symlink.c | static int xiafs_follow_link(struct inode * dir, struct inode * inode, |
dir | 86 | fs/xiafs/symlink.c | if (!dir) { |
dir | 87 | fs/xiafs/symlink.c | dir = current->fs->root; |
dir | 88 | fs/xiafs/symlink.c | dir->i_count++; |
dir | 91 | fs/xiafs/symlink.c | iput(dir); |
dir | 95 | fs/xiafs/symlink.c | iput(dir); |
dir | 105 | fs/xiafs/symlink.c | iput(dir); |
dir | 110 | fs/xiafs/symlink.c | iput(dir); |
dir | 115 | fs/xiafs/symlink.c | error = open_namei(bh->b_data,flag,mode,res_inode,dir); |
dir | 39 | include/asm-alpha/ioctl.h | #define _IOC(dir,type,nr,size) \ |
dir | 40 | include/asm-alpha/ioctl.h | (((dir) << _IOC_DIRSHIFT) | \ |
dir | 253 | include/asm-alpha/pgtable.h | extern inline pmd_t * pmd_offset(pgd_t * dir, unsigned long address) |
dir | 255 | include/asm-alpha/pgtable.h | return (pmd_t *) pgd_page(*dir) + ((address >> PMD_SHIFT) & (PTRS_PER_PAGE - 1)); |
dir | 259 | include/asm-alpha/pgtable.h | extern inline pte_t * pte_offset(pmd_t * dir, unsigned long address) |
dir | 261 | include/asm-alpha/pgtable.h | return (pte_t *) pmd_page(*dir) + ((address >> PAGE_SHIFT) & (PTRS_PER_PAGE - 1)); |
dir | 223 | include/asm-i386/pgtable.h | extern inline pmd_t * pmd_offset(pgd_t * dir, unsigned long address) |
dir | 225 | include/asm-i386/pgtable.h | return (pmd_t *) dir; |
dir | 229 | include/asm-i386/pgtable.h | extern inline pte_t * pte_offset(pmd_t * dir, unsigned long address) |
dir | 231 | include/asm-i386/pgtable.h | return (pte_t *) pmd_page(*dir) + ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1)); |
dir | 65 | include/linux/ext_fs.h | extern int ext_lookup(struct inode * dir,const char * name, int len, |
dir | 67 | include/linux/ext_fs.h | extern int ext_create(struct inode * dir,const char * name, int len, int mode, |
dir | 69 | include/linux/ext_fs.h | extern int ext_mkdir(struct inode * dir, const char * name, int len, int mode); |
dir | 70 | include/linux/ext_fs.h | extern int ext_rmdir(struct inode * dir, const char * name, int len); |
dir | 71 | include/linux/ext_fs.h | extern int ext_unlink(struct inode * dir, const char * name, int len); |
dir | 74 | include/linux/ext_fs.h | extern int ext_link(struct inode * oldinode, struct inode * dir, const char * name, int len); |
dir | 75 | include/linux/ext_fs.h | extern int ext_mknod(struct inode * dir, const char * name, int len, int mode, int rdev); |
dir | 78 | include/linux/ext_fs.h | extern struct inode * ext_new_inode(const struct inode * dir); |
dir | 169 | include/linux/iso_fs.h | extern int isofs_lookup(struct inode * dir,const char * name, int len, |
dir | 84 | include/linux/minix_fs.h | extern int minix_lookup(struct inode * dir,const char * name, int len, |
dir | 86 | include/linux/minix_fs.h | extern int minix_create(struct inode * dir,const char * name, int len, int mode, |
dir | 88 | include/linux/minix_fs.h | extern int minix_mkdir(struct inode * dir, const char * name, int len, int mode); |
dir | 89 | include/linux/minix_fs.h | extern int minix_rmdir(struct inode * dir, const char * name, int len); |
dir | 90 | include/linux/minix_fs.h | extern int minix_unlink(struct inode * dir, const char * name, int len); |
dir | 93 | include/linux/minix_fs.h | extern int minix_link(struct inode * oldinode, struct inode * dir, const char * name, int len); |
dir | 94 | include/linux/minix_fs.h | extern int minix_mknod(struct inode * dir, const char * name, int len, int mode, int rdev); |
dir | 97 | include/linux/minix_fs.h | extern struct inode * minix_new_inode(const struct inode * dir); |
dir | 127 | include/linux/msdos_fs.h | extern int msdos_get_entry(struct inode *dir,loff_t *pos,struct buffer_head **bh, |
dir | 129 | include/linux/msdos_fs.h | extern int msdos_scan(struct inode *dir,const char *name,struct buffer_head **res_bh, |
dir | 131 | include/linux/msdos_fs.h | extern int msdos_parent_ino(struct inode *dir,int locked); |
dir | 132 | include/linux/msdos_fs.h | extern int msdos_subdirs(struct inode *dir); |
dir | 148 | include/linux/msdos_fs.h | extern int msdos_lookup(struct inode *dir,const char *name,int len, |
dir | 150 | include/linux/msdos_fs.h | extern int msdos_create(struct inode *dir,const char *name,int len,int mode, |
dir | 152 | include/linux/msdos_fs.h | extern int msdos_mkdir(struct inode *dir,const char *name,int len,int mode); |
dir | 153 | include/linux/msdos_fs.h | extern int msdos_rmdir(struct inode *dir,const char *name,int len); |
dir | 154 | include/linux/msdos_fs.h | extern int msdos_unlink(struct inode *dir,const char *name,int len); |
dir | 155 | include/linux/msdos_fs.h | extern int msdos_unlink_umsdos(struct inode *dir,const char *name,int len); |
dir | 56 | include/linux/nfs_fs.h | extern int nfs_proc_lookup(struct nfs_server *server, struct nfs_fh *dir, |
dir | 68 | include/linux/nfs_fs.h | extern int nfs_proc_create(struct nfs_server *server, struct nfs_fh *dir, |
dir | 71 | include/linux/nfs_fs.h | extern int nfs_proc_remove(struct nfs_server *server, struct nfs_fh *dir, |
dir | 77 | include/linux/nfs_fs.h | struct nfs_fh *dir, const char *name); |
dir | 78 | include/linux/nfs_fs.h | extern int nfs_proc_symlink(struct nfs_server *server, struct nfs_fh *dir, |
dir | 80 | include/linux/nfs_fs.h | extern int nfs_proc_mkdir(struct nfs_server *server, struct nfs_fh *dir, |
dir | 83 | include/linux/nfs_fs.h | extern int nfs_proc_rmdir(struct nfs_server *server, struct nfs_fh *dir, |
dir | 149 | include/linux/smb_fs.h | int smb_proc_readdir(struct smb_server *server, struct inode *dir, |
dir | 28 | include/linux/smb_fs_i.h | struct smb_inode_info *dir; |
dir | 364 | include/linux/sysv_fs.h | extern int sysv_lookup(struct inode * dir,const char * name, int len, |
dir | 366 | include/linux/sysv_fs.h | extern int sysv_create(struct inode * dir,const char * name, int len, int mode, |
dir | 368 | include/linux/sysv_fs.h | extern int sysv_mkdir(struct inode * dir, const char * name, int len, int mode); |
dir | 369 | include/linux/sysv_fs.h | extern int sysv_rmdir(struct inode * dir, const char * name, int len); |
dir | 370 | include/linux/sysv_fs.h | extern int sysv_unlink(struct inode * dir, const char * name, int len); |
dir | 373 | include/linux/sysv_fs.h | extern int sysv_link(struct inode * oldinode, struct inode * dir, const char * name, int len); |
dir | 374 | include/linux/sysv_fs.h | extern int sysv_mknod(struct inode * dir, const char * name, int len, int mode, int rdev); |
dir | 377 | include/linux/sysv_fs.h | extern struct inode * sysv_new_inode(const struct inode * dir); |
dir | 67 | include/linux/xia_fs.h | extern int xiafs_lookup(struct inode * dir,const char * name, int len, |
dir | 69 | include/linux/xia_fs.h | extern int xiafs_create(struct inode * dir,const char * name, int len, int mode, |
dir | 71 | include/linux/xia_fs.h | extern int xiafs_mkdir(struct inode * dir, const char * name, int len, int mode); |
dir | 72 | include/linux/xia_fs.h | extern int xiafs_rmdir(struct inode * dir, const char * name, int len); |
dir | 73 | include/linux/xia_fs.h | extern int xiafs_unlink(struct inode * dir, const char * name, int len); |
dir | 76 | include/linux/xia_fs.h | extern int xiafs_link(struct inode * oldinode, struct inode * dir, |
dir | 78 | include/linux/xia_fs.h | extern int xiafs_mknod(struct inode * dir, const char * name, int len, |
dir | 83 | include/linux/xia_fs.h | extern struct inode * xiafs_new_inode(struct inode * dir); |
dir | 260 | mm/filemap.c | pgd_t * dir; |
dir | 264 | mm/filemap.c | dir = pgd_offset(current->mm, address); |
dir | 266 | mm/filemap.c | error |= filemap_sync_pmd_range(dir, address, end - address, vma, flags); |
dir | 268 | mm/filemap.c | dir++; |
dir | 85 | mm/memory.c | static inline void free_one_pmd(pmd_t * dir) |
dir | 89 | mm/memory.c | if (pmd_none(*dir)) |
dir | 91 | mm/memory.c | if (pmd_bad(*dir)) { |
dir | 92 | mm/memory.c | printk("free_one_pmd: bad directory entry %08lx\n", pmd_val(*dir)); |
dir | 93 | mm/memory.c | pmd_clear(dir); |
dir | 96 | mm/memory.c | pte = pte_offset(dir, 0); |
dir | 97 | mm/memory.c | pmd_clear(dir); |
dir | 101 | mm/memory.c | static inline void free_one_pgd(pgd_t * dir) |
dir | 105 | mm/memory.c | if (pgd_none(*dir)) |
dir | 107 | mm/memory.c | if (pgd_bad(*dir)) { |
dir | 108 | mm/memory.c | printk("free_one_pgd: bad directory entry %08lx\n", pgd_val(*dir)); |
dir | 109 | mm/memory.c | pgd_clear(dir); |
dir | 112 | mm/memory.c | pmd = pmd_offset(dir, 0); |
dir | 113 | mm/memory.c | pgd_clear(dir); |
dir | 354 | mm/memory.c | static inline void unmap_pmd_range(pgd_t * dir, unsigned long address, unsigned long size) |
dir | 359 | mm/memory.c | if (pgd_none(*dir)) |
dir | 361 | mm/memory.c | if (pgd_bad(*dir)) { |
dir | 362 | mm/memory.c | printk("unmap_pmd_range: bad pgd (%08lx)\n", pgd_val(*dir)); |
dir | 363 | mm/memory.c | pgd_clear(dir); |
dir | 366 | mm/memory.c | pmd = pmd_offset(dir, address); |
dir | 383 | mm/memory.c | pgd_t * dir; |
dir | 386 | mm/memory.c | dir = pgd_offset(mm, address); |
dir | 388 | mm/memory.c | unmap_pmd_range(dir, address, end - address); |
dir | 390 | mm/memory.c | dir++; |
dir | 444 | mm/memory.c | pgd_t * dir; |
dir | 449 | mm/memory.c | dir = pgd_offset(current->mm, address); |
dir | 451 | mm/memory.c | pmd_t *pmd = pmd_alloc(dir, address); |
dir | 459 | mm/memory.c | dir++; |
dir | 515 | mm/memory.c | pgd_t * dir; |
dir | 519 | mm/memory.c | dir = pgd_offset(current->mm, from); |
dir | 521 | mm/memory.c | pmd_t *pmd = pmd_alloc(dir, from); |
dir | 529 | mm/memory.c | dir++; |
dir | 74 | mm/mprotect.c | pgd_t *dir; |
dir | 76 | mm/mprotect.c | dir = pgd_offset(current->mm, start); |
dir | 78 | mm/mprotect.c | change_pmd_range(dir, start, end - start, newprot); |
dir | 80 | mm/mprotect.c | dir++; |
dir | 443 | mm/swap.c | pmd_t *dir, unsigned long address, unsigned long end, unsigned long limit) |
dir | 448 | mm/swap.c | if (pmd_none(*dir)) |
dir | 450 | mm/swap.c | if (pmd_bad(*dir)) { |
dir | 451 | mm/swap.c | printk("swap_out_pmd: bad pmd (%08lx)\n", pmd_val(*dir)); |
dir | 452 | mm/swap.c | pmd_clear(dir); |
dir | 456 | mm/swap.c | pte = pte_offset(dir, address); |
dir | 475 | mm/swap.c | pgd_t *dir, unsigned long address, unsigned long end, unsigned long limit) |
dir | 480 | mm/swap.c | if (pgd_none(*dir)) |
dir | 482 | mm/swap.c | if (pgd_bad(*dir)) { |
dir | 483 | mm/swap.c | printk("swap_out_pgd: bad pgd (%08lx)\n", pgd_val(*dir)); |
dir | 484 | mm/swap.c | pgd_clear(dir); |
dir | 488 | mm/swap.c | pmd = pmd_offset(dir, address); |
dir | 850 | mm/swap.c | pte_t *dir, unsigned int type, unsigned long page) |
dir | 852 | mm/swap.c | pte_t pte = *dir; |
dir | 865 | mm/swap.c | set_pte(dir, pte_mkdirty(pte)); |
dir | 871 | mm/swap.c | if (pte_val(*dir) != pte_val(pte)) { |
dir | 875 | mm/swap.c | set_pte(dir, pte_mkwrite(pte_mkdirty(mk_pte(page, vma->vm_page_prot)))); |
dir | 881 | mm/swap.c | static inline int unuse_pmd(struct vm_area_struct * vma, pmd_t *dir, |
dir | 888 | mm/swap.c | if (pmd_none(*dir)) |
dir | 890 | mm/swap.c | if (pmd_bad(*dir)) { |
dir | 891 | mm/swap.c | printk("unuse_pmd: bad pmd (%08lx)\n", pmd_val(*dir)); |
dir | 892 | mm/swap.c | pmd_clear(dir); |
dir | 895 | mm/swap.c | pte = pte_offset(dir, address); |
dir | 910 | mm/swap.c | static inline int unuse_pgd(struct vm_area_struct * vma, pgd_t *dir, |
dir | 917 | mm/swap.c | if (pgd_none(*dir)) |
dir | 919 | mm/swap.c | if (pgd_bad(*dir)) { |
dir | 920 | mm/swap.c | printk("unuse_pgd: bad pgd (%08lx)\n", pgd_val(*dir)); |
dir | 921 | mm/swap.c | pgd_clear(dir); |
dir | 924 | mm/swap.c | pmd = pmd_offset(dir, address); |
dir | 73 | mm/vmalloc.c | static inline void free_area_pmd(pgd_t * dir, unsigned long address, unsigned long size) |
dir | 78 | mm/vmalloc.c | if (pgd_none(*dir)) |
dir | 80 | mm/vmalloc.c | if (pgd_bad(*dir)) { |
dir | 81 | mm/vmalloc.c | printk("free_area_pmd: bad pgd (%08lx)\n", pgd_val(*dir)); |
dir | 82 | mm/vmalloc.c | pgd_clear(dir); |
dir | 85 | mm/vmalloc.c | pmd = pmd_offset(dir, address); |
dir | 99 | mm/vmalloc.c | pgd_t * dir; |
dir | 102 | mm/vmalloc.c | dir = pgd_offset(&init_mm, address); |
dir | 104 | mm/vmalloc.c | free_area_pmd(dir, address, end - address); |
dir | 106 | mm/vmalloc.c | dir++; |
dir | 155 | mm/vmalloc.c | pgd_t * dir; |
dir | 158 | mm/vmalloc.c | dir = pgd_offset(&init_mm, address); |
dir | 160 | mm/vmalloc.c | pmd_t *pmd = pmd_alloc_kernel(dir, address); |
dir | 165 | mm/vmalloc.c | set_pgdir(address, *dir); |
dir | 167 | mm/vmalloc.c | dir++; |
dir | 215 | mm/vmalloc.c | pgd_t * dir; |
dir | 219 | mm/vmalloc.c | dir = pgd_offset(&init_mm, address); |
dir | 221 | mm/vmalloc.c | pmd_t *pmd = pmd_alloc_kernel(dir, address); |
dir | 226 | mm/vmalloc.c | set_pgdir(address, *dir); |
dir | 228 | mm/vmalloc.c | dir++; |