blk-mq: add bounds check on tag-to-rq conversion
We need to check for a valid index before accessing the array element to avoid accessing invalid memory regions. Reviewed-by: NChristoph Hellwig <hch@lst.de> Reviewed-by: NJeff Moyer <jmoyer@redhat.com> Modified by Jens to drop the unlikely(), and make the fall through path be having a valid tag. Signed-off-by: NJens Axboe <axboe@fb.com>
Showing
想要评论请 注册 或 登录