Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bfq-iosched: ensure to clear bic/bfqq pointers when preparing request
commit 72961c4 upstream. Even if we don't have an IO context attached to a request, we still need to clear the priv[0..1] pointers, as they could be pointing to previously used bic/bfqq structures. If we don't do so, we'll either corrupt memory on dispatching a request, or cause an imbalance in counters. Inspired by a fix from Kees. Reported-by: Oleksandr Natalenko <[email protected]> Reported-by: Kees Cook <[email protected]> Cc: [email protected] Fixes: aee69d7 ("block, bfq: introduce the BFQ-v0 I/O scheduler as an extra scheduler") Signed-off-by: Jens Axboe <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
- Loading branch information