X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fmtd%2Fmaps%2Fpci.c;fp=drivers%2Fmtd%2Fmaps%2Fpci.c;h=21822c2edbe40126198990635473c902c06e7dc0;hb=64ba3f394c830ec48a1c31b53dcae312c56f1604;hp=d2ab1bae9c346fbf2168ff59199222f226e6f2cb;hpb=be1e6109ac94a859551f8e1774eb9a8469fe055c;p=linux-2.6.git diff --git a/drivers/mtd/maps/pci.c b/drivers/mtd/maps/pci.c index d2ab1bae9..21822c2ed 100644 --- a/drivers/mtd/maps/pci.c +++ b/drivers/mtd/maps/pci.c @@ -334,6 +334,9 @@ mtd_pci_probe(struct pci_dev *dev, const struct pci_device_id *id) return 0; release: + if (mtd) + map_destroy(mtd); + if (map) { map->exit(dev, map); kfree(map);