lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <DCD177647606E9419ED923E0C8C4AA7223E75BB255@inbmail02.lsi.com>
Date:	Tue, 11 Dec 2012 14:32:32 +0530
From:	"Reddy, Sreekanth" <Sreekanth.Reddy@....com>
To:	Dan Carpenter <dan.carpenter@...cle.com>,
	"Nandigama, Nagalakshmi" <Nagalakshmi.Nandigama@....com>
CC:	Support <support@....com>,
	"James E.J. Bottomley" <JBottomley@...allels.com>,
	DL-MPT Fusion Linux <DL-MPTFusionLinux@....com>,
	"linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"kernel-janitors@...r.kernel.org" <kernel-janitors@...r.kernel.org>
Subject: RE: [patch] [SCSI] mpt3sas: cut and paste bug storing trigger mpi

James,

This patch seem to be fine. Please consider this patch as Acked-by: "Sreekanth Reddy" <Sreekanth.reddy@....com>

Regards,
Sreekanth.

-----Original Message-----
From: Dan Carpenter [mailto:dan.carpenter@...cle.com] 
Sent: Friday, December 07, 2012 11:58 AM
To: Nandigama, Nagalakshmi
Cc: Reddy, Sreekanth; Support; James E.J. Bottomley; DL-MPT Fusion Linux; linux-scsi@...r.kernel.org; linux-kernel@...r.kernel.org; kernel-janitors@...r.kernel.org
Subject: [patch] [SCSI] mpt3sas: cut and paste bug storing trigger mpi

ioc->diag_trigger_mpi is an SL_WH_MPI_TRIGGERS_T struct.

There is a cut and paste error here and SL_WH_EVENT_TRIGGERS_T is used instead of SL_WH_MPI_TRIGGERS_T.  Since the SL_WH_EVENT_TRIGGERS_T is smaller than SL_WH_MPI_TRIGGERS_T, it means we only clear part of the buffer.

Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
---
Only needed in linux-next.

This is a static analysis patch.  Even though I'm pretty sure it's correct, I'm not able to test it.

diff --git a/drivers/scsi/mpt3sas/mpt3sas_ctl.c b/drivers/scsi/mpt3sas/mpt3sas_ctl.c
index 8af944d..3e35e64 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_ctl.c
+++ b/drivers/scsi/mpt3sas/mpt3sas_ctl.c
@@ -3136,7 +3136,7 @@ _ctl_diag_trigger_mpi_store(struct device *cdev,
 	spin_lock_irqsave(&ioc->diag_trigger_lock, flags);
 	sz = min(sizeof(struct SL_WH_MPI_TRIGGERS_T), count);
 	memset(&ioc->diag_trigger_mpi, 0,
-	    sizeof(struct SL_WH_EVENT_TRIGGERS_T));
+	    sizeof(struct SL_WH_MPI_TRIGGERS_T));
 	memcpy(&ioc->diag_trigger_mpi, buf, sz);
 	if (ioc->diag_trigger_mpi.ValidEntries > NUM_VALID_ENTRIES)
 		ioc->diag_trigger_mpi.ValidEntries = NUM_VALID_ENTRIES;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ