diff options
Diffstat (limited to 'drivers/media/dvb/ngene/ngene-core.c')
-rw-r--r-- | drivers/media/dvb/ngene/ngene-core.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/dvb/ngene/ngene-core.c b/drivers/media/dvb/ngene/ngene-core.c index 3a7ef71087be..dc073bdc623a 100644 --- a/drivers/media/dvb/ngene/ngene-core.c +++ b/drivers/media/dvb/ngene/ngene-core.c | |||
@@ -1304,7 +1304,6 @@ static void ngene_stop(struct ngene *dev) | |||
1304 | static int ngene_start(struct ngene *dev) | 1304 | static int ngene_start(struct ngene *dev) |
1305 | { | 1305 | { |
1306 | int stat; | 1306 | int stat; |
1307 | unsigned long flags; | ||
1308 | int i; | 1307 | int i; |
1309 | 1308 | ||
1310 | pci_set_master(dev->pci_dev); | 1309 | pci_set_master(dev->pci_dev); |
@@ -1337,6 +1336,8 @@ static int ngene_start(struct ngene *dev) | |||
1337 | #ifdef CONFIG_PCI_MSI | 1336 | #ifdef CONFIG_PCI_MSI |
1338 | /* enable MSI if kernel and card support it */ | 1337 | /* enable MSI if kernel and card support it */ |
1339 | if (pci_msi_enabled() && dev->card_info->msi_supported) { | 1338 | if (pci_msi_enabled() && dev->card_info->msi_supported) { |
1339 | unsigned long flags; | ||
1340 | |||
1340 | ngwritel(0, NGENE_INT_ENABLE); | 1341 | ngwritel(0, NGENE_INT_ENABLE); |
1341 | free_irq(dev->pci_dev->irq, dev); | 1342 | free_irq(dev->pci_dev->irq, dev); |
1342 | stat = pci_enable_msi(dev->pci_dev); | 1343 | stat = pci_enable_msi(dev->pci_dev); |
@@ -1515,7 +1516,7 @@ static int init_channels(struct ngene *dev) | |||
1515 | 1516 | ||
1516 | void __devexit ngene_remove(struct pci_dev *pdev) | 1517 | void __devexit ngene_remove(struct pci_dev *pdev) |
1517 | { | 1518 | { |
1518 | struct ngene *dev = (struct ngene *)pci_get_drvdata(pdev); | 1519 | struct ngene *dev = pci_get_drvdata(pdev); |
1519 | int i; | 1520 | int i; |
1520 | 1521 | ||
1521 | tasklet_kill(&dev->event_tasklet); | 1522 | tasklet_kill(&dev->event_tasklet); |
@@ -1536,12 +1537,11 @@ int __devinit ngene_probe(struct pci_dev *pci_dev, | |||
1536 | if (pci_enable_device(pci_dev) < 0) | 1537 | if (pci_enable_device(pci_dev) < 0) |
1537 | return -ENODEV; | 1538 | return -ENODEV; |
1538 | 1539 | ||
1539 | dev = vmalloc(sizeof(struct ngene)); | 1540 | dev = vzalloc(sizeof(struct ngene)); |
1540 | if (dev == NULL) { | 1541 | if (dev == NULL) { |
1541 | stat = -ENOMEM; | 1542 | stat = -ENOMEM; |
1542 | goto fail0; | 1543 | goto fail0; |
1543 | } | 1544 | } |
1544 | memset(dev, 0, sizeof(struct ngene)); | ||
1545 | 1545 | ||
1546 | dev->pci_dev = pci_dev; | 1546 | dev->pci_dev = pci_dev; |
1547 | dev->card_info = (struct ngene_info *)id->driver_data; | 1547 | dev->card_info = (struct ngene_info *)id->driver_data; |