Function report |
Source Code:fs\iomap\swapfile.c |
Create Date:2022-07-28 20:32:27 |
| Last Modify:2020-03-18 11:03:10 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Accumulate iomaps for this swap file. We have to accumulate iomaps because* swap only cares about contiguous page-aligned physical extents and makes no* distinction between written and unwritten extents.
Proto:static loff_t iomap_swapfile_activate_actor(struct inode *inode, loff_t pos, loff_t count, void *data, struct iomap *iomap, struct iomap *srcmap)
Type:loff_t
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct inode * | inode | |
| loff_t | pos | |
| loff_t | count | |
| void * | data | |
| struct iomap * | iomap | |
| struct iomap * | srcmap |
| 86 | Case type of mapping == locks allocated at @addr |
| 89 | Break |
| 90 | Case type of mapping == data inline in the inode |
| 94 | Default |
| 100 | If flags for mapping & IOMAP_F_DIRTY Then |
| 104 | If flags for mapping & IOMAP_F_SHARED Then |
| 110 | If block device for I/O != swap device or bdev of swap file Then |
| 115 | If length of mapping, bytes == 0 Then |
| 117 | memcpy( & accumulated iomap , iomap, size of accumulated iomap ) |
| 118 | Else if disk offset of mapping, bytes + length of mapping, bytes == disk offset of mapping, bytes Then |
| 121 | Else |
| 126 | memcpy( & accumulated iomap , iomap, size of accumulated iomap ) |
| 128 | Return count |
| 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 |