From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: Steve Kemp <steve@steve.org.uk>
Cc: linux-kernel@vger.kernel.org
Subject: Re: trivial patches: Should we care about control reaches end of non-void function
Date: Wed, 15 Oct 2008 23:26:25 +0100 [thread overview]
Message-ID: <20081015232625.547ebe9e@lxorguk.ukuu.org.uk> (raw)
In-Reply-To: <20081015180732.GA4119@steve.org.uk>
> I see some functions in the kernel have added "return 0" after the
> BUG, presumably to silence these warnings. Would a patch to do this
> consistently, or is that too trivial even for trivial patches?
Probably better to mark BUG() properly for the compiler.
If you can get __attribute((__noreturn__)) on the end of the BUG function
somehow say
static inline void bug_off(void) __attribute((__noreturn__)) {};
and expanded that onto the end of the macro maybe it would shut up
Alan
next prev parent reply other threads:[~2008-10-15 22:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-15 18:07 Steve Kemp
2008-10-15 21:33 ` [PATCH] compiler warning cleanup Steve Kemp
2008-10-15 22:26 ` Alan Cox [this message]
2008-10-16 6:08 ` trivial patches: Should we care about control reaches end of non-void function Steve Kemp
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=20081015232625.547ebe9e@lxorguk.ukuu.org.uk \
--to=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=steve@steve.org.uk \
/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
all inboxes | Powered by JetHome®