diff options
Diffstat (limited to 'drivers/net/wan/pc300too.c')
-rw-r--r-- | drivers/net/wan/pc300too.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wan/pc300too.c b/drivers/net/wan/pc300too.c index dfbd3b00f03b..6353cb5c658d 100644 --- a/drivers/net/wan/pc300too.c +++ b/drivers/net/wan/pc300too.c | |||
@@ -334,14 +334,13 @@ static int __devinit pc300_pci_init_one(struct pci_dev *pdev, | |||
334 | return i; | 334 | return i; |
335 | } | 335 | } |
336 | 336 | ||
337 | card = kmalloc(sizeof(card_t), GFP_KERNEL); | 337 | card = kzalloc(sizeof(card_t), GFP_KERNEL); |
338 | if (card == NULL) { | 338 | if (card == NULL) { |
339 | printk(KERN_ERR "pc300: unable to allocate memory\n"); | 339 | printk(KERN_ERR "pc300: unable to allocate memory\n"); |
340 | pci_release_regions(pdev); | 340 | pci_release_regions(pdev); |
341 | pci_disable_device(pdev); | 341 | pci_disable_device(pdev); |
342 | return -ENOBUFS; | 342 | return -ENOBUFS; |
343 | } | 343 | } |
344 | memset(card, 0, sizeof(card_t)); | ||
345 | pci_set_drvdata(pdev, card); | 344 | pci_set_drvdata(pdev, card); |
346 | 345 | ||
347 | if (pdev->device == PCI_DEVICE_ID_PC300_TE_1 || | 346 | if (pdev->device == PCI_DEVICE_ID_PC300_TE_1 || |