diff --git a/drivers/media/pci/cx88/cx88-mpeg.c b/drivers/media/pci/cx88/cx88-mpeg.c index a369b0840acffde2584e78bdba236eb0ed9c2e5f..98344540c51f83bb57be721a98d9c8b6288357c2 100644 --- a/drivers/media/pci/cx88/cx88-mpeg.c +++ b/drivers/media/pci/cx88/cx88-mpeg.c @@ -732,7 +732,7 @@ static int cx8802_probe(struct pci_dev *pci_dev, dev->alloc_ctx = vb2_dma_sg_init_ctx(&pci_dev->dev); if (IS_ERR(dev->alloc_ctx)) { err = PTR_ERR(dev->alloc_ctx); - goto fail_core; + goto fail_dev; } dev->core = core; @@ -754,6 +754,7 @@ static int cx8802_probe(struct pci_dev *pci_dev, fail_free: vb2_dma_sg_cleanup_ctx(dev->alloc_ctx); + fail_dev: kfree(dev); fail_core: core->dvbdev = NULL;