From: Brian King <brking@linux.vnet.ibm.com>
To: netdev@vger.kernel.org
Cc: brking@linux.vnet.ibm.com
Subject: [PATCH 1/1] ibmveth: Fix oops on request_irq failure
Date: Wed, 28 Sep 2011 10:33:43 -0500 [thread overview]
Message-ID: <201109281533.p8SFXhfe030707@d03av04.boulder.ibm.com> (raw)
If request_irq fails, the ibmveth driver will overwrite
the rc and end up returning a successful rc on its open
function, resulting in an oops later when a packet gets
sent and buffers are not allocated due to the failed open.
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
---
drivers/net/ibmveth.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff -puN drivers/net/ibmveth.c~ibmveth_bounce_oops2 drivers/net/ibmveth.c
--- linux-2.6/drivers/net/ibmveth.c~ibmveth_bounce_oops2 2011-09-28 09:53:09.000000000 -0500
+++ linux-2.6-bjking1/drivers/net/ibmveth.c 2011-09-28 09:53:09.000000000 -0500
@@ -636,8 +636,8 @@ static int ibmveth_open(struct net_devic
netdev_err(netdev, "unable to request irq 0x%x, rc %d\n",
netdev->irq, rc);
do {
- rc = h_free_logical_lan(adapter->vdev->unit_address);
- } while (H_IS_LONG_BUSY(rc) || (rc == H_BUSY));
+ lpar_rc = h_free_logical_lan(adapter->vdev->unit_address);
+ } while (H_IS_LONG_BUSY(lpar_rc) || (lpar_rc == H_BUSY));
goto err_out;
}
_
next reply other threads:[~2011-09-28 15:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-28 15:33 Brian King [this message]
2011-09-29 4:34 ` [PATCH 1/1] ibmveth: Fix oops on request_irq failure David Miller
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=201109281533.p8SFXhfe030707@d03av04.boulder.ibm.com \
--to=brking@linux.vnet.ibm.com \
--cc=netdev@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).