函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\stat.c Create Date:2022-07-29 10:32:55
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:For backward compatibility? Maybe this should be moved* into arch/i386 instead?

函数原型:static int cp_old_stat(struct kstat *stat, struct __old_kernel_stat __user *statbuf)

返回类型:int

参数:

类型参数名称
struct kstat *stat
struct __old_kernel_stat __user *statbuf
211  warncount等于5
214  如果warncount大于0则
215  warncount自减
216  printk - print a kernel message*@fmt: format string* This is printk(). It can be called from any context. We want it to work.* We try to grab the console_lock. If we succeed, it's easy - we log the* output and call the console drivers
218  否则如果warncount小于0则
220  warncount等于0
223  memset( & tmp, 0, sizeof(struct__old_kernel_stat))
224  st_dev等于old_encode_dev(dev)
225  st_ino等于ino
226  如果st_ino的长度小于ino的长度且st_ino不等于ino则返回:负EOVERFLOW
228  st_mode等于mode
229  st_nlink等于nlink
230  如果st_nlink不等于nlink则返回:负EOVERFLOW
232  uid/gid input should be always 32bit uid_t (st_uid, from_kuid_munged(current_user_ns(), uid))
233  SET_GID(st_gid, from_kgid_munged(current_user_ns(), gid))
234  st_rdev等于old_encode_dev(rdev)
236  如果size大于MAX_NON_LFS则返回:负EOVERFLOW
239  st_size等于size
240  st_atime等于tv_sec
241  st_mtime等于 seconds
242  st_ctime等于 seconds
243  返回:如果copy_to_user(statbuf, & tmp, tmp的长度)则负EFAULT否则0
调用者
名称描述
SYSCALL_DEFINE2
SYSCALL_DEFINE2
SYSCALL_DEFINE2