From: Arnaldo Carvalho de Melo <acme@conectiva.com.br>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] bmac.c: restore_flags on failure
Date: Mon, 8 Jan 2001 20:02:31 -0200 [thread overview]
Message-ID: <20010108200231.C17087@conectiva.com.br> (raw)
Alan,
I haven't found Randy Gobbel's e-mail, please apply.
- Arnaldo
--- linux-2.4.0-ac3/drivers/net/bmac.c Tue Dec 19 11:24:51 2000
+++ linux-2.4.0-ac3.acme/drivers/net/bmac.c Mon Jan 8 19:55:30 2001
@@ -6,6 +6,8 @@
*
* May 1999, Al Viro: proper release of /proc/net/bmac entry, switched to
* dynamic procfs inode.
+ * Jan 2001, Arnaldo Carvalho de Melo <acme@conectiva.com.br>
+ * restore_flags on failure in bmac_reset_and_enable
*/
#include <linux/config.h>
#include <linux/module.h>
@@ -1227,9 +1229,9 @@
bmac_reset_chip(dev);
if (enable) {
if (!bmac_init_tx_ring(bp) || !bmac_init_rx_ring(bp))
- return 0;
+ goto out;
if (!bmac_init_chip(dev))
- return 0;
+ goto out;
bmac_start_chip(dev);
bmwrite(dev, INTDISABLE, EnableNormal);
bp->reset_and_enabled = 1;
@@ -1247,6 +1249,8 @@
}
restore_flags(flags);
return 1;
+out: restore_flags(flags);
+ return 0;
}
static int __init bmac_probe(void)
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
reply other threads:[~2001-01-08 23:50 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20010108200231.C17087@conectiva.com.br \
--to=acme@conectiva.com.br \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
/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).