Rules listed through the error_injection debugfs file omit the block operation they match. As a result, rules that differ only in operation are indistinguishable even though op is mandatory when adding a rule.
Showing the changes to block (1 of 1 file). Show all
Unified · Split
| @@ -276,9 +276,10 @@ static int blk_error_injection_show(struct seq_file *s, void *private) · 275 unmodified lines | ||
| 276 | 276 | |
| 277 | 277 | rcu_read_lock(); |
| 278 | 278 | list_for_each_entry_rcu(inj, &disk->error_injection_list, entry) { |
| 279 | − seq_printf(s, "%llu:%llu status=%s,chance=%u", | |
| 280 | − inj->start, inj->end, | |
| 281 | − blk_status_to_tag(inj->status), inj->chance); | |
| 279 | + seq_printf(s, "%llu:%llu op=%s,status=%s,chance=%u", | |
| 280 | + inj->start, inj->end, | |
| 281 | + blk_op_str(inj->op), | |
| 282 | + blk_status_to_tag(inj->status), inj->chance); | |
| 282 | 283 | seq_putc(s, '\n'); |
| 283 | 284 | } |
| 284 | 285 | rcu_read_unlock(); |