Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:ipc\mqueue.c Create Date:2022-07-28 16:50:45
Last Modify:2020-03-17 23:00:47 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:mqueue_create_attr

Proto:static int mqueue_create_attr(struct dentry *dentry, umode_t mode, void *arg)

Type:int

Parameter:

TypeParameterName
struct dentry *dentry
umode_tmode
void *arg
494  dir = Where the name belongs to - NULL is * negative
496  attr = arg
500  spin_lock( & mq_lock)
501  ipc_ns = This routine should be called with the mq_lock held.
502  If Not ipc_ns Then
503  error = -EACCES
504  Go to out_unlock
507  If mq_queues_count >= mq_queues_max && Not Check operation authority Then
509  error = -ENOSPC
510  Go to out_unlock
512  mq_queues_count++
513  spin_unlock( & mq_lock)
515  inode = mqueue_get_inode(i_sb, ipc_ns, mode, attr)
516  If IS_ERR(inode) Then
517  error = PTR_ERR(inode)
518  spin_lock( & mq_lock)
519  mq_queues_count--
520  Go to out_unlock
523  put_ipc_ns(ipc_ns)
524  i_size += DIRENT_SIZE
525  i_ctime = i_mtime = i_atime = current_time(dir)
527  These are the low-level FS interfaces to the dcache..
528  get a reference to a dentry
529  Return 0
530  out_unlock :
531  spin_unlock( & mq_lock)
532  If ipc_ns Then put_ipc_ns(ipc_ns)
534  Return error
Caller
NameDescribe
mqueue_create