History

block: Fix secure erase

Commit 288dab8a35a0 ("block: add a separate operation type for secure erase") split REQ_OP_SECURE_ERASE from REQ_OP_DISCARD without considering all the places REQ_OP_DISCARD was being used to mean either. Fix those.

Adrian Hunter committed 10 years ago

Commit 7afafc81 parent f6b6a289 files · +50 −32Browse files

Showing the changes to kernel (1 of 9 files). Show all

Unified · Split

kernel/trace/blktrace.c+1−1
@@ -223,7 +223,7 @@ static void __blk_add_trace(struct blk_trace *bt, sector_t sector, int bytes, · 222 unmodified lines
223223 what |= MASK_TC_BIT(op_flags, META);
224224 what |= MASK_TC_BIT(op_flags, PREFLUSH);
225225 what |= MASK_TC_BIT(op_flags, FUA);
226− if (op == REQ_OP_DISCARD)
226+ if (op == REQ_OP_DISCARD || op == REQ_OP_SECURE_ERASE)
227227 what |= BLK_TC_ACT(BLK_TC_DISCARD);
228228 if (op == REQ_OP_FLUSH)
229229 what |= BLK_TC_ACT(BLK_TC_FLUSH);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t