tag | line | file | source code |
fd | 42 | arch/alpha/boot/tools/build.c | int fd, i; |
fd | 91 | arch/alpha/boot/tools/build.c | fd = open(infile, O_RDONLY); |
fd | 92 | arch/alpha/boot/tools/build.c | if (fd < 0) { |
fd | 96 | arch/alpha/boot/tools/build.c | if (read(fd, &fhdr, sizeof(struct filehdr)) != sizeof(struct filehdr)) |
fd | 102 | arch/alpha/boot/tools/build.c | if (read(fd, &ahdr, sizeof(struct aouthdr)) != sizeof(struct aouthdr)) |
fd | 105 | arch/alpha/boot/tools/build.c | if (read(fd, i+shdr, sizeof(struct scnhdr)) != sizeof(struct scnhdr)) |
fd | 131 | arch/alpha/boot/tools/build.c | if (lseek(fd, offset, SEEK_SET) != offset) |
fd | 138 | arch/alpha/boot/tools/build.c | if (read(fd, buffer, num) != num) |
fd | 34 | arch/i386/ibcs/binfmt_coff.c | asmlinkage int sys_close (unsigned fd); |
fd | 125 | arch/i386/ibcs/binfmt_coff.c | int fd = -1; /* Open file descriptor */ |
fd | 379 | arch/i386/ibcs/binfmt_coff.c | fd = open_inode (bprm->inode, O_RDONLY); |
fd | 380 | arch/i386/ibcs/binfmt_coff.c | if (fd < 0) { |
fd | 382 | arch/i386/ibcs/binfmt_coff.c | printk ("can not open inode, result = %d\n", fd); |
fd | 384 | arch/i386/ibcs/binfmt_coff.c | status = fd; |
fd | 387 | arch/i386/ibcs/binfmt_coff.c | fp = current->files->fd[fd]; |
fd | 390 | arch/i386/ibcs/binfmt_coff.c | fd = -1; /* Invalidate the open file descriptor */ |
fd | 568 | arch/i386/ibcs/binfmt_coff.c | if (fd >= 0) |
fd | 569 | arch/i386/ibcs/binfmt_coff.c | sys_close (fd); /* Close unused code file */ |
fd | 737 | arch/i386/ibcs/binfmt_coff.c | load_coff_library (int fd) |
fd | 759 | arch/i386/ibcs/binfmt_coff.c | file = current->files->fd[fd]; |
fd | 29 | arch/i386/ibcs/binfmt_elf.c | asmlinkage int sys_close(unsigned fd); |
fd | 172 | arch/i386/ibcs/binfmt_elf.c | file = current->files->fd[elf_exec_fileno]; |
fd | 329 | arch/i386/ibcs/binfmt_elf.c | file = current->files->fd[elf_exec_fileno]; |
fd | 565 | arch/i386/ibcs/binfmt_elf.c | static int load_elf_library(int fd){ |
fd | 578 | arch/i386/ibcs/binfmt_elf.c | file = current->files->fd[fd]; |
fd | 584 | arch/i386/ibcs/binfmt_elf.c | sys_close(fd); |
fd | 637 | arch/i386/ibcs/binfmt_elf.c | sys_close(fd); |
fd | 1556 | drivers/char/tty_io.c | filp = (*p)->files->fd[i]; |
fd | 932 | drivers/net/wavelan.c | fd_t fd; |
fd | 951 | drivers/net/wavelan.c | fd.fd_status = 0; |
fd | 952 | drivers/net/wavelan.c | fd.fd_command = (i == NRXBLOCKS - 1) ? FD_COMMAND_EL : 0; |
fd | 953 | drivers/net/wavelan.c | fd.fd_link_offset = rx_next; |
fd | 954 | drivers/net/wavelan.c | fd.fd_rbd_offset = rx + sizeof(fd); |
fd | 955 | drivers/net/wavelan.c | obram_write(ioaddr, rx, (unsigned char *)&fd, sizeof(fd)); |
fd | 959 | drivers/net/wavelan.c | rbd.rbd_bufl = rx + sizeof(fd) + sizeof(rbd); |
fd | 962 | drivers/net/wavelan.c | obram_write(ioaddr, rx + sizeof(fd), (unsigned char *)&rbd, sizeof(rbd)); |
fd | 1331 | drivers/net/wavelan.c | fd_t fd; |
fd | 1337 | drivers/net/wavelan.c | obram_read(ioaddr, lp->rx_head, (unsigned char *)&fd, sizeof(fd)); |
fd | 1339 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_C) != FD_STATUS_C) |
fd | 1346 | drivers/net/wavelan.c | (fd.fd_status & (FD_STATUS_B | FD_STATUS_OK)) |
fd | 1358 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_OK) != FD_STATUS_OK) |
fd | 1362 | drivers/net/wavelan.c | if ((fd.fd_status & (FD_STATUS_S6 | FD_STATUS_S7 | FD_STATUS_S8 | FD_STATUS_S9 | FD_STATUS_S10 | FD_STATUS_S11)) != 0) |
fd | 1366 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S6) != 0) |
fd | 1369 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S7) != 0) |
fd | 1375 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S8) != 0) |
fd | 1381 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S9) != 0) |
fd | 1387 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S10) != 0) |
fd | 1393 | drivers/net/wavelan.c | if ((fd.fd_status & FD_STATUS_S11) != 0) |
fd | 1400 | drivers/net/wavelan.c | if (fd.fd_rbd_offset == I82586NULL) |
fd | 1404 | drivers/net/wavelan.c | obram_read(ioaddr, fd.fd_rbd_offset, (unsigned char *)&rbd, sizeof(rbd)); |
fd | 1450 | drivers/net/wavelan.c | printk("%s%02x", (i == 0) ? "" : ":", fd.fd_dest[i]); |
fd | 1455 | drivers/net/wavelan.c | printk("%s%02x", (i == 0) ? "" : ":", fd.fd_src[i]); |
fd | 1457 | drivers/net/wavelan.c | printk("%s: fd_length=%d\n", dev->name, fd.fd_length); |
fd | 1523 | drivers/net/wavelan.c | fd.fd_status = 0; |
fd | 1524 | drivers/net/wavelan.c | obram_write(ioaddr, fdoff(lp->rx_head, fd_status), (unsigned char *)&fd.fd_status, sizeof(fd.fd_status)); |
fd | 1526 | drivers/net/wavelan.c | fd.fd_command = FD_COMMAND_EL; |
fd | 1527 | drivers/net/wavelan.c | obram_write(ioaddr, fdoff(lp->rx_head, fd_command), (unsigned char *)&fd.fd_command, sizeof(fd.fd_command)); |
fd | 1529 | drivers/net/wavelan.c | fd.fd_command = 0; |
fd | 1530 | drivers/net/wavelan.c | obram_write(ioaddr, fdoff(lp->rx_last, fd_command), (unsigned char *)&fd.fd_command, sizeof(fd.fd_command)); |
fd | 1533 | drivers/net/wavelan.c | lp->rx_head = fd.fd_link_offset; |
fd | 355 | drivers/sound/configure.c | int fd; |
fd | 360 | drivers/sound/configure.c | if ((fd = open (path, 0)) > 0) |
fd | 368 | drivers/sound/configure.c | count = read (fd, &c, 1); |
fd | 379 | drivers/sound/configure.c | close (fd); |
fd | 50 | fs/binfmt_elf.c | static int load_elf_library(int fd); |
fd | 206 | fs/binfmt_elf.c | file = current->files->fd[elf_exec_fileno]; |
fd | 374 | fs/binfmt_elf.c | file = current->files->fd[elf_exec_fileno]; |
fd | 636 | fs/binfmt_elf.c | load_elf_library(int fd){ |
fd | 650 | fs/binfmt_elf.c | file = current->files->fd[fd]; |
fd | 656 | fs/binfmt_elf.c | SYS(close)(fd); |
fd | 715 | fs/binfmt_elf.c | SYS(close)(fd); |
fd | 240 | fs/buffer.c | asmlinkage int sys_fsync(unsigned int fd) |
fd | 245 | fs/buffer.c | if (fd>=NR_OPEN || !(file=current->files->fd[fd]) || !(inode=file->f_inode)) |
fd | 53 | fs/exec.c | static int load_aout_library(int fd); |
fd | 107 | fs/exec.c | int error, fd; |
fd | 115 | fs/exec.c | fd = 0; |
fd | 116 | fs/exec.c | fpp = current->files->fd; |
fd | 120 | fs/exec.c | if (++fd >= NR_OPEN) { |
fd | 142 | fs/exec.c | return fd; |
fd | 272 | fs/exec.c | int fd, retval; |
fd | 276 | fs/exec.c | fd = sys_open(library, 0, 0); |
fd | 277 | fs/exec.c | if (fd < 0) |
fd | 278 | fs/exec.c | return fd; |
fd | 279 | fs/exec.c | file = current->files->fd[fd]; |
fd | 286 | fs/exec.c | retval = fn(fd); |
fd | 291 | fs/exec.c | sys_close(fd); |
fd | 741 | fs/exec.c | int fd, error; |
fd | 787 | fs/exec.c | fd = open_inode(bprm->inode, O_RDONLY); |
fd | 789 | fs/exec.c | if (fd < 0) |
fd | 790 | fs/exec.c | return fd; |
fd | 791 | fs/exec.c | file = current->files->fd[fd]; |
fd | 793 | fs/exec.c | sys_close(fd); |
fd | 808 | fs/exec.c | sys_close(fd); |
fd | 817 | fs/exec.c | sys_close(fd); |
fd | 850 | fs/exec.c | static int load_aout_library(int fd) |
fd | 860 | fs/exec.c | file = current->files->fd[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->files->fd[fd]) |
fd | 27 | fs/fcntl.c | if (current->files->fd[arg]) |
fd | 34 | fs/fcntl.c | (current->files->fd[arg] = current->files->fd[fd])->f_count++; |
fd | 40 | fs/fcntl.c | if (oldfd >= NR_OPEN || !current->files->fd[oldfd]) |
fd | 66 | fs/fcntl.c | asmlinkage int sys_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg) |
fd | 72 | fs/fcntl.c | if (fd >= NR_OPEN || !(filp = current->files->fd[fd])) |
fd | 76 | fs/fcntl.c | return dupfd(fd,arg); |
fd | 78 | fs/fcntl.c | return FD_ISSET(fd, ¤t->files->close_on_exec); |
fd | 81 | fs/fcntl.c | FD_SET(fd, ¤t->files->close_on_exec); |
fd | 83 | fs/fcntl.c | FD_CLR(fd, ¤t->files->close_on_exec); |
fd | 105 | fs/fcntl.c | return fcntl_getlk(fd, (struct flock *) arg); |
fd | 107 | fs/fcntl.c | return fcntl_setlk(fd, cmd, (struct flock *) arg); |
fd | 109 | fs/fcntl.c | return fcntl_setlk(fd, cmd, (struct flock *) arg); |
fd | 58 | fs/ioctl.c | asmlinkage int sys_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg) |
fd | 63 | fs/ioctl.c | if (fd >= NR_OPEN || !(filp = current->files->fd[fd])) |
fd | 67 | fs/ioctl.c | FD_SET(fd, ¤t->files->close_on_exec); |
fd | 71 | fs/ioctl.c | FD_CLR(fd, ¤t->files->close_on_exec); |
fd | 58 | fs/locks.c | int fcntl_getlk(unsigned int fd, struct flock *l) |
fd | 65 | fs/locks.c | if (fd >= NR_OPEN || !(filp = current->files->fd[fd])) |
fd | 98 | fs/locks.c | int fcntl_setlk(unsigned int fd, unsigned int cmd, struct flock *l) |
fd | 109 | fs/locks.c | if (fd >= NR_OPEN || !(filp = current->files->fd[fd])) |
fd | 77 | fs/nfs/inode.c | unsigned int fd; |
fd | 88 | fs/nfs/inode.c | fd = data->fd; |
fd | 93 | fs/nfs/inode.c | if (fd >= NR_OPEN || !(filp = current->files->fd[fd])) { |
fd | 50 | fs/open.c | asmlinkage int sys_fstatfs(unsigned int fd, struct statfs * buf) |
fd | 59 | fs/open.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 111 | fs/open.c | asmlinkage int sys_ftruncate(unsigned int fd, unsigned int length) |
fd | 117 | fs/open.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 227 | fs/open.c | asmlinkage int sys_fchdir(unsigned int fd) |
fd | 233 | fs/open.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 268 | fs/open.c | asmlinkage int sys_fchmod(unsigned int fd, mode_t mode) |
fd | 274 | fs/open.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 313 | fs/open.c | asmlinkage int sys_fchown(unsigned int fd, uid_t user, gid_t group) |
fd | 319 | fs/open.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 412 | fs/open.c | int flag,error,fd; |
fd | 414 | fs/open.c | for(fd=0; fd<NR_OPEN && fd<current->rlim[RLIMIT_NOFILE].rlim_cur; fd++) |
fd | 415 | fs/open.c | if (!current->files->fd[fd]) |
fd | 417 | fs/open.c | if (fd>=NR_OPEN || fd>=current->rlim[RLIMIT_NOFILE].rlim_cur) |
fd | 419 | fs/open.c | FD_CLR(fd,¤t->files->close_on_exec); |
fd | 423 | fs/open.c | current->files->fd[fd] = f; |
fd | 437 | fs/open.c | current->files->fd[fd]=NULL; |
fd | 454 | fs/open.c | current->files->fd[fd]=NULL; |
fd | 459 | fs/open.c | return (fd); |
fd | 504 | fs/open.c | asmlinkage int sys_close(unsigned int fd) |
fd | 508 | fs/open.c | if (fd >= NR_OPEN) |
fd | 510 | fs/open.c | FD_CLR(fd, ¤t->files->close_on_exec); |
fd | 511 | fs/open.c | if (!(filp = current->files->fd[fd])) |
fd | 513 | fs/open.c | current->files->fd[fd] = NULL; |
fd | 383 | fs/pipe.c | int fd[2]; |
fd | 398 | fs/pipe.c | if (!current->files->fd[i]) { |
fd | 399 | fs/pipe.c | current->files->fd[ fd[j]=i ] = f[j]; |
fd | 403 | fs/pipe.c | current->files->fd[fd[0]]=NULL; |
fd | 410 | fs/pipe.c | current->files->fd[fd[0]] = NULL; |
fd | 411 | fs/pipe.c | current->files->fd[fd[1]] = NULL; |
fd | 424 | fs/pipe.c | put_fs_long(fd[0],0+fildes); |
fd | 425 | fs/pipe.c | put_fs_long(fd[1],1+fildes); |
fd | 56 | fs/proc/fd.c | unsigned int ino, pid, fd, c; |
fd | 86 | fs/proc/fd.c | fd = 0; |
fd | 91 | fs/proc/fd.c | fd = 0xfffff; |
fd | 94 | fs/proc/fd.c | fd *= 10; |
fd | 95 | fs/proc/fd.c | fd += c; |
fd | 96 | fs/proc/fd.c | if (fd & 0xffff0000) { |
fd | 97 | fs/proc/fd.c | fd = 0xfffff; |
fd | 107 | fs/proc/fd.c | if (fd >= NR_OPEN || !p->files->fd[fd] || !p->files->fd[fd]->f_inode) |
fd | 110 | fs/proc/fd.c | ino = (pid << 16) + (PROC_PID_FD_DIR << 8) + fd; |
fd | 121 | fs/proc/fd.c | unsigned int fd, pid, ino; |
fd | 132 | fs/proc/fd.c | fd = filp->f_pos; |
fd | 134 | fs/proc/fd.c | if (fd < 2) { |
fd | 135 | fs/proc/fd.c | i = j = fd+1; |
fd | 136 | fs/proc/fd.c | if (!fd) |
fd | 137 | fs/proc/fd.c | fd = inode->i_ino; |
fd | 139 | fs/proc/fd.c | fd = (inode->i_ino & 0xffff0000) | PROC_PID_INO; |
fd | 140 | fs/proc/fd.c | put_fs_long(fd, &dirent->d_ino); |
fd | 147 | fs/proc/fd.c | fd -= 2; |
fd | 153 | fs/proc/fd.c | if (fd >= NR_OPEN) |
fd | 156 | fs/proc/fd.c | if (!p->files->fd[fd] || !p->files->fd[fd]->f_inode) |
fd | 161 | fs/proc/fd.c | while (fd >= j) { |
fd | 166 | fs/proc/fd.c | ino = (pid << 16) + (PROC_PID_FD_DIR << 8) + fd; |
fd | 172 | fs/proc/fd.c | put_fs_byte('0'+(fd % 10), i+dirent->d_name); |
fd | 173 | fs/proc/fd.c | fd /= 10; |
fd | 239 | fs/proc/inode.c | if (ino >= NR_OPEN || !p->files->fd[ino]) |
fd | 244 | fs/proc/inode.c | if (p->files->fd[ino]->f_mode & 1) |
fd | 246 | fs/proc/inode.c | if (p->files->fd[ino]->f_mode & 2) |
fd | 69 | fs/proc/link.c | int i, fd; |
fd | 73 | fs/proc/link.c | for(fd=0 ; fd<NR_OPEN ; fd++) |
fd | 74 | fs/proc/link.c | if (current->files->fd[fd] == f) |
fd | 76 | fs/proc/link.c | if (fd>=NR_OPEN) |
fd | 88 | fs/proc/link.c | ((ino >> 8) != 1) || !(new_f = p->files->fd[ino & 0x0ff])) |
fd | 95 | fs/proc/link.c | current->files->fd[fd] = new_f; |
fd | 151 | fs/proc/link.c | if (ino < NR_OPEN && p->files->fd[ino]) { |
fd | 158 | fs/proc/link.c | new_inode = p->files->fd[ino]->f_inode; |
fd | 26 | fs/read_write.c | asmlinkage int sys_readdir(unsigned int fd, struct dirent * dirent, unsigned int count) |
fd | 32 | fs/read_write.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd]) || |
fd | 47 | fs/read_write.c | asmlinkage int sys_lseek(unsigned int fd, off_t offset, unsigned int origin) |
fd | 52 | fs/read_write.c | if (fd >= NR_OPEN || !(file=current->files->fd[fd]) || !(file->f_inode)) |
fd | 83 | fs/read_write.c | asmlinkage int sys_llseek(unsigned int fd, unsigned long offset_high, |
fd | 92 | fs/read_write.c | if (fd >= NR_OPEN || !(file=current->files->fd[fd]) || !(file->f_inode)) |
fd | 122 | fs/read_write.c | asmlinkage int sys_read(unsigned int fd,char * buf,unsigned int count) |
fd | 128 | fs/read_write.c | if (fd>=NR_OPEN || !(file=current->files->fd[fd]) || !(inode=file->f_inode)) |
fd | 142 | fs/read_write.c | asmlinkage int sys_write(unsigned int fd,char * buf,unsigned int count) |
fd | 149 | fs/read_write.c | if (fd>=NR_OPEN || !(file=current->files->fd[fd]) || !(inode=file->f_inode)) |
fd | 105 | fs/select.c | if (!current->files->fd[i]) |
fd | 107 | fs/select.c | if (!current->files->fd[i]->f_inode) |
fd | 126 | fs/select.c | if (FD_ISSET(i,in) && check(SEL_IN,wait,current->files->fd[i])) { |
fd | 131 | fs/select.c | if (FD_ISSET(i,out) && check(SEL_OUT,wait,current->files->fd[i])) { |
fd | 136 | fs/select.c | if (FD_ISSET(i,ex) && check(SEL_EX,wait,current->files->fd[i])) { |
fd | 161 | fs/stat.c | asmlinkage int sys_fstat(unsigned int fd, struct old_stat * statbuf) |
fd | 170 | fs/stat.c | if (fd >= NR_OPEN || !(f=current->files->fd[fd]) || !(inode=f->f_inode)) |
fd | 176 | fs/stat.c | asmlinkage int sys_newfstat(unsigned int fd, struct new_stat * statbuf) |
fd | 185 | fs/stat.c | if (fd >= NR_OPEN || !(f=current->files->fd[fd]) || !(inode=f->f_inode)) |
fd | 79 | include/asm-alpha/unistd.h | int fd; |
fd | 81 | include/asm-alpha/unistd.h | fd = sys_open(name, mode, flags); |
fd | 82 | include/asm-alpha/unistd.h | printk("[%d]open(%s,%d,%d)=%d\n",current->pid, name, mode, flags, fd); |
fd | 83 | include/asm-alpha/unistd.h | return fd; |
fd | 87 | include/asm-alpha/unistd.h | static inline int dup(int fd) |
fd | 89 | include/asm-alpha/unistd.h | int newfd = sys_dup(fd); |
fd | 90 | include/asm-alpha/unistd.h | printk("[%d]dup(%d)=%d\n",current->pid, fd, newfd); |
fd | 94 | include/asm-alpha/unistd.h | static inline int close(int fd) |
fd | 96 | include/asm-alpha/unistd.h | printk("[%d]close(%d)\n",current->pid,fd); |
fd | 97 | include/asm-alpha/unistd.h | return sys_close(fd); |
fd | 110 | include/asm-alpha/unistd.h | static inline int write(int fd, const char * buf, int nr) |
fd | 112 | include/asm-alpha/unistd.h | return sys_write(fd, buf, nr); |
fd | 116 | include/asm-alpha/unistd.h | static inline int read(int fd, char * buf, int nr) |
fd | 118 | include/asm-alpha/unistd.h | int res = sys_read(fd, buf, nr); |
fd | 119 | include/asm-alpha/unistd.h | printk("[%d]read(%d,%s,%d)=%d\n",current->pid, fd, buf, nr, res); |
fd | 108 | include/asm-i386/unistd.h | static inline _syscall3(int,write,int,fd,const char *,buf,off_t,count) |
fd | 109 | include/asm-i386/unistd.h | static inline _syscall1(int,dup,int,fd) |
fd | 112 | include/asm-i386/unistd.h | static inline _syscall1(int,close,int,fd) |
fd | 148 | include/asm-sparc/unistd.h | static inline _syscall3(int,write,int,fd,const char *,buf,off_t,count) |
fd | 149 | include/asm-sparc/unistd.h | static inline _syscall1(int,dup,int,fd) |
fd | 152 | include/asm-sparc/unistd.h | static inline _syscall1(int,close,int,fd) |
fd | 35 | include/linux/binfmts.h | int (*load_shlib)(int fd); |
fd | 24 | include/linux/nfs_mount.h | int fd; /* 1 */ |
fd | 89 | include/linux/sched.h | struct file * fd[NR_OPEN]; |
fd | 21 | include/linux/time.h | #define FD_SET(fd,fdsetp) set_bit(fd,fdsetp) |
fd | 22 | include/linux/time.h | #define FD_CLR(fd,fdsetp) clear_bit(fd,fdsetp) |
fd | 23 | include/linux/time.h | #define FD_ISSET(fd,fdsetp) (0 != test_bit(fd,fdsetp)) |
fd | 27 | include/linux/time.h | #define FD_SET(fd,fdsetp) __FD_SET(fd,fdsetp) |
fd | 28 | include/linux/time.h | #define FD_CLR(fd,fdsetp) __FD_CLR(fd,fdsetp) |
fd | 29 | include/linux/time.h | #define FD_ISSET(fd,fdsetp) __FD_ISSET(fd,fdsetp) |
fd | 83 | include/linux/types.h | #define __FD_SET(fd,fdsetp) \ |
fd | 85 | include/linux/types.h | "=m" (*(fd_set *) (fdsetp)):"r" ((int) (fd))) |
fd | 88 | include/linux/types.h | #define __FD_CLR(fd,fdsetp) \ |
fd | 90 | include/linux/types.h | "=m" (*(fd_set *) (fdsetp)):"r" ((int) (fd))) |
fd | 93 | include/linux/types.h | #define __FD_ISSET(fd,fdsetp) (__extension__ ({ \ |
fd | 96 | include/linux/types.h | :"=q" (__result) :"r" ((int) (fd)), \ |
fd | 362 | kernel/exit.c | if (current->files->fd[i]) |
fd | 124 | kernel/fork.c | if ((f = p->files->fd[i]) != NULL) |
fd | 125 | kernel/fork.c | p->files->fd[i] = copy_fd(f); |
fd | 128 | kernel/fork.c | if ((f = p->files->fd[i]) != NULL) |
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 | 198 | mm/mmap.c | unsigned long fd = get_fs_long(buffer+4); |
fd | 199 | mm/mmap.c | if (fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 161 | net/socket.c | int fd; |
fd | 172 | net/socket.c | for (fd = 0; fd < NR_OPEN; ++fd) |
fd | 173 | net/socket.c | if (!current->files->fd[fd]) |
fd | 175 | net/socket.c | if (fd == NR_OPEN) |
fd | 181 | net/socket.c | FD_CLR(fd, ¤t->files->close_on_exec); |
fd | 182 | net/socket.c | current->files->fd[fd] = file; |
fd | 191 | net/socket.c | return(fd); |
fd | 210 | net/socket.c | static inline struct socket *sockfd_lookup(int fd, struct file **pfile) |
fd | 215 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || !(file = current->files->fd[fd])) |
fd | 600 | net/socket.c | int i, fd; |
fd | 651 | net/socket.c | if ((fd = get_fd(SOCK_INODE(sock))) < 0) |
fd | 657 | net/socket.c | return(fd); |
fd | 729 | net/socket.c | static int sock_bind(int fd, struct sockaddr *umyaddr, int addrlen) |
fd | 736 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || current->files->fd[fd] == NULL) |
fd | 739 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 759 | net/socket.c | static int sock_listen(int fd, int backlog) |
fd | 763 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || current->files->fd[fd] == NULL) |
fd | 765 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 788 | net/socket.c | static int sock_accept(int fd, struct sockaddr *upeer_sockaddr, int *upeer_addrlen) |
fd | 796 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 798 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) |
fd | 830 | net/socket.c | if ((fd = get_fd(SOCK_INODE(newsock))) < 0) |
fd | 841 | net/socket.c | return(fd); |
fd | 850 | net/socket.c | static int sock_connect(int fd, struct sockaddr *uservaddr, int addrlen) |
fd | 858 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || (file=current->files->fd[fd]) == NULL) |
fd | 860 | net/socket.c | if (!(sock = sockfd_lookup(fd, &file))) |
fd | 901 | net/socket.c | static int sock_getsockname(int fd, struct sockaddr *usockaddr, int *usockaddr_len) |
fd | 908 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || current->files->fd[fd] == NULL) |
fd | 910 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 926 | net/socket.c | static int sock_getpeername(int fd, struct sockaddr *usockaddr, int *usockaddr_len) |
fd | 933 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || current->files->fd[fd] == NULL) |
fd | 935 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 951 | net/socket.c | static int sock_send(int fd, void * buff, int len, unsigned flags) |
fd | 957 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 959 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 976 | net/socket.c | static int sock_sendto(int fd, void * buff, int len, unsigned flags, |
fd | 984 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 986 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 1011 | net/socket.c | static int sock_recv(int fd, void * buff, int len, unsigned flags) |
fd | 1017 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 1020 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 1040 | net/socket.c | static int sock_recvfrom(int fd, void * buff, int len, unsigned flags, |
fd | 1048 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 1050 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 1077 | net/socket.c | static int sock_setsockopt(int fd, int level, int optname, char *optval, int optlen) |
fd | 1082 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 1084 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 1095 | net/socket.c | static int sock_getsockopt(int fd, int level, int optname, char *optval, int *optlen) |
fd | 1100 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 1102 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |
fd | 1115 | net/socket.c | static int sock_shutdown(int fd, int how) |
fd | 1120 | net/socket.c | if (fd < 0 || fd >= NR_OPEN || ((file = current->files->fd[fd]) == NULL)) |
fd | 1122 | net/socket.c | if (!(sock = sockfd_lookup(fd, NULL))) |