Function report |
Source Code:block\badblocks.c |
Create Date:2022-07-28 17:24:40 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:adblocks_show() - sysfs access to bad-blocks list*@bb: the badblocks structure that holds all badblock information*@page: buffer received from sysfs*@unack: weather to show unacknowledged badblocks* Return:* Length of returned data
Proto:ssize_t badblocks_show(struct badblocks *bb, char *page, int unack)
Type:ssize_t
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct badblocks * | bb | |
| char * | page | |
| int | unack |
| 471 | p = badblock list |
| 474 | If shift from sectors to block size * a -ve shift means badblocks are * disabled. < 0 Then Return 0 |
| 477 | retry : |
| 480 | len = 0 |
| 481 | i = 0 |
| 483 | When len < PAGE_SIZE && i < count of bad blocks cycle |
| 488 | i++ |
| 497 | If unack && len == 0 Then there probably are unacknowledged * bad blocks. This is only cleared * when a read discovers none = 0 |
| 500 | If read_seqretry( & lock, seq) Then Go to retry |
| 503 | Return len |
| 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 |