public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] libsas: use right function to alloc smp response
@ 2013-03-06  2:43 Jack Wang
  0 siblings, 0 replies; only message in thread
From: Jack Wang @ 2013-03-06  2:43 UTC (permalink / raw)
  To: 'James E.J. Bottomley'; +Cc: linux-scsi, 'lindar_liu', xjtuwjp

[-- Attachment #1: Type: text/plain, Size: 1015 bytes --]

In fact the disc_resp buffer will be overwrite by smp response, so we never
found this typo, correct it by using the right one.

>From 43c522be7a5b4ce89de725926a1fbabd70674c64 Mon Sep 17 00:00:00 2001
From: John Gong <john_gong@usish.com>
Date: Fri, 1 Mar 2013 04:08:18 -0500
Subject: [PATCH] use right function to alloc smp reponse

Signed-off-by: John Gong <john_gong@usish.com>
Signed-off-by: Jack Wang <jack_wang@usish.com>
---
 drivers/scsi/libsas/sas_expander.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/libsas/sas_expander.c
b/drivers/scsi/libsas/sas_expander.c
index efc6e72..e071e08 100644
--- a/drivers/scsi/libsas/sas_expander.c
+++ b/drivers/scsi/libsas/sas_expander.c
@@ -388,7 +388,7 @@ int sas_ex_phy_discover(struct domain_device *dev, int
single)
 	if (!disc_req)
 		return -ENOMEM;
 
-	disc_resp = alloc_smp_req(DISCOVER_RESP_SIZE);
+	disc_resp = alloc_smp_resp(DISCOVER_RESP_SIZE);
 	if (!disc_resp) {
 		kfree(disc_req);
 		return -ENOMEM;
-- 
1.7.1

[-- Attachment #2: 0001-use-right-function-to-alloc-smp-reponse.patch --]
[-- Type: application/octet-stream, Size: 914 bytes --]

>From 43c522be7a5b4ce89de725926a1fbabd70674c64 Mon Sep 17 00:00:00 2001
From: John Gong <john_gong@usish.com>
Date: Fri, 1 Mar 2013 04:08:18 -0500
Subject: [PATCH] use right function to alloc smp reponse

Signed-off-by: John Gong <john_gong@usish.com>
Signed-off-by: Jack Wang <jack_wang@usish.com>
---
 drivers/scsi/libsas/sas_expander.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/scsi/libsas/sas_expander.c b/drivers/scsi/libsas/sas_expander.c
index efc6e72..e071e08 100644
--- a/drivers/scsi/libsas/sas_expander.c
+++ b/drivers/scsi/libsas/sas_expander.c
@@ -388,7 +388,7 @@ int sas_ex_phy_discover(struct domain_device *dev, int single)
 	if (!disc_req)
 		return -ENOMEM;
 
-	disc_resp = alloc_smp_req(DISCOVER_RESP_SIZE);
+	disc_resp = alloc_smp_resp(DISCOVER_RESP_SIZE);
 	if (!disc_resp) {
 		kfree(disc_req);
 		return -ENOMEM;
-- 
1.7.1


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2013-03-06  2:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-06  2:43 [PATCH] libsas: use right function to alloc smp response Jack Wang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox