Skip to content

Commit

Permalink
[media] bttv: fix missing irq after reloading driver
Browse files Browse the repository at this point in the history
If pci_disable_device() isn't called when the driver is removed, then
the next time when it is loaded the irq isn't found.

I'm pretty sure this used to work in the past, but calling
pci_disable_device() is clearly the correct method and this makes
it work again.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed May 1, 2015
1 parent 9450684 commit de73e13
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/media/pci/bt8xx/bttv-driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -4239,6 +4239,7 @@ static int bttv_probe(struct pci_dev *dev, const struct pci_device_id *pci_id)
iounmap(btv->bt848_mmio);
release_mem_region(pci_resource_start(btv->c.pci,0),
pci_resource_len(btv->c.pci,0));
pci_disable_device(btv->c.pci);
return result;
}

Expand Down Expand Up @@ -4282,6 +4283,7 @@ static void bttv_remove(struct pci_dev *pci_dev)
iounmap(btv->bt848_mmio);
release_mem_region(pci_resource_start(btv->c.pci,0),
pci_resource_len(btv->c.pci,0));
pci_disable_device(btv->c.pci);

v4l2_device_unregister(&btv->c.v4l2_dev);
bttvs[btv->c.nr] = NULL;
Expand Down

0 comments on commit de73e13

Please sign in to comment.