[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20161224100756.GA16741@lst.de>
Date: Sat, 24 Dec 2016 11:07:56 +0100
From: Christoph Hellwig <hch@....de>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Christoph Hellwig <hch@....de>, Chris Leech <cleech@...hat.com>,
Ming Lei <tom.leiming@...il.com>,
Dave Chinner <david@...morbit.com>,
Johannes Weiner <hannes@...xchg.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Lee Duncan <lduncan@...e.com>, open-iscsi@...glegroups.com,
Linux SCSI List <linux-scsi@...r.kernel.org>,
linux-block <linux-block@...r.kernel.org>,
Jens Axboe <axboe@...com>,
"Michael S. Tsirkin" <mst@...hat.com>
Subject: Re: [4.10, panic, regression] iscsi: null pointer deref at
iscsi_tcp_segment_done+0x20d/0x2e0
On Fri, Dec 23, 2016 at 11:42:45AM -0800, Linus Torvalds wrote:
> Ugh. This patch is nasty.
It's the same SCSI has done for ages - except that is uses a separate
kmalloc for the sense buffer.
> I think we should just fix blk_execute_rq() instead.
As you found out below it's not just blk_execute_rq, it's the whole
architecture of the BLOCK_PC code, which expects a caller provided
sense buffer. But with the way blk-mq allocates request structures
we can actually fix it, but I first need to extent the way it allows
drivers to allocate private data to the old request code. I've
actually already implemented that for SCSI long time ago, and have
started to life it to the block layer.
Once that is done the callers won't need a sense buffer at all, and
can just look at the driver provided one. Which currently is missing
in virtio-blk, so we'd need something similar to the above patch
anyway.
Powered by blists - more mailing lists