/* * linux/fs/stat.c * * (C) 1991 Linus Torvalds */ #include #include #include #include #include #include static void cp_stat(struct m_inode * inode, struct stat * statbuf) { struct stat tmp; int i; verify_area(statbuf,sizeof (* statbuf)); tmp.st_dev = inode->i_dev; tmp.st_ino = inode->i_num; tmp.st_mode = inode->i_mode; tmp.st_nlink = inode->i_nlinks; tmp.st_uid = inode->i_uid; tmp.st_gid = inode->i_gid; tmp.st_rdev = inode->i_zone[0]; tmp.st_size = inode->i_size; tmp.st_atime = inode->i_atime; tmp.st_mtime = inode->i_mtime; tmp.st_ctime = inode->i_ctime; for (i=0 ; i= NR_OPEN || !(f=current->filp[fd]) || !(inode=f->f_inode)) return -EBADF; cp_stat(inode,statbuf); return 0; } int sys_readlink() { return -ENOSYS; }