Skip to content
Commit 8a15b4d7 authored by Stanley Chu's avatar Stanley Chu Committed by Jens Axboe
Browse files

block: bypass blk_set_runtime_active for uninitialized q->dev



Some devices may skip blk_pm_runtime_init() and have null pointer
in its request_queue->dev. For example, SCSI devices of UFS Well-Known
LUNs.

Currently the null pointer is checked by the user of
blk_set_runtime_active(), i.e., scsi_dev_type_resume(). It is better to
check it by blk_set_runtime_active() itself instead of by its users.

Signed-off-by: default avatarStanley Chu <stanley.chu@mediatek.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent f7c4ce89
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment