From: Petr Tesarik <ptesarik@suse.com>
To: Josh Triplett <josh@joshtriplett.org>
Cc: Juergen Gross <jgross@suse.com>, Ingo Molnar <mingo@redhat.com>,
Thomas Gleixner <tglx@linutronix.de>,
Eric Biederman <ebiederm@xmission.com>,
"H. Peter Anvin" <hpa@zytor.com>,
Boris Ostrovsky <boris.ostrovsky@oracle.com>,
"Paul E. McKenney" <paulmck@linux.vnet.ibm.com>,
Dave Young <dyoung@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
David Vrabel <david.vrabel@citrix.com>,
"moderated list:XEN HYPERVISOR INTERFACE"
<xen-devel@lists.xenproject.org>,
"maintainer:X86 ARCHITECTURE 32-BIT AND 64-BIT" <x86@kernel.org>,
"open list:KEXEC" <kexec@lists.infradead.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/2] Add a kexec_crash_loaded() function
Date: Wed, 13 Jul 2016 15:03:22 +0200 [thread overview]
Message-ID: <20160713150322.45d47ed4@hananiah.suse.cz> (raw)
In-Reply-To: <20160713125232.GA32462@x>
On Wed, 13 Jul 2016 05:52:33 -0700
Josh Triplett <josh@joshtriplett.org> wrote:
> On Wed, Jul 13, 2016 at 02:19:55PM +0200, Petr Tesarik wrote:
> > --- a/kernel/kexec_core.c
> > +++ b/kernel/kexec_core.c
> > @@ -95,6 +95,12 @@ int kexec_should_crash(struct task_struct *p)
> > return 0;
> > }
> >
> > +int kexec_crash_loaded(void)
> > +{
> > + return !!kexec_crash_image;
> > +}
>
> Nit: this function should return bool rather than int, since it
> effectively returns true/false.
I thought about this for a moment. Since the return value should also
be used for the corresponding sysctl, which is an integer, I wasn't
sure if bool is the correct type, especially since other boolean
functions in kexec.h also return int... But that could be legacy.
I've got no problem changing the type to 'bool' if that's what it takes.
Petr T
next prev parent reply other threads:[~2016-07-13 13:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-13 12:19 [PATCH 0/2] Allow crash dumps with crash_kexec_post_notifiers Petr Tesarik
2016-07-13 12:19 ` [PATCH 1/2] Add a kexec_crash_loaded() function Petr Tesarik
2016-07-13 12:52 ` Josh Triplett
2016-07-13 13:03 ` Petr Tesarik [this message]
2016-07-13 12:20 ` [PATCH 2/2] Allow kdump with crash_kexec_post_notifiers Petr Tesarik
2016-07-13 12:53 ` [Xen-devel] " David Vrabel
2016-08-01 11:55 ` Jan Beulich
2016-07-13 12:27 ` [PATCH 0/2] Allow crash dumps " Petr Tesarik
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=20160713150322.45d47ed4@hananiah.suse.cz \
--to=ptesarik@suse.com \
--cc=akpm@linux-foundation.org \
--cc=boris.ostrovsky@oracle.com \
--cc=david.vrabel@citrix.com \
--cc=dyoung@redhat.com \
--cc=ebiederm@xmission.com \
--cc=hpa@zytor.com \
--cc=jgross@suse.com \
--cc=josh@joshtriplett.org \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=paulmck@linux.vnet.ibm.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=xen-devel@lists.xenproject.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
all inboxes | Powered by JetHome®