Archived
14
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/drivers/scsi
Yoann Padioleau dd00cc486a some kmalloc/memset ->kzalloc (tree wide)
Transform some calls to kmalloc/memset to a single kzalloc (or kcalloc).

Here is a short excerpt of the semantic patch performing
this transformation:

@@
type T2;
expression x;
identifier f,fld;
expression E;
expression E1,E2;
expression e1,e2,e3,y;
statement S;
@@

 x =
- kmalloc
+ kzalloc
  (E1,E2)
  ...  when != \(x->fld=E;\|y=f(...,x,...);\|f(...,x,...);\|x=E;\|while(...) S\|for(e1;e2;e3) S\)
- memset((T2)x,0,E1);

@@
expression E1,E2,E3;
@@

- kzalloc(E1 * E2,E3)
+ kcalloc(E1,E2,E3)

[akpm@linux-foundation.org: get kcalloc args the right way around]
Signed-off-by: Yoann Padioleau <padator@wanadoo.fr>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Acked-by: Russell King <rmk@arm.linux.org.uk>
Cc: Bryan Wu <bryan.wu@analog.com>
Acked-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Dave Airlie <airlied@linux.ie>
Acked-by: Roland Dreier <rolandd@cisco.com>
Cc: Jiri Kosina <jkosina@suse.cz>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Acked-by: Pierre Ossman <drzeus-list@drzeus.cx>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: "David S. Miller" <davem@davemloft.net>
Acked-by: Greg KH <greg@kroah.com>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-19 10:04:50 -07:00
..
aacraid Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
aic7xxx Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
aic7xxx_old
aic94xx PCI: Change all drivers to use pci_device->revision 2007-07-11 16:02:10 -07:00
arcmsr Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
arm [ARM] ecard: add ecardm_iomap() / ecardm_iounmap() 2007-05-11 17:19:02 +01:00
dpt [SCSI] dpt: whitespace cleanup 2007-04-01 10:10:04 -05:00
ibmvscsi [SCSI] ibmvscsi: convert to use the data buffer accessors 2007-07-15 10:05:33 -05:00
libsas Freezer: make kernel threads nonfreezable by default 2007-07-17 10:23:02 -07:00
lpfc some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
megaraid some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
pcmcia some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
qla2xxx Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
qla4xxx [SCSI] qla4xxx: Fix underrun/overrun conditions 2007-07-14 19:11:38 -05:00
sym53c8xx_2 [SCSI] sym53c8xx: convert to use the data buffer accessors 2007-07-15 10:00:32 -05:00
.gitignore
3w-9xxx.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
3w-9xxx.h
3w-xxxx.c [SCSI] 3w-xxxx: convert to use the data buffer accessors 2007-05-30 23:29:32 -05:00
3w-xxxx.h
53c700.c [SCSI] 53c700: Remove printk, which triggers because of low scsi clock on SNI RMs 2007-07-14 19:12:43 -05:00
53c700.h [SCSI] 53c700: m68k support for the 53c700 SCSI core 2007-06-17 16:15:56 -05:00
53c700.scr
53c700_d.h_shipped
a100u2w.c [SCSI] a100u2w: Convert into Linux style 2007-06-17 16:09:29 -05:00
a100u2w.h [SCSI] a100u2w: Convert into Linux style 2007-06-17 16:09:29 -05:00
a2091.c
a2091.h
a3000.c
a3000.h
a4000t.c [SCSI] 53c700: Fixup m68k drivers: 2007-06-19 19:53:35 -07:00
advansys.c [SCSI] advansys: cleanups 2007-05-27 15:05:10 -05:00
aha152x.c [SCSI] aha152x: use wait_for_completion_timeout 2007-05-22 10:50:19 -05:00
aha152x.h
aha1542.c PCI: Cleanup the includes of <linux/pci.h> 2007-05-02 19:02:35 -07:00
aha1542.h
aha1740.c [SCSI] aha1740: convert to use the data buffer accessors 2007-05-26 19:12:56 -05:00
aha1740.h
aic7xxx_old.c [SCSI] aic7xxx_old: remove redundant GFP_ATOMIC from kmalloc 2007-07-15 09:34:45 -05:00
atari_dma_emul.c
atari_NCR5380.c [SCSI] atari_NCR5380: update_timeout removal 2007-06-04 09:55:15 -05:00
atari_scsi.c m68k: Atari SCSI driver compile fixes 2007-05-04 17:59:05 -07:00
atari_scsi.h m68k: Atari SCSI driver compile fixes 2007-05-04 17:59:05 -07:00
atp870u.c
atp870u.h
blz1230.c
blz2060.c
BusLogic.c [SCSI] BusLogic: convert to use the data buffer accessors 2007-05-26 19:21:37 -05:00
BusLogic.h
bvme6000_scsi.c [SCSI] 53c700: Fixup m68k drivers: 2007-06-19 19:53:35 -07:00
ch.c [SCSI] ch: kmalloc/memset->kzalloc 2007-05-06 09:33:11 -05:00
constants.c [SCSI] constants.c: Update ASC list and make it const 2007-03-11 11:21:25 -05:00
cyberstorm.c
cyberstormII.c
dc395x.c [SCSI] dc395x: convert to use the data buffer accessors 2007-07-15 10:04:49 -05:00
dc395x.h
dec_esp.c
dmx3191d.c
dpt_i2o.c [SCSI] dpt_i2o: convert to use the data buffer accessors 2007-05-31 12:25:27 -05:00
dpti.h
dtc.c
dtc.h
eata.c [SCSI] eata: convert to use the data buffer accessors 2007-05-26 19:13:55 -05:00
eata_generic.h [SCSI] eata_pio: Remove FALSE/TRUE defines 2007-03-20 11:27:03 -05:00
eata_pio.c
eata_pio.h
esp_scsi.c Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
esp_scsi.h [SCSI] esp: use shost_priv 2007-05-31 17:30:04 -04:00
fastlane.c
fcal.c
fcal.h
fd_mcs.c
fdomain.c [SCSI] fdomain: fix PCMCIA-related warnings 2007-05-27 12:59:28 -05:00
fdomain.h
FlashPoint.c
g_NCR5380.c
g_NCR5380.h
g_NCR5380_mmio.c
gdth.c [SCSI] gdth: Fix obvious typo "spin_lock_irqrestore()" 2007-05-30 08:39:52 -05:00
gdth.h
gdth_ioctl.h
gdth_kcompat.h
gdth_proc.c
gdth_proc.h
gvp11.c
gvp11.h
hosts.c SCSI: use the proper semaphore to protect the class lists 2007-04-27 10:57:30 -07:00
hptiop.c [SCSI] hptiop: convert to use the data buffer accessors 2007-06-17 18:35:14 -05:00
hptiop.h
ibmmca.c [SCSI] ibmmca: convert to use the data buffer accessors 2007-05-26 16:30:17 -05:00
ide-scsi.c ide-scsi: fix OOPS in idescsi_expiry() 2007-06-16 02:24:44 +02:00
imm.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
imm.h
in2000.c
in2000.h
initio.c [SCSI] initio: convert to use the data buffer accessors 2007-05-26 19:13:27 -05:00
initio.h [SCSI] initio: Convert into a real Linux driver and update to modern style 2007-05-22 11:08:56 -05:00
ipr.c Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
ipr.h [SCSI] ipr: Use PCI-E reset API for new ipr adapter 2007-05-08 11:54:40 -05:00
ips.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
ips.h [SCSI] ips: remove kernel 2.4 code 2007-05-24 09:14:41 -05:00
iscsi_tcp.c [SCSI] iscsi_tcp: convert to use the data buffer accessors 2007-06-17 16:01:55 -05:00
iscsi_tcp.h [SCSI] iscsi_tcp: fix handling of data buffer padding 2007-06-02 15:35:10 -04:00
jazz_esp.c [SCSI] esp: use shost_priv 2007-05-31 17:30:04 -04:00
Kconfig Introduce CONFIG_VIRT_TO_BUS 2007-07-16 09:05:42 -07:00
lasi700.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
libiscsi.c [SCSI] iscsi_tcp: convert to use the data buffer accessors 2007-06-17 16:01:55 -05:00
libsrp.c [SCSI] tgt: fix a rdma indirect transfer error bug 2007-05-16 12:45:17 -04:00
mac53c94.c [SCSI] mac53c94: convert to use the data buffer accessors 2007-05-26 19:07:50 -05:00
mac53c94.h
mac_esp.c
mac_scsi.c
mac_scsi.h
Makefile [SCSI] don't build scsi_dma_{map,unmap} for !HAS_DMA 2007-07-14 19:28:10 -05:00
mca_53c9x.c
megaraid.c [SCSI] megaraid_old: convert to use the data buffer accessors 2007-05-31 18:11:21 -04:00
megaraid.h [SCSI] megaraid: fix warnings when CONFIG_PROC_FS=n 2007-05-08 11:15:08 -05:00
mesh.c [SCSI] mesh: convert to use the data buffer accessors 2007-06-07 08:49:10 -05:00
mesh.h
mvme16x_scsi.c [SCSI] 53c700: m68k MVME16x NCR53C710 SCSI 2007-06-17 16:17:40 -05:00
mvme147.c
mvme147.h
ncr53c8xx.c [SCSI] ncr53c8xx: convert to use the data buffer accessors 2007-07-15 10:03:03 -05:00
ncr53c8xx.h
NCR53C9x.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
NCR53C9x.h
NCR53c406a.c [SCSI] NCR53c406a: convert to use the data buffer accessors 2007-05-26 19:08:20 -05:00
NCR5380.c Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
NCR5380.h [SCSI] ncr5380 warning fixes 2007-05-24 09:13:25 -05:00
NCR_D700.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
NCR_D700.h
NCR_Q720.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
NCR_Q720.h
nsp32.c Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
nsp32.h
nsp32_debug.c
nsp32_io.h
oktagon_esp.c
oktagon_io.S
osst.c [SCSI] modalias for scsi devices 2007-04-17 18:15:04 -04:00
osst.h
osst_detect.h
osst_options.h
pas16.c
pas16.h
pluto.c [SCSI] pluto: Use wait_for_completion_timeout. 2007-05-29 02:49:05 -07:00
pluto.h
ppa.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
ppa.h
psi240i.c
psi240i.h
psi_chip.h
ql1040_fw.h
ql1280_fw.h
ql12160_fw.h
qla1280.c [SCSI] qla1280: use DMA_64BIT_MASK instead of ~ 0ULL 2007-05-06 09:33:11 -05:00
qla1280.h
qlogicfas.c
qlogicfas408.c [SCSI] qlogicfas408: convert to use the data buffer accessors 2007-05-26 19:21:09 -05:00
qlogicfas408.h
qlogicpti.c [SPARC/64] constify of_get_property return: drivers 2007-04-26 01:54:27 -07:00
qlogicpti.h
qlogicpti_asm.c
raid_class.c
script_asm.pl
scsi.c [SCSI] scsi.c: convert to use the data buffer accessors 2007-07-14 18:57:54 -05:00
scsi.h
scsi_debug.c [SCSI] scsi_debug: correct parameter default text 2007-06-17 14:56:07 -05:00
scsi_debug.h
scsi_devinfo.c [SCSI] Add Brownie 1200U3P to blacklist 2007-07-14 18:58:37 -05:00
scsi_error.c Freezer: make kernel threads nonfreezable by default 2007-07-17 10:23:02 -07:00
scsi_ioctl.c
scsi_lib.c [SCSI] don't build scsi_dma_{map,unmap} for !HAS_DMA 2007-07-14 19:28:10 -05:00
scsi_lib_dma.c [SCSI] don't build scsi_dma_{map,unmap} for !HAS_DMA 2007-07-14 19:28:10 -05:00
scsi_logging.h
scsi_module.c
scsi_netlink.c [NETLINK]: Switch cb_lock spinlock to mutex and allow to override it 2007-04-25 22:29:03 -07:00
scsi_priv.h
scsi_proc.c
scsi_sas_internal.h
scsi_scan.c Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6 2007-07-15 16:51:54 -07:00
scsi_sysctl.c
scsi_sysfs.c [SCSI] kill scsi host template suspend/resume 2007-05-22 10:41:12 -05:00
scsi_tgt_if.c [SCSI] tgt: fix sesnse buffer problems 2007-03-11 11:39:27 -05:00
scsi_tgt_lib.c [SCSI] tgt: remove the code to build sense 2007-03-20 10:52:59 -05:00
scsi_tgt_priv.h [SCSI] tgt: fix sesnse buffer problems 2007-03-11 11:39:27 -05:00
scsi_transport_api.h
scsi_transport_fc.c [SCSI] fc_transport: Check portstates before invoking target scan 2007-06-17 16:03:11 -05:00
scsi_transport_iscsi.c [SCSI] iscsi class, iscsi_tcp, iser, qla4xxx: add netdevname sysfs attr 2007-06-02 15:38:04 -04:00
scsi_transport_sas.c
scsi_transport_spi.c
scsi_typedefs.h
scsi_wait_scan.c
scsicam.c
sd.c bsg: add a request_queue argument to scsi_cmd_ioctl() 2007-07-16 08:52:45 +02:00
seagate.c
sg.c [SCSI] sg: remove unnecessary check 2007-05-28 09:08:32 -05:00
sgiwd93.c Convert SGI IP22 and specific drivers to platform_device. 2007-05-11 17:00:29 +01:00
sim710.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
sni_53c710.c [SCSI] sni_53c710: Cleanup 2007-07-14 19:12:15 -05:00
sr.c [SCSI] sr: fix error handling in module_init 2007-07-14 18:54:34 -05:00
sr.h
sr_ioctl.c
sr_vendor.c
st.c bsg: add a request_queue argument to scsi_cmd_ioctl() 2007-07-16 08:52:45 +02:00
st.h
st_options.h
stex.c [SCSI] stex: use resid for xfer len information 2007-07-14 18:59:10 -05:00
sun3_NCR5380.c
sun3_scsi.c
sun3_scsi.h
sun3_scsi_vme.c
sun3x_esp.c
sun_esp.c [SCSI] esp: use shost_priv 2007-05-31 17:30:04 -04:00
sym53c416.c [SCSI] sym53c416: convert to use the data buffer accessors 2007-05-26 19:08:50 -05:00
sym53c416.h
t128.c
t128.h
tmscsim.c some kmalloc/memset ->kzalloc (tree wide) 2007-07-19 10:04:50 -07:00
tmscsim.h [SCSI] tmscsim: Further clean-up of the driver 2007-07-14 18:56:33 -05:00
u14-34f.c [SCSI] u14-34f: convert to use the data buffer accessors 2007-05-26 19:19:04 -05:00
ultrastor.c [SCSI] ultrastor: convert to use the data buffer accessors 2007-05-26 19:18:38 -05:00
ultrastor.h
wd33c93.c
wd33c93.h
wd7000.c [SCSI] wd7000: convert to use the data buffer accessors 2007-05-26 19:18:10 -05:00
zalon.c
zorro7xx.c [SCSI] 53c700: Fixup m68k drivers: 2007-06-19 19:53:35 -07:00