函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\inode.c Create Date:2022-07-29 10:38:10
Last Modify:2020-03-18 19:19:59 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:mestamp_truncate - Truncate timespec to a granularity*@t: Timespec*@inode: inode being updated* Truncate a timespec to the granularity supported by the fs* containing the inode. Always rounds down. gran must

函数原型:struct timespec64 timestamp_truncate(struct timespec64 t, struct inode *inode)

返回类型:struct timespec64

参数:

类型参数名称
struct timespec64t
struct inode *inode
2190  sb等于i_sb
2191  gran等于s_time_gran
2193  seconds 等于clamp - return a value clamped to a given range with strict typechecking*@val: current value*@lo: lowest allowable value*@hi: highest allowable value* This macro does strict typechecking of @lo/@hi to make sure they are of the* same type as @val( seconds , s_time_min, s_time_max)
2194  如果此条件成立可能性小(为编译器优化)( seconds == s_time_max || seconds == s_time_min)则 nanoseconds 等于0
2198  如果gran恒等于1则否则如果gran恒等于NSEC_PER_SEC
2201  nanoseconds 等于0
2202  否则如果gran大于1且gran小于NSEC_PER_SEC nanoseconds 减等于 nanoseconds 取模gran
2204  否则WARN(1, "invalid file time granularity: %u", gran)
2206  返回:t
调用者
名称描述
current_timerrent_time - Return FS time*@inode: inode.* Return the current time truncated to the time granularity supported by* the fs.* Note that inode and inode->sb cannot be NULL.* Otherwise, the function warns and returns time without truncation.
notify_changey_change - modify attributes of a filesytem object*@dentry: object affected*@attr: new attributes*@delegated_inode: returns inode, if the inode is delegated* The caller must hold the i_mutex on the affected object