X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=sound%2Foss%2Fkahlua.c;h=eb9bc365530dde4107f1cf4f9de102bd66dac59b;hb=3b23e665b68387f5ee7b21f7b75ceea4d9acae4a;hp=12e7b3038be2bb8a05dcb2c27045d4023c340464;hpb=b197ba3c70638a3a2ae39296781912f26ac0f991;p=linux-2.6 diff --git a/sound/oss/kahlua.c b/sound/oss/kahlua.c index 12e7b3038b..eb9bc36553 100644 --- a/sound/oss/kahlua.c +++ b/sound/oss/kahlua.c @@ -67,7 +67,7 @@ static int __devinit probe_one(struct pci_dev *pdev, const struct pci_device_id return 1; mem = ioremap(base, 128); - if(mem == 0UL) + if (!mem) return 1; map = readw(mem + 0x18); /* Read the SMI enables */ iounmap(mem); @@ -139,13 +139,12 @@ static int __devinit probe_one(struct pci_dev *pdev, const struct pci_device_id printk(KERN_INFO "kahlua: XpressAudio on IRQ %d, DMA %d, %d\n", irq, dma8, dma16); - hw_config = kmalloc(sizeof(struct address_info), GFP_KERNEL); + hw_config = kzalloc(sizeof(struct address_info), GFP_KERNEL); if(hw_config == NULL) { printk(KERN_ERR "kahlua: out of memory.\n"); return 1; } - memset(hw_config, 0, sizeof(*hw_config)); pci_set_drvdata(pdev, hw_config);