From: Don Zickus <dzickus@redhat.com>
To: Li Zhong <zhong@linux.vnet.ibm.com>
Cc: x86@kernel.org, Peter Zijlstra <peterz@infradead.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] x86,nmi: Fix page faults by nmiaction if kmemcheck is enabled
Date: Fri, 9 Mar 2012 09:24:22 -0500 [thread overview]
Message-ID: <20120309142422.GD24378@redhat.com> (raw)
In-Reply-To: <1331287938.13274.38.camel@ThinkPad-T420>
On Fri, Mar 09, 2012 at 05:12:18AM -0500, Li Zhong wrote:
> On Thu, 2012-03-08 at 16:02 -0500, Don Zickus wrote:
>
> Thank you, Don.
>
> As flags is moved into the macro, it may cause following compile error,
> drivers/watchdog/hpwdt.c: In function 'hpwdt_init_nmi_decoding':
> drivers/watchdog/hpwdt.c:737: error: initializer element is not constant
> drivers/watchdog/hpwdt.c:737: error: (near initialization for
> 'hpwdt_pretimeout_na.flags')
Crap, I thought I had them all compiled. Thanks for the heads up.
Actually I think this could is just misusing the flag to begin with. Let
me figure out what is going on.
Thanks,
Don
>
> So following fix might be needed:
>
> diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c
> index 3c166d3..e1161ea 100644
> --- a/drivers/watchdog/hpwdt.c
> +++ b/drivers/watchdog/hpwdt.c
> @@ -734,9 +734,12 @@ static int __devinit hpwdt_init_nmi_decoding(struct pci_dev *dev)
> * die notify list to handle a critical NMI. The default is to
> * be last so other users of the NMI signal can function.
> */
> - retval = register_nmi_handler(NMI_UNKNOWN, hpwdt_pretimeout,
> - (priority) ? NMI_FLAG_FIRST : 0,
> - "hpwdt");
> + if (priority)
> + retval = register_nmi_handler(NMI_UNKNOWN, hpwdt_pretimeout,
> + NMI_FLAG_FIRST, "hpwdt");
> + else
> + retval = register_nmi_handler(NMI_UNKNOWN, hpwdt_pretimeout,
> + 0, "hpwdt");
> if (retval != 0) {
> dev_warn(&dev->dev,
> "Unable to register a die notifier (err=%d).\n",
>
>
prev parent reply other threads:[~2012-03-09 14:24 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-08 21:02 Don Zickus
2012-03-08 21:04 ` Peter Zijlstra
2012-03-09 10:12 ` Li Zhong
2012-03-09 14:24 ` Don Zickus [this message]
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=20120309142422.GD24378@redhat.com \
--to=dzickus@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=x86@kernel.org \
--cc=zhong@linux.vnet.ibm.com \
/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®