Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:quota_send_warning - Send warning to userspace about exceeded quota*@qid: The kernel internal quota identifier

Proto:void quota_send_warning(struct kqid qid, dev_t dev, const char warntype)

Type:void

Parameter:

TypeParameterName
struct kqidqid
dev_tdev
const charwarntype
44  msg_size = 4 * la_total_size - total length of attribute including padding*@payload: length of payload + 2 * la_total_size_64bit - total length of attribute including padding*@payload: length of payload
50  skb = genlmsg_new - Allocate a new generic netlink message*@payload: size of the message payload*@flags: the type of memory to allocate.
51  If Not skb Then
52  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
54  Return
56  msg_head = genlmsg_put(skb, 0, atomic_add_return(1, & seq), & Netlink family structure for quota , 0, QUOTA_NL_C_WARNING)
58  If Not msg_head Then
59  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
61  Go to err_out
63  ret = la_put_u32 - Add a u32 netlink attribute to a socket buffer*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value
64  If ret Then Go to attr_err_out
66  ret = la_put_u64_64bit - Add a u64 netlink attribute to a skb and align it*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value*@padattr: attribute type for the padding
69  If ret Then Go to attr_err_out
71  ret = la_put_u32 - Add a u32 netlink attribute to a socket buffer*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value
72  If ret Then Go to attr_err_out
74  ret = la_put_u32 - Add a u32 netlink attribute to a socket buffer*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value
75  If ret Then Go to attr_err_out
77  ret = la_put_u32 - Add a u32 netlink attribute to a socket buffer*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value
78  If ret Then Go to attr_err_out
80  ret = la_put_u64_64bit - Add a u64 netlink attribute to a skb and align it*@skb: socket buffer to add attribute to*@attrtype: attribute type*@value: numeric value*@padattr: attribute type for the padding
83  If ret Then Go to attr_err_out
85  genlmsg_end - Finalize a generic netlink message*@skb: socket buffer the message is stored in*@hdr: user specific header
87  genlmsg_multicast - multicast a netlink message to the default netns*@family: the generic netlink family*@skb: netlink message as socket buffer*@portid: own netlink portid to avoid sending to yourself*@group: offset of multicast group in groups
88  Return
89  attr_err_out :
90  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
91  err_out :
92  free an sk_buff