aboutsummaryrefslogtreecommitdiffstats
path: root/sound/oss
diff options
context:
space:
mode:
authorAmol Lad <amol@verismonetworks.com>2006-12-06 23:35:23 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-07 11:39:30 -0500
commitb9d85b08c689dbf54b9943a02f73cb54c2b0fccf (patch)
treed653db1f027142b1ac51e6b04277b6d889802465 /sound/oss
parentaa8a8d664828c7184a2e775fb50611324ef21b5c (diff)
[PATCH] sound/oss/btaudio.c: ioremap balanced with iounmap
ioremap must be balanced by an iounmap and failing to do so can result in a memory leak. Signed-off-by: Amol Lad <amol@verismonetworks.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'sound/oss')
-rw-r--r--sound/oss/btaudio.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/oss/btaudio.c b/sound/oss/btaudio.c
index 6ad384114239..ad7210a00dc0 100644
--- a/sound/oss/btaudio.c
+++ b/sound/oss/btaudio.c
@@ -1020,6 +1020,7 @@ static int __devinit btaudio_probe(struct pci_dev *pci_dev,
1020 fail2: 1020 fail2:
1021 free_irq(bta->irq,bta); 1021 free_irq(bta->irq,bta);
1022 fail1: 1022 fail1:
1023 iounmap(bta->mmio);
1023 kfree(bta); 1024 kfree(bta);
1024 fail0: 1025 fail0:
1025 release_mem_region(pci_resource_start(pci_dev,0), 1026 release_mem_region(pci_resource_start(pci_dev,0),
@@ -1051,6 +1052,7 @@ static void __devexit btaudio_remove(struct pci_dev *pci_dev)
1051 free_irq(bta->irq,bta); 1052 free_irq(bta->irq,bta);
1052 release_mem_region(pci_resource_start(pci_dev,0), 1053 release_mem_region(pci_resource_start(pci_dev,0),
1053 pci_resource_len(pci_dev,0)); 1054 pci_resource_len(pci_dev,0));
1055 iounmap(bta->mmio);
1054 1056
1055 /* remove from linked list */ 1057 /* remove from linked list */
1056 if (bta == btaudios) { 1058 if (bta == btaudios) {