From: "Randy.Dunlap" <rddunlap@osdl.org>
To: netdev@oss.sgi.com
Cc: jgarzik@pobox.com
Subject: [janitor] depca: release resources on errors
Date: Sat, 24 Jan 2004 22:31:09 -0800 [thread overview]
Message-ID: <20040124223109.1c134ca1.rddunlap@osdl.org> (raw)
Hi,
Please apply to 2.6.current.
Thanks,
--
~Randy
From: Leann Ogasawara <ogasawara@osdl.org>
Hi All,
Inserts missing iounmap's and release_mem_region's. Appreciate
feedback.
Leann
diffed against 2.6.1
===== drivers/net/depca.c 1.20 vs edited =====
diff -puN drivers/net/depca.c~depca_iounmap drivers/net/depca.c
diff -puN drivers/net/depca.c~depca_iounmap drivers/net/depca.c
linux-262-rc1-bk1-rddunlap/drivers/net/depca.c | 4 ++++
1 files changed, 4 insertions(+)
diff -puN drivers/net/depca.c~depca_iounmap drivers/net/depca.c
--- linux-262-rc1-bk1/drivers/net/depca.c~depca_iounmap 2004-01-23 15:49:48.000000000 -0800
+++ linux-262-rc1-bk1-rddunlap/drivers/net/depca.c 2004-01-23 15:49:48.000000000 -0800
@@ -771,6 +771,8 @@ static int __init depca_hw_init (struct
status = -ENXIO;
if (!irqnum) {
printk(" and failed to detect IRQ line.\n");
+ iounmap(lp->sh_mem);
+ release_mem_region(mem_start, mem_len);
goto out_priv;
} else {
for (dev->irq = 0, i = 0; (depca_irq[i]) && (!dev->irq); i++)
@@ -781,6 +783,8 @@ static int __init depca_hw_init (struct
if (!dev->irq) {
printk(" but incorrect IRQ line detected.\n");
+ iounmap(lp->sh_mem);
+ release_mem_region(mem_start, mem_len);
return -ENXIO;
}
}
_
next reply other threads:[~2004-01-25 6:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-25 6:31 Randy.Dunlap [this message]
2004-01-25 16:36 ` [janitor] depca: release resources on errors Jeff Garzik
2004-01-26 3:30 ` Randy.Dunlap
2004-01-26 4:25 ` Jeff Garzik
2004-01-30 2:14 ` Leann Ogasawara
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040124223109.1c134ca1.rddunlap@osdl.org \
--to=rddunlap@osdl.org \
--cc=jgarzik@pobox.com \
--cc=netdev@oss.sgi.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).