3W RAID drivers: memset not needed in probe
PATCH 3/7 3W RAID drivers: memset not needed in probe
From: Denis Cheng <[email protected]>
The memory return from scsi_host_alloc is alloced by kzalloc, which is already zero initilized, so memset not needed.
Signed-off-by Denis Cheng <[email protected]>
Cc Adam Radford <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
drivers/scsi/3w-9xxx.c | 2 -- drivers/scsi/3w-xxxx.c | 2 -- 2 files changed, 4 deletions(-)
drivers/scsi/3w-9xxx.c renamed from drivers/scsi/3w-9xxx.c~3w-raid-drivers-memset-not-needed-in-probe +0 -2
@@ -2028,8 +2028,6 @@ static int __devinit twa_probe(struct pc } tw_dev = (TW_Device_Extension *)host->hostdata; -memset (tw_dev,0 ,sizeof (TW_Device_Extension)); -/* Save values to device extension */ tw_dev->host = host; tw_dev->tw_pci_dev = pdev;
drivers/scsi/3w-xxxx.c renamed from drivers/scsi/3w-xxxx.c~3w-raid-drivers-memset-not-needed-in-probe +0 -2
@@ -2294,8 +2294,6 @@ static int __devinit tw_probe(struct pci } tw_dev = (TW_Device_Extension *)host->hostdata; -memset (tw_dev,0 ,sizeof (TW_Device_Extension)); -/* Save values to device extension */ tw_dev->host = host; tw_dev->tw_pci_dev = pdev;
_
adam radford
maintainerQuoted 9 lines · On Tue, Mar 4, 2008 at 3:24 PM, <[email protected]> wrote:
From: Denis Cheng <[email protected]>
The memory return from
scsi_host_allocis alloced by kzalloc, which is already zero initilized, so memset not needed.Signed-off-by Denis Cheng <[email protected]>Cc Adam Radford <[email protected]>Signed-off-by Andrew Morton <[email protected]>---
ACK.... James can you please apply this.
-Adam