X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;ds=sidebyside;f=sound%2Foss%2Fsb_card.c;h=27acd6f29b98ffe06e4ffddd737e2d49218ce7c3;hb=ec4883b015c3212f6f6d04fb2ff45f528492f598;hp=8666291c00523fccca590df1d6a5fbedbf6c28c7;hpb=71bc7bf045262e82c645cad48fd56dd17e75344e;p=powerpc.git diff --git a/sound/oss/sb_card.c b/sound/oss/sb_card.c index 8666291c00..27acd6f29b 100644 --- a/sound/oss/sb_card.c +++ b/sound/oss/sb_card.c @@ -137,11 +137,10 @@ static int __init sb_init_legacy(void) { struct sb_module_options sbmo = {0}; - if((legacy = kmalloc(sizeof(struct sb_card_config), GFP_KERNEL)) == NULL) { + if((legacy = kzalloc(sizeof(struct sb_card_config), GFP_KERNEL)) == NULL) { printk(KERN_ERR "sb: Error: Could not allocate memory\n"); return -ENOMEM; } - memset(legacy, 0, sizeof(struct sb_card_config)); legacy->conf.io_base = io; legacy->conf.irq = irq; @@ -247,11 +246,10 @@ static int sb_pnp_probe(struct pnp_card_link *card, const struct pnp_card_device return -EBUSY; } - if((scc = kmalloc(sizeof(struct sb_card_config), GFP_KERNEL)) == NULL) { + if((scc = kzalloc(sizeof(struct sb_card_config), GFP_KERNEL)) == NULL) { printk(KERN_ERR "sb: Error: Could not allocate memory\n"); return -ENOMEM; } - memset(scc, 0, sizeof(struct sb_card_config)); printk(KERN_INFO "sb: PnP: Found Card Named = \"%s\", Card PnP id = " \ "%s, Device PnP id = %s\n", card->card->name, card_id->id,