diff options
author | Amol Lad <amol@verismonetworks.com> | 2006-12-06 20:35:19 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-07 08:39:30 -0800 |
commit | 8684265412518858c48a56c2f0aa86f280978b74 (patch) | |
tree | fe3f59c28991d84ae031d8d40613e5b29514c0aa /drivers | |
parent | 238b8721a554a33a451a3f13bdb5be8fe5cfc927 (diff) | |
download | linux-8684265412518858c48a56c2f0aa86f280978b74.tar.gz linux-8684265412518858c48a56c2f0aa86f280978b74.tar.bz2 linux-8684265412518858c48a56c2f0aa86f280978b74.zip |
[PATCH] ioremap balanced with iounmap for drivers/char/rio/rio_linux.c
Signed-off-by: Amol Lad <amol@verismonetworks.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/char/rio/rio_linux.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/char/rio/rio_linux.c b/drivers/char/rio/rio_linux.c index 7ac68cb3bedd..e79b2ede8510 100644 --- a/drivers/char/rio/rio_linux.c +++ b/drivers/char/rio/rio_linux.c @@ -1026,6 +1026,7 @@ static int __init rio_init(void) found++; } else { iounmap(p->RIOHosts[p->RIONumHosts].Caddr); + p->RIOHosts[p->RIONumHosts].Caddr = NULL; } } @@ -1078,6 +1079,7 @@ static int __init rio_init(void) found++; } else { iounmap(p->RIOHosts[p->RIONumHosts].Caddr); + p->RIOHosts[p->RIONumHosts].Caddr = NULL; } #else printk(KERN_ERR "Found an older RIO PCI card, but the driver is not " "compiled to support it.\n"); @@ -1117,8 +1119,10 @@ static int __init rio_init(void) } } - if (!okboard) + if (!okboard) { iounmap(hp->Caddr); + hp->Caddr = NULL; + } } } @@ -1188,6 +1192,8 @@ static void __exit rio_exit(void) } /* It is safe/allowed to del_timer a non-active timer */ del_timer(&hp->timer); + if (hp->Caddr) + iounmap(hp->Caddr); if (hp->Type == RIO_PCI) pci_dev_put(hp->pdev); } |