Re: [PATCH] [v2] nvme-pci: check req to prevent crash in nvme_handle_cqe()

2020-09-01 Thread Keith Busch
On Mon, Aug 31, 2020 at 06:55:53PM +0800, Xianting Tian wrote: > As blk_mq_tag_to_rq() may return null, so it should be check whether it is > null before using it to prevent a crash. It may return NULL if the command id exceeds the number of tags. We already have a check for a valid command id

RE: [PATCH] [v2] nvme-pci: check req to prevent crash in nvme_handle_cqe()

2020-09-01 Thread Tianxianting
...@grimberg.me Cc: linux-n...@lists.infradead.org; linux-kernel@vger.kernel.org; tianxianting (RD) Subject: [PATCH] [v2] nvme-pci: check req to prevent crash in nvme_handle_cqe() We met a crash issue when hot-insert a nvme device, blk_mq_tag_to_rq() returned null(req=null), then crash happened

[PATCH] [v2] nvme-pci: check req to prevent crash in nvme_handle_cqe()

2020-08-31 Thread Xianting Tian
We met a crash issue when hot-insert a nvme device, blk_mq_tag_to_rq() returned null(req=null), then crash happened in nvme_end_request(): struct nvme_request *rq = nvme_req(req); rq->result = result; <==crash here The test env is, a server is configured with 2 backplanes, each