From: David Rientjes <rientjes@google.com>
To: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: kosaki.motohiro@gmail.com, akpm@linux-foundation.org,
kamezawa.hiroyu@jp.fujitsu.com, linux-mm@kvack.org
Subject: Re: [patch] mm, mempolicy: make mempolicies robust against errors
Date: Wed, 7 Mar 2012 13:06:31 -0800 (PST) [thread overview]
Message-ID: <alpine.DEB.2.00.1203071304160.7640@chino.kir.corp.google.com> (raw)
In-Reply-To: <4F578BCA.1090706@jp.fujitsu.com>
On Wed, 7 Mar 2012, KOSAKI Motohiro wrote:
> > It's a different topic, the proposal here is whether an error in
> > mempolicies (either the code or flipped bit) should crash the kernel or
> > not since it's a condition that can easily be recovered from and leave
> > BUG() to errors that actually are fatal. Crashing the kernel offers no
> > advantage.
>
> Should crash? The code path never reach. thus there is no ideal behavior.
> In this case, BUG() is just unreachable annotation. So let's just annotate
> unreachable() even though CONFIG_BUG=n.
>
> WARN_ON_ONCE makes code broat and no positive impact.
>
I think you misunderstand the difference between WARN() and BUG(). Both
are intended to never be reached; the difference is that BUG() is a fatal
condition and WARN() is not. All of the changes from BUG() to WARN() in
this patch are not fatal and has no other side-effects other memory
allocations that are not truly interleaved, for example. These should
have been WARN() from the beginning.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2012-03-07 21:06 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-04 21:43 [patch] mm, mempolicy: dummy slab_node return value for bugless kernels David Rientjes
2012-03-06 20:15 ` Rafael Aquini
2012-03-07 0:08 ` Andrew Morton
2012-03-07 0:55 ` Rafael Aquini
2012-03-07 4:25 ` David Rientjes
2012-03-07 4:29 ` [patch] mm, mempolicy: make mempolicies robust against errors David Rientjes
2012-03-07 5:30 ` KOSAKI Motohiro
2012-03-07 5:58 ` David Rientjes
2012-03-07 6:34 ` KOSAKI Motohiro
2012-03-07 6:56 ` David Rientjes
2012-03-07 16:24 ` KOSAKI Motohiro
2012-03-07 21:06 ` David Rientjes [this message]
2012-03-08 23:51 ` Andrew Morton
2012-04-26 14:58 ` Christoph Lameter
2012-03-07 11:12 ` [patch] mm, mempolicy: dummy slab_node return value for bugless kernels Glauber Costa
2012-03-07 21:04 ` David Rientjes
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=alpine.DEB.2.00.1203071304160.7640@chino.kir.corp.google.com \
--to=rientjes@google.com \
--cc=akpm@linux-foundation.org \
--cc=kamezawa.hiroyu@jp.fujitsu.com \
--cc=kosaki.motohiro@gmail.com \
--cc=kosaki.motohiro@jp.fujitsu.com \
--cc=linux-mm@kvack.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