From: Hannes Reinecke <hare@suse.de>
To: Nic Bellinger <nab@daterainc.com>
Cc: target-devel@vger.kernel.org, linux-scsi@vger.kernel.org,
Hannes Reinecke <hare@suse.de>
Subject: [PATCH 1/5] tcm_loop: Check for valid hba in tcm_loop_drop_nexus()
Date: Wed, 16 Oct 2013 09:12:52 +0200 [thread overview]
Message-ID: <1381907576-81857-2-git-send-email-hare@suse.de> (raw)
In-Reply-To: <1381907576-81857-1-git-send-email-hare@suse.de>
Signed-off-by: Hannes Reinecke <hare@suse.de>
---
drivers/target/loopback/tcm_loop.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/target/loopback/tcm_loop.c b/drivers/target/loopback/tcm_loop.c
index 0f6d69d..57d5a95 100644
--- a/drivers/target/loopback/tcm_loop.c
+++ b/drivers/target/loopback/tcm_loop.c
@@ -932,7 +932,10 @@ static int tcm_loop_drop_nexus(
struct tcm_loop_nexus *tl_nexus;
struct tcm_loop_hba *tl_hba = tpg->tl_hba;
- tl_nexus = tpg->tl_hba->tl_nexus;
+ if (!tl_hba)
+ return -ENODEV;
+
+ tl_nexus = tl_hba->tl_nexus;
if (!tl_nexus)
return -ENODEV;
--
1.7.12.4
next prev parent reply other threads:[~2013-10-16 7:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-16 7:12 [PATCH 0/5] Updates for tcm_loop Hannes Reinecke
2013-10-16 7:12 ` Hannes Reinecke [this message]
2013-10-16 7:12 ` [PATCH 2/5] tcm_loop: Implement transport offline Hannes Reinecke
2013-10-16 7:12 ` [PATCH 3/5] tcm_loop: separate out tcm_loop_issue_tmr Hannes Reinecke
2013-10-16 7:12 ` [PATCH 4/5] tcm_loop: TCQ and command abort support Hannes Reinecke
2013-10-16 7:12 ` [PATCH 5/5] tcm_loop: Implement target reset Hannes Reinecke
2013-10-16 21:00 ` [PATCH 0/5] Updates for tcm_loop Nicholas A. Bellinger
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=1381907576-81857-2-git-send-email-hare@suse.de \
--to=hare@suse.de \
--cc=linux-scsi@vger.kernel.org \
--cc=nab@daterainc.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;
as well as URLs for NNTP newsgroup(s).