From: Thomas Graf <tgraf@suug.ch>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, lucy.liu@intel.com,
john.r.fastabend@intel.com, alexander.h.duyck@intel.com
Subject: [PATCH] dcbnl: Use BUG_ON() instead of BUG()
Date: Thu, 14 Jun 2012 04:40:15 -0400 [thread overview]
Message-ID: <20120614084015.GC29738@canuck.infradead.org> (raw)
In-Reply-To: <20120613.155541.26513304496438357.davem@davemloft.net>
Signed-off-by: Thomas Graf <tgraf@suug.ch>
---
net/dcb/dcbnl.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/net/dcb/dcbnl.c b/net/dcb/dcbnl.c
index da6ee81..0a36007 100644
--- a/net/dcb/dcbnl.c
+++ b/net/dcb/dcbnl.c
@@ -208,10 +208,7 @@ static struct sk_buff *dcbnl_newmsg(int type, u8 cmd, u32 port, u32 seq,
return NULL;
nlh = nlmsg_put(skb, port, seq, type, sizeof(*dcb), flags);
- if (!nlh) {
- /* header should always fit, allocation must be buggy */
- BUG();
- }
+ BUG_ON(!nlh);
dcb = nlmsg_data(nlh);
dcb->dcb_family = AF_UNSPEC;
next prev parent reply other threads:[~2012-06-14 8:40 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-13 12:54 [PATCH 0/8] dcbnl: Major simplifications Thomas Graf
2012-06-13 12:54 ` [PATCH 1/8] dcbnl: Prepare framework to shorten handling functions Thomas Graf
2012-06-13 12:54 ` [PATCH 2/8] dcbnl: Shorten all command " Thomas Graf
2012-06-21 6:04 ` John Fastabend
2012-06-13 12:54 ` [PATCH 3/8] dcbnl: Remove now unused dcbnl_reply() Thomas Graf
2012-06-13 12:54 ` [PATCH 4/8] dcbnl: Use dcbnl_newmsg() where possible Thomas Graf
2012-06-13 12:54 ` [PATCH 5/8] dcbnl: Return consistent error codes Thomas Graf
2012-06-13 12:54 ` [PATCH 6/8] dcbnl: Move dcb app lookup code into dcb_app_lookup() Thomas Graf
2012-06-13 12:55 ` [PATCH 7/8] dcbnl: Move dcb app allocation into dcb_app_add() Thomas Graf
2012-06-13 12:55 ` [PATCH 8/8] dcbnl: Use type safe nlmsg_data() Thomas Graf
2012-06-13 22:55 ` [PATCH 0/8] dcbnl: Major simplifications David Miller
2012-06-14 7:54 ` Thomas Graf
2012-06-14 16:06 ` John Fastabend
2012-06-15 7:26 ` Thomas Graf
2012-06-16 3:53 ` John Fastabend
2012-06-14 8:40 ` Thomas Graf [this message]
2012-06-14 8:46 ` [PATCH] dcbnl: Use BUG_ON() instead of BUG() 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=20120614084015.GC29738@canuck.infradead.org \
--to=tgraf@suug.ch \
--cc=alexander.h.duyck@intel.com \
--cc=davem@davemloft.net \
--cc=john.r.fastabend@intel.com \
--cc=lucy.liu@intel.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).