函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:simple_write_to_buffer - copy data from user space to the buffer*@to: the buffer to write to*@available: the size of the buffer*@ppos: the current position in the buffer*@from: the user space buffer to read from*@count: the maximum number of bytes to

函数原型:ssize_t simple_write_to_buffer(void *to, size_t available, loff_t *ppos, const void __user *from, size_t count)

返回类型:ssize_t

参数:

类型参数名称
void *to
size_tavailable
loff_t *ppos
const void __user *from
size_tcount
683  pos等于ppos
686  如果pos小于0则返回:负EINVAL
688  如果pos大于等于available或非count则返回:0
690  如果count大于availableposcount等于availablepos
692  res等于copy_from_user(to + pos, from, count)
693  如果res恒等于count则返回:负EFAULT
695  count减等于res
696  ppos等于poscount
697  返回:count
调用者
名称描述
snapshot_write