linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch] hpsa: set the enclosure identifier to zero
@ 2016-04-14  9:37 Dan Carpenter
  2016-04-26  2:02 ` Martin K. Petersen
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2016-04-14  9:37 UTC (permalink / raw)
  To: Don Brace
  Cc: James E.J. Bottomley, Martin K. Petersen, iss_storagedev,
	esc.storagedev, linux-scsi, linux-kernel, kernel-janitors

This has only called from show_sas_rphy_enclosure_identifier().  The
caller expects that we set an identifier, otherwise it uses an
unintialized variable.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 5be944c..25aa219 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/scsi/hpsa.c
@@ -9602,6 +9602,7 @@ hpsa_sas_get_linkerrors(struct sas_phy *phy)
 static int
 hpsa_sas_get_enclosure_identifier(struct sas_rphy *rphy, u64 *identifier)
 {
+	*identifier = 0;
 	return 0;
 }
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [patch] hpsa: set the enclosure identifier to zero
  2016-04-14  9:37 [patch] hpsa: set the enclosure identifier to zero Dan Carpenter
@ 2016-04-26  2:02 ` Martin K. Petersen
  0 siblings, 0 replies; 2+ messages in thread
From: Martin K. Petersen @ 2016-04-26  2:02 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: Don Brace, James E.J. Bottomley, Martin K. Petersen,
	iss_storagedev, esc.storagedev, linux-scsi, linux-kernel,
	kernel-janitors

>>>>> "Dan" == Dan Carpenter <dan.carpenter@oracle.com> writes:

Dan> This has only called from show_sas_rphy_enclosure_identifier().
Dan> The caller expects that we set an identifier, otherwise it uses an
Dan> unintialized variable.

Applied to 4.7/scsi-queue.

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-04-26  2:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-14  9:37 [patch] hpsa: set the enclosure identifier to zero Dan Carpenter
2016-04-26  2:02 ` Martin K. Petersen

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).