tag | line | file | source code |
fd | 106 | fs/buffer.c | int sys_fsync(int fd) |
fd | 36 | fs/exec.c | extern int sys_close(int fd); |
fd | 16 | fs/fcntl.c | extern int sys_close(int fd); |
fd | 20 | fs/fcntl.c | static int dupfd(unsigned int fd, unsigned int arg) |
fd | 22 | fs/fcntl.c | if (fd >= NR_OPEN || !current->filp[fd]) |
fd | 34 | fs/fcntl.c | (current->filp[arg] = current->filp[fd])->f_count++; |
fd | 66 | fs/fcntl.c | int sys_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg) |
fd | 71 | fs/fcntl.c | if (fd >= NR_OPEN || !(filp = current->filp[fd])) |
fd | 75 | fs/fcntl.c | return dupfd(fd,arg); |
fd | 77 | fs/fcntl.c | return FD_ISSET(fd, ¤t->close_on_exec); |
fd | 80 | fs/fcntl.c | FD_SET(fd, ¤t->close_on_exec); |
fd | 82 | fs/fcntl.c | FD_CLR(fd, ¤t->close_on_exec); |
fd | 91 | fs/fcntl.c | return fcntl_getlk(fd, (struct flock *) arg); |
fd | 93 | fs/fcntl.c | return fcntl_setlk(fd, cmd, (struct flock *) arg); |
fd | 95 | fs/fcntl.c | return fcntl_setlk(fd, cmd, (struct flock *) arg); |
fd | 57 | fs/ioctl.c | int sys_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg) |
fd | 62 | fs/ioctl.c | if (fd >= NR_OPEN || !(filp = current->filp[fd])) |
fd | 66 | fs/ioctl.c | FD_SET(fd, ¤t->close_on_exec); |
fd | 70 | fs/ioctl.c | FD_CLR(fd, ¤t->close_on_exec); |
fd | 51 | fs/locks.c | int fcntl_getlk(unsigned int fd, struct flock *l) |
fd | 58 | fs/locks.c | if (fd >= NR_OPEN || !(filp = current->filp[fd])) |
fd | 91 | fs/locks.c | int fcntl_setlk(unsigned int fd, unsigned int cmd, struct flock *l) |
fd | 102 | fs/locks.c | if (fd >= NR_OPEN || !(filp = current->filp[fd])) |
fd | 64 | fs/nfs/inode.c | unsigned int fd; |
fd | 73 | fs/nfs/inode.c | fd = data->fd; |
fd | 78 | fs/nfs/inode.c | if (fd >= NR_OPEN || !(filp = current->filp[fd])) { |
fd | 49 | fs/open.c | int sys_fstatfs(unsigned int fd, struct statfs * buf) |
fd | 58 | fs/open.c | if (fd >= NR_OPEN || !(file = current->filp[fd])) |
fd | 94 | fs/open.c | int sys_ftruncate(unsigned int fd, unsigned int length) |
fd | 99 | fs/open.c | if (fd >= NR_OPEN || !(file = current->filp[fd])) |
fd | 234 | fs/open.c | int sys_fchmod(unsigned int fd, mode_t mode) |
fd | 239 | fs/open.c | if (fd >= NR_OPEN || !(file = current->filp[fd])) |
fd | 281 | fs/open.c | int sys_fchown(unsigned int fd, uid_t user, gid_t group) |
fd | 286 | fs/open.c | if (fd >= NR_OPEN || !(file = current->filp[fd])) |
fd | 358 | fs/open.c | int flag,error,fd; |
fd | 360 | fs/open.c | for(fd=0 ; fd<NR_OPEN ; fd++) |
fd | 361 | fs/open.c | if (!current->filp[fd]) |
fd | 363 | fs/open.c | if (fd>=NR_OPEN) |
fd | 365 | fs/open.c | FD_CLR(fd,¤t->close_on_exec); |
fd | 369 | fs/open.c | current->filp[fd] = f; |
fd | 382 | fs/open.c | current->filp[fd]=NULL; |
fd | 392 | fs/open.c | current->filp[fd] = NULL; |
fd | 409 | fs/open.c | current->filp[fd]=NULL; |
fd | 414 | fs/open.c | return (fd); |
fd | 445 | fs/open.c | int sys_close(unsigned int fd) |
fd | 449 | fs/open.c | if (fd >= NR_OPEN) |
fd | 451 | fs/open.c | FD_CLR(fd, ¤t->close_on_exec); |
fd | 452 | fs/open.c | if (!(filp = current->filp[fd])) |
fd | 454 | fs/open.c | current->filp[fd] = NULL; |
fd | 219 | fs/pipe.c | int fd[2]; |
fd | 235 | fs/pipe.c | current->filp[ fd[j]=i ] = f[j]; |
fd | 239 | fs/pipe.c | current->filp[fd[0]]=NULL; |
fd | 246 | fs/pipe.c | current->filp[fd[0]] = NULL; |
fd | 247 | fs/pipe.c | current->filp[fd[1]] = NULL; |
fd | 260 | fs/pipe.c | put_fs_long(fd[0],0+fildes); |
fd | 261 | fs/pipe.c | put_fs_long(fd[1],1+fildes); |
fd | 56 | fs/proc/fd.c | unsigned int ino, pid, fd, c; |
fd | 87 | fs/proc/fd.c | fd = 0; |
fd | 92 | fs/proc/fd.c | fd = 0xfffff; |
fd | 95 | fs/proc/fd.c | fd *= 10; |
fd | 96 | fs/proc/fd.c | fd += c; |
fd | 97 | fs/proc/fd.c | if (fd & 0xffff0000) { |
fd | 98 | fs/proc/fd.c | fd = 0xfffff; |
fd | 108 | fs/proc/fd.c | if (fd >= NR_OPEN || !p->filp[fd] || !p->filp[fd]->f_inode) |
fd | 110 | fs/proc/fd.c | ino = (pid << 16) + 0x100 + fd; |
fd | 112 | fs/proc/fd.c | if (fd >= p->numlibraries) |
fd | 114 | fs/proc/fd.c | ino = (pid << 16) + 0x200 + fd; |
fd | 125 | fs/proc/fd.c | unsigned int fd, pid, ino; |
fd | 137 | fs/proc/fd.c | fd = filp->f_pos; |
fd | 139 | fs/proc/fd.c | if (fd < 2) { |
fd | 140 | fs/proc/fd.c | i = j = fd+1; |
fd | 141 | fs/proc/fd.c | if (!fd) |
fd | 142 | fs/proc/fd.c | fd = inode->i_ino; |
fd | 144 | fs/proc/fd.c | fd = (inode->i_ino & 0xffff0000) | 2; |
fd | 145 | fs/proc/fd.c | put_fs_long(fd, &dirent->d_ino); |
fd | 152 | fs/proc/fd.c | fd -= 2; |
fd | 159 | fs/proc/fd.c | if (fd >= NR_OPEN) |
fd | 161 | fs/proc/fd.c | if (!p->filp[fd] || !p->filp[fd]->f_inode) |
fd | 164 | fs/proc/fd.c | if (fd >= p->numlibraries) |
fd | 168 | fs/proc/fd.c | while (fd >= j) { |
fd | 174 | fs/proc/fd.c | ino = (pid << 16) + 0x100 + fd; |
fd | 176 | fs/proc/fd.c | ino = (pid << 16) + 0x200 + fd; |
fd | 181 | fs/proc/fd.c | put_fs_byte('0'+(fd % 10), i+dirent->d_name); |
fd | 182 | fs/proc/fd.c | fd /= 10; |
fd | 19 | fs/read_write.c | int sys_readdir(unsigned int fd, struct dirent * dirent, unsigned int count) |
fd | 25 | fs/read_write.c | if (fd >= NR_OPEN || !(file = current->filp[fd]) || |
fd | 37 | fs/read_write.c | int sys_lseek(unsigned int fd, off_t offset, unsigned int origin) |
fd | 42 | fs/read_write.c | if (fd >= NR_OPEN || !(file=current->filp[fd]) || !(file->f_inode)) |
fd | 70 | fs/read_write.c | int sys_read(unsigned int fd,char * buf,unsigned int count) |
fd | 76 | fs/read_write.c | if (fd>=NR_OPEN || !(file=current->filp[fd]) || !(inode=file->f_inode)) |
fd | 90 | fs/read_write.c | int sys_write(unsigned int fd,char * buf,unsigned int count) |
fd | 96 | fs/read_write.c | if (fd>=NR_OPEN || !(file=current->filp[fd]) || !(inode=file->f_inode)) |
fd | 142 | fs/stat.c | int sys_fstat(unsigned int fd, struct old_stat * statbuf) |
fd | 151 | fs/stat.c | if (fd >= NR_OPEN || !(f=current->filp[fd]) || !(inode=f->f_inode)) |
fd | 157 | fs/stat.c | int sys_newfstat(unsigned int fd, struct new_stat * statbuf) |
fd | 166 | fs/stat.c | if (fd >= NR_OPEN || !(f=current->filp[fd]) || !(inode=f->f_inode)) |
fd | 24 | include/linux/nfs_mount.h | int fd; /* 1 */ |
fd | 17 | include/linux/time.h | #define FD_SET(fd,fdsetp) __FD_SET(fd,fdsetp) |
fd | 18 | include/linux/time.h | #define FD_CLR(fd,fdsetp) __FD_CLR(fd,fdsetp) |
fd | 19 | include/linux/time.h | #define FD_ISSET(fd,fdsetp) __FD_ISSET(fd,fdsetp) |
fd | 95 | include/linux/types.h | #define __FD_SET(fd,fdsetp) \ |
fd | 97 | include/linux/types.h | "=m" (*(fd_set *) (fdsetp)):"r" ((int) (fd))) |
fd | 100 | include/linux/types.h | #define __FD_CLR(fd,fdsetp) \ |
fd | 102 | include/linux/types.h | "=m" (*(fd_set *) (fdsetp)):"r" ((int) (fd))) |
fd | 105 | include/linux/types.h | #define __FD_ISSET(fd,fdsetp) (__extension__ ({ \ |
fd | 108 | include/linux/types.h | :"=q" (__result) :"r" ((int) (fd)), \ |
fd | 47 | init/main.c | static inline _syscall3(int,write,int,fd,const char *,buf,off_t,count) |
fd | 48 | init/main.c | static inline _syscall1(int,dup,int,fd) |
fd | 51 | init/main.c | static inline _syscall1(int,close,int,fd) |
fd | 20 | kernel/exit.c | int sys_close(int fd); |
fd | 10 | lib/close.c | _syscall1(int,close,int,fd) |
fd | 10 | lib/dup.c | _syscall1(int,dup,int,fd) |
fd | 11 | lib/write.c | _syscall3(int,write,int,fd,const char *,buf,off_t,count) |
fd | 41 | mm/mmap.c | int prot, flags, mask, fd, error; |
fd | 48 | mm/mmap.c | fd = (int) get_fs_long(buffer+4); /* object to map */ |
fd | 51 | mm/mmap.c | if (fd >= NR_OPEN || fd < 0 || !(file = current->filp[fd])) |
fd | 18 | net/socket.c | extern int sys_close(int fd); |
fd | 82 | net/socket.c | int fd; |
fd | 91 | net/socket.c | for (fd = 0; fd < NR_OPEN; ++fd) |
fd | 92 | net/socket.c | if (!current->filp[fd]) |
fd | 94 | net/socket.c | if (fd == NR_OPEN) { |
fd | 98 | net/socket.c | FD_CLR(fd, ¤t->close_on_exec); |
fd | 99 | net/socket.c | current->filp[fd] = file; |
fd | 108 | net/socket.c | return fd; |
fd | 117 | net/socket.c | toss_fd(int fd) |
fd | 120 | net/socket.c | sys_close(fd); |
fd | 135 | net/socket.c | sockfd_lookup(int fd, struct file **pfile) |
fd | 139 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || !(file = current->filp[fd])) |
fd | 413 | net/socket.c | int i, fd; |
fd | 460 | net/socket.c | if ((fd = get_fd(SOCK_INODE(sock))) < 0) { |
fd | 465 | net/socket.c | return fd; |
fd | 519 | net/socket.c | sock_bind(int fd, struct sockaddr *umyaddr, int addrlen) |
fd | 524 | net/socket.c | PRINTK(("sys_bind: fd = %d\n", fd)); |
fd | 525 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 540 | net/socket.c | sock_listen(int fd, int backlog) |
fd | 544 | net/socket.c | PRINTK(("sys_listen: fd = %d\n", fd)); |
fd | 545 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 566 | net/socket.c | sock_accept(int fd, struct sockaddr *upeer_sockaddr, int *upeer_addrlen) |
fd | 572 | net/socket.c | PRINTK(("sys_accept: fd = %d\n", fd)); |
fd | 573 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) |
fd | 603 | net/socket.c | if ((fd = get_fd(SOCK_INODE(newsock))) < 0) { |
fd | 615 | net/socket.c | return fd; |
fd | 622 | net/socket.c | sock_connect(int fd, struct sockaddr *uservaddr, int addrlen) |
fd | 628 | net/socket.c | PRINTK(("sys_connect: fd = %d\n", fd)); |
fd | 629 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) |
fd | 655 | net/socket.c | sock_getsockname(int fd, struct sockaddr *usockaddr, int *usockaddr_len) |
fd | 659 | net/socket.c | PRINTK(("sys_getsockname: fd = %d\n", fd)); |
fd | 660 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 666 | net/socket.c | sock_getpeername(int fd, struct sockaddr *usockaddr, int *usockaddr_len) |
fd | 670 | net/socket.c | PRINTK(("sys_getpeername: fd = %d\n", fd)); |
fd | 671 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 680 | net/socket.c | sys_send( int fd, void * buff, int len, unsigned flags) |
fd | 686 | net/socket.c | fd, buff, len, flags)); |
fd | 688 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 691 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 700 | net/socket.c | sys_sendto( int fd, void * buff, int len, unsigned flags, |
fd | 707 | net/socket.c | " addr=%X, alen = %d\n", fd, buff, len, flags, addr, addr_len)); |
fd | 709 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 712 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 723 | net/socket.c | sys_recv( int fd, void * buff, int len, unsigned flags) |
fd | 729 | net/socket.c | fd, buff, len, flags)); |
fd | 731 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 734 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 743 | net/socket.c | sys_recvfrom( int fd, void * buff, int len, unsigned flags, |
fd | 750 | net/socket.c | " addr=%X, alen=%X\n", fd, buff, len, flags, addr, addr_len)); |
fd | 752 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 755 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 766 | net/socket.c | sys_setsockopt (int fd, int level, int optname, char *optval, int optlen) |
fd | 771 | net/socket.c | PRINTK (("sys_setsockopt(fd=%d, level=%d, optname=%d,\n",fd, level, |
fd | 775 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 778 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 786 | net/socket.c | sys_getsockopt (int fd, int level, int optname, char *optval, int *optlen) |
fd | 790 | net/socket.c | PRINTK (("sys_getsockopt(fd=%d, level=%d, optname=%d,\n",fd, level, |
fd | 794 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->filp[fd]) == NULL)) |
fd | 797 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 808 | net/socket.c | sys_shutdown( int fd, int how) |
fd | 813 | net/socket.c | PRINTK(("sys_shutdown (fd = %d, how = %d)\n",fd, how)); |
fd | 815 | net/socket.c | file = current->filp[fd]; |
fd | 816 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || file == NULL) |
fd | 819 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |