aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wan/pci200syn.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wan/pci200syn.c')
-rw-r--r--drivers/net/wan/pci200syn.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wan/pci200syn.c b/drivers/net/wan/pci200syn.c
index 7f720de2e9f0..092e51d89036 100644
--- a/drivers/net/wan/pci200syn.c
+++ b/drivers/net/wan/pci200syn.c
@@ -312,14 +312,13 @@ static int __devinit pci200_pci_init_one(struct pci_dev *pdev,
312 return i; 312 return i;
313 } 313 }
314 314
315 card = kmalloc(sizeof(card_t), GFP_KERNEL); 315 card = kzalloc(sizeof(card_t), GFP_KERNEL);
316 if (card == NULL) { 316 if (card == NULL) {
317 printk(KERN_ERR "pci200syn: unable to allocate memory\n"); 317 printk(KERN_ERR "pci200syn: unable to allocate memory\n");
318 pci_release_regions(pdev); 318 pci_release_regions(pdev);
319 pci_disable_device(pdev); 319 pci_disable_device(pdev);
320 return -ENOBUFS; 320 return -ENOBUFS;
321 } 321 }
322 memset(card, 0, sizeof(card_t));
323 pci_set_drvdata(pdev, card); 322 pci_set_drvdata(pdev, card);
324 card->ports[0].dev = alloc_hdlcdev(&card->ports[0]); 323 card->ports[0].dev = alloc_hdlcdev(&card->ports[0]);
325 card->ports[1].dev = alloc_hdlcdev(&card->ports[1]); 324 card->ports[1].dev = alloc_hdlcdev(&card->ports[1]);