aboutsummaryrefslogtreecommitdiff
path: root/drivers/ide/ide-tape.c
diff options
context:
space:
mode:
authorDeepak Saxena <dsaxena@plexity.net>2005-11-07 01:01:25 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 07:54:00 -0800
commitf5e3c2faa20615e900ab26bd957f898400435924 (patch)
treed3dd4c93539f155e3fd4ef18ae9cfe482ed1b340 /drivers/ide/ide-tape.c
parent9c2153844d72ac92b6da0ee42f7f81fb0aa91f8a (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.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c
index 47f2b832555..0ac7eb8f40d 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)
printk(KERN_WARNING "ide-tape: Use drive %s with ide-scsi emulation and osst.\n", drive->name);
printk(KERN_WARNING "ide-tape: OnStream support will be removed soon from ide-tape!\n");
}
- tape = (idetape_tape_t *) kmalloc (sizeof (idetape_tape_t), GFP_KERNEL);
+ tape = (idetape_tape_t *) kzalloc (sizeof (idetape_tape_t), GFP_KERNEL);
if (tape == NULL) {
printk(KERN_ERR "ide-tape: %s: Can't allocate a tape structure\n", drive->name);
goto failed;
@@ -4864,8 +4864,6 @@ static int ide_tape_probe(struct device *dev)
ide_register_subdriver(drive, &idetape_driver);
- memset(tape, 0, sizeof(*tape));
-
kref_init(&tape->kref);
tape->drive = drive;