diff options
author | Deepak Saxena <dsaxena@plexity.net> | 2005-11-07 04:01:25 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-11-07 10:54:00 -0500 |
commit | f5e3c2faa20615e900ab26bd957f898400435924 (patch) | |
tree | d3dd4c93539f155e3fd4ef18ae9cfe482ed1b340 /drivers/ide/ide-tape.c | |
parent | 9c2153844d72ac92b6da0ee42f7f81fb0aa91f8a (diff) |
[PATCH] ide: kmalloc + memset -> kzalloc conversion
Signed-off-by: Deepak Saxena <dsaxena@plexity.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/ide/ide-tape.c')
-rw-r--r-- | drivers/ide/ide-tape.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c index 47f2b832555f..0ac7eb8f40d5 100644 --- a/drivers/ide/ide-tape.c +++ b/drivers/ide/ide-tape.c | |||
@@ -4850,7 +4850,7 @@ static int ide_tape_probe(struct device *dev) | |||
4850 | printk(KERN_WARNING "ide-tape: Use drive %s with ide-scsi emulation and osst.\n", drive->name); | 4850 | printk(KERN_WARNING "ide-tape: Use drive %s with ide-scsi emulation and osst.\n", drive->name); |
4851 | printk(KERN_WARNING "ide-tape: OnStream support will be removed soon from ide-tape!\n"); | 4851 | printk(KERN_WARNING "ide-tape: OnStream support will be removed soon from ide-tape!\n"); |
4852 | } | 4852 | } |
4853 | tape = (idetape_tape_t *) kmalloc (sizeof (idetape_tape_t), GFP_KERNEL); | 4853 | tape = (idetape_tape_t *) kzalloc (sizeof (idetape_tape_t), GFP_KERNEL); |
4854 | if (tape == NULL) { | 4854 | if (tape == NULL) { |
4855 | printk(KERN_ERR "ide-tape: %s: Can't allocate a tape structure\n", drive->name); | 4855 | printk(KERN_ERR "ide-tape: %s: Can't allocate a tape structure\n", drive->name); |
4856 | goto failed; | 4856 | goto failed; |
@@ -4864,8 +4864,6 @@ static int ide_tape_probe(struct device *dev) | |||
4864 | 4864 | ||
4865 | ide_register_subdriver(drive, &idetape_driver); | 4865 | ide_register_subdriver(drive, &idetape_driver); |
4866 | 4866 | ||
4867 | memset(tape, 0, sizeof(*tape)); | ||
4868 | |||
4869 | kref_init(&tape->kref); | 4867 | kref_init(&tape->kref); |
4870 | 4868 | ||
4871 | tape->drive = drive; | 4869 | tape->drive = drive; |