mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-05 05:42:36 +00:00
null_blk: fix softirq completions for queue_mode == 1
Only blk-mq completions have payload attached to the request, for request_fn mode we have stored it in req->special. This fixes an oops with queue_mode=1 and softirq completions. Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
parent
95ed068165
commit
d891fa7087
1 changed files with 4 additions and 1 deletions
|
@ -227,7 +227,10 @@ static void null_cmd_end_timer(struct nullb_cmd *cmd)
|
||||||
|
|
||||||
static void null_softirq_done_fn(struct request *rq)
|
static void null_softirq_done_fn(struct request *rq)
|
||||||
{
|
{
|
||||||
end_cmd(blk_mq_rq_to_pdu(rq));
|
if (queue_mode == NULL_Q_MQ)
|
||||||
|
end_cmd(blk_mq_rq_to_pdu(rq));
|
||||||
|
else
|
||||||
|
end_cmd(rq->special);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void null_handle_cmd(struct nullb_cmd *cmd)
|
static inline void null_handle_cmd(struct nullb_cmd *cmd)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue