Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\libfs.c Create Date:2022-07-28 20:10:25
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:simple_transaction_get

Proto:char *simple_transaction_get(struct file *file, const char __user *buf, size_t size)

Type:char

Parameter:

TypeParameterName
struct file *file
const char __user *buf
size_tsize
758  DEFINE_SPINLOCK(simple_transaction_lock)
760  If size > SIMPLE_TRANSACTION_LIMIT - 1 Then Return ERR_PTR( - EFBIG)
763  ar = get_zeroed_page(GFP_KERNEL)
764  If Not ar Then Return ERR_PTR( - ENOMEM)
767  spin_lock( & simple_transaction_lock)
770  If needed for tty driver, and maybe others Then
771  spin_unlock( & simple_transaction_lock)
772  free_page((unsignedlong)ar)
773  Return ERR_PTR( - EBUSY)
776  needed for tty driver, and maybe others = ar
778  spin_unlock( & simple_transaction_lock)
780  If copy_from_user(data, buf, size) Then Return ERR_PTR( - EFAULT)
783  Return data
Caller
NameDescribe
smk_user_accesssmk_user_access - handle access check transaction*@file: file pointer*@buf: data from user space*@count: bytes sent*@ppos: where to start - must be 0