Function report |
Source Code:fs\aio.c |
Create Date:2022-07-28 20:21:15 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:aio_read_events_ring* Pull an event off of the ioctx's event ring. Returns the number of* events fetched
Proto:static long aio_read_events_ring(struct kioctx *ctx, struct io_event __user *event, long nr)
Type:long
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct kioctx * | ctx | |
| struct io_event __user * | event | |
| long | nr |
| 1178 | ret = 0 |
| 1187 | sched_annotate_sleep() |
| 1188 | mutex_lock( & ring_lock) |
| 1191 | ring = kmap_atomic(ring_pages[0]) |
| 1194 | Prevent people trying to call kunmap_atomic() as if it were kunmap()* kunmap_atomic() should get the return value of kmap_atomic, not the page.(ring) |
| 1200 | smp_rmb() |
| 1202 | pr_debug("h%u t%u m%u\n", head, tail, Size of ringbuffer, in units of struct io_event ) |
| 1219 | pos = head + AIO_EVENTS_OFFSET |
| 1220 | page = ring_pages[pos / AIO_EVENTS_PER_PAGE] |
| 1221 | pos %= AIO_EVENTS_PER_PAGE |
| 1223 | avail = min - return minimum of two values of the same or compatible types*@x: first value*@y: second value(avail, nr - ret) |
| 1241 | ring = kmap_atomic(ring_pages[0]) |
| 1243 | Prevent people trying to call kunmap_atomic() as if it were kunmap()* kunmap_atomic() should get the return value of kmap_atomic, not the page.(ring) |
| 1244 | flush_dcache_page(ring_pages[0]) |
| 1247 | out : |
| 1250 | Return ret |
| Name | Describe |
|---|---|
| aio_read_events |
| Source code conversion tool public plug-in interface | X |
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |