From: Christoph Hellwig <hch@lst.de>
To: Spencer Baugh <sbaugh@catern.com>
Cc: "Nicholas A. Bellinger" <nab@linux-iscsi.org>,
Sagi Grimberg <sagig@mellanox.com>,
Christoph Hellwig <hch@lst.de>,
Bart Van Assche <bart.vanassche@sandisk.com>,
Alexei Potashnik <alexei@purestorage.com>,
Andy Grover <agrover@redhat.com>,
Christophe Vu-Brugier <cvubrugier@fastmail.fm>,
Roland Dreier <roland@purestorage.com>,
"open list:TARGET SUBSYSTEM" <linux-scsi@vger.kernel.org>,
"open list:TARGET SUBSYSTEM" <target-devel@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>,
Joern Engel <joern@purestorage.com>,
Spencer Baugh <Spencer.baugh@purestorage.com>
Subject: Re: [PATCH] target: fix crash in cmd tracing when cmd didn't match a LUN
Date: Fri, 24 Jul 2015 12:52:06 +0200 [thread overview]
Message-ID: <20150724105206.GA25162@lst.de> (raw)
In-Reply-To: <1437689973-22991-1-git-send-email-sbaugh@catern.com>
On Thu, Jul 23, 2015 at 03:19:32PM -0700, Spencer Baugh wrote:
> From: Alexei Potashnik <alexei@purestorage.com>
>
> If command didn't match a LUN and we're sending check condition, the
> target_cmd_complete ftrace point will crash because it assumes that
> cmd->t_task_cdb has been set.
>
> The fix will temporarily set t_task_cdb to the se_cmd buffer
> and copy first 6 bytes of cdb in there as soon as possible.
> At a later point t_task_cdb is reset to the correct buffer,
> but until then traces and printks don't cause a crash.
This is too ugly to live. Just dropping the t_task_cdb dereference
from the trace point sounds like the simples quick fix for now,
and removing the crazy layering violation in iSCSI that opencode
target_submit_cmd is the proper long term fix.
next prev parent reply other threads:[~2015-07-24 10:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-23 22:19 [PATCH] target: fix crash in cmd tracing when cmd didn't match a LUN Spencer Baugh
2015-07-24 10:52 ` Christoph Hellwig [this message]
2015-07-24 20:32 ` Nicholas A. Bellinger
2015-07-25 6:48 ` Christoph Hellwig
2015-07-25 9:28 ` Nicholas A. Bellinger
-- strict thread matches above, loose matches on Subject: below --
2015-07-21 22:07 Spencer Baugh
2015-07-21 22:13 ` Spencer Baugh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150724105206.GA25162@lst.de \
--to=hch@lst.de \
--cc=Spencer.baugh@purestorage.com \
--cc=agrover@redhat.com \
--cc=alexei@purestorage.com \
--cc=bart.vanassche@sandisk.com \
--cc=cvubrugier@fastmail.fm \
--cc=joern@purestorage.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=nab@linux-iscsi.org \
--cc=roland@purestorage.com \
--cc=sagig@mellanox.com \
--cc=sbaugh@catern.com \
--cc=target-devel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox