Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\dmapool.c Create Date:2022-07-28 15:23:57
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:show_pools

Proto:static ssize_t show_pools(struct device *dev, struct device_attribute *attr, char *buf)

Type:ssize_t

Parameter:

TypeParameterName
struct device *dev
struct device_attribute *attr
char *buf
73  next = buf
74  size = PAGE_SIZE
76  temp = scnprintf - Format a string and place it in a buffer*@buf: The buffer to place the result into*@size: The size of the buffer, including the trailing null space*@fmt: The format string to use*@
77  size -= temp
78  next += temp
80  mutex_lock( & pools_lock)
82  pages = 0
83  blocks = 0
85  spin_lock_irq( & lock)
87  pages++
88  blocks += in_use
90  spin_unlock_irq( & lock)
93  temp = scnprintf - Format a string and place it in a buffer*@buf: The buffer to place the result into*@size: The size of the buffer, including the trailing null space*@fmt: The format string to use*@
97  size -= temp
98  next += temp
100  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
102  Return PAGE_SIZE - size