* [PATCH] drivers/scsi/mpt2sas/mpt2sas_transport.c: add missing sas_phy_free
@ 2011-08-10 11:32 Julia Lawall
2011-08-30 10:42 ` Nandigama, Nagalakshmi
0 siblings, 1 reply; 2+ messages in thread
From: Julia Lawall @ 2011-08-10 11:32 UTC (permalink / raw)
To: James E.J. Bottomley
Cc: kernel-janitors, Kashyap Desai, James Bottomley, linux-scsi,
linux-kernel
From: Julia Lawall <julia@diku.dk>
In each case, sas_phy_add has not yet been successfully applied, so use
sas_phy_free to free phy.
Signed-off-by: Julia Lawall <julia@diku.dk>
---
drivers/scsi/mpt2sas/mpt2sas_transport.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/scsi/mpt2sas/mpt2sas_transport.c b/drivers/scsi/mpt2sas/mpt2sas_transport.c
index 15c7980..762f05e 100644
--- a/drivers/scsi/mpt2sas/mpt2sas_transport.c
+++ b/drivers/scsi/mpt2sas/mpt2sas_transport.c
@@ -857,6 +857,7 @@ mpt2sas_transport_add_host_phy(struct MPT2SAS_ADAPTER *ioc, struct _sas_phy
&mpt2sas_phy->identify))) {
printk(MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n",
ioc->name, __FILE__, __LINE__, __func__);
+ sas_phy_free(phy);
return -1;
}
phy->identify = mpt2sas_phy->identify;
@@ -923,6 +924,7 @@ mpt2sas_transport_add_expander_phy(struct MPT2SAS_ADAPTER *ioc, struct _sas_phy
&mpt2sas_phy->identify))) {
printk(MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n",
ioc->name, __FILE__, __LINE__, __func__);
+ sas_phy_free(phy);
return -1;
}
phy->identify = mpt2sas_phy->identify;
^ permalink raw reply [flat|nested] 2+ messages in thread* RE: [PATCH] drivers/scsi/mpt2sas/mpt2sas_transport.c: add missing sas_phy_free
2011-08-10 11:32 [PATCH] drivers/scsi/mpt2sas/mpt2sas_transport.c: add missing sas_phy_free Julia Lawall
@ 2011-08-30 10:42 ` Nandigama, Nagalakshmi
0 siblings, 0 replies; 2+ messages in thread
From: Nandigama, Nagalakshmi @ 2011-08-30 10:42 UTC (permalink / raw)
To: Julia Lawall, James E.J. Bottomley
Cc: kernel-janitors, Desai, Kashyap, James Bottomley, linux-scsi,
linux-kernel
The patch seem to be fine. Please consider this patch as Acked-by: "Nandigama, Nagalakshmi" <Nagalakshmi.Nandigama@lsi.com>
Regards,
Nagalakshmi
-----Original Message-----
From: Julia Lawall [mailto:julia@diku.dk]
Sent: Wednesday, August 10, 2011 5:02 PM
To: James E.J. Bottomley
Cc: kernel-janitors@vger.kernel.org; Desai, Kashyap; James Bottomley; linux-scsi@vger.kernel.org; linux-kernel@vger.kernel.org
Subject: [PATCH] drivers/scsi/mpt2sas/mpt2sas_transport.c: add missing sas_phy_free
From: Julia Lawall <julia@diku.dk>
In each case, sas_phy_add has not yet been successfully applied, so use
sas_phy_free to free phy.
Signed-off-by: Julia Lawall <julia@diku.dk>
---
drivers/scsi/mpt2sas/mpt2sas_transport.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/scsi/mpt2sas/mpt2sas_transport.c b/drivers/scsi/mpt2sas/mpt2sas_transport.c
index 15c7980..762f05e 100644
--- a/drivers/scsi/mpt2sas/mpt2sas_transport.c
+++ b/drivers/scsi/mpt2sas/mpt2sas_transport.c
@@ -857,6 +857,7 @@ mpt2sas_transport_add_host_phy(struct MPT2SAS_ADAPTER *ioc, struct _sas_phy
&mpt2sas_phy->identify))) {
printk(MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n",
ioc->name, __FILE__, __LINE__, __func__);
+ sas_phy_free(phy);
return -1;
}
phy->identify = mpt2sas_phy->identify;
@@ -923,6 +924,7 @@ mpt2sas_transport_add_expander_phy(struct MPT2SAS_ADAPTER *ioc, struct _sas_phy
&mpt2sas_phy->identify))) {
printk(MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n",
ioc->name, __FILE__, __LINE__, __func__);
+ sas_phy_free(phy);
return -1;
}
phy->identify = mpt2sas_phy->identify;
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-08-30 10:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-10 11:32 [PATCH] drivers/scsi/mpt2sas/mpt2sas_transport.c: add missing sas_phy_free Julia Lawall
2011-08-30 10:42 ` Nandigama, Nagalakshmi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®