public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@amd64.org>
To: Tony Luck <tony.luck@intel.com>
Cc: linux-kernel@vger.kernel.org, Ingo Molnar <mingo@elte.hu>,
	Chen Gong <gong.chen@linux.intel.com>,
	"Huang, Ying" <ying.huang@intel.com>,
	Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
Subject: Re: [PATCH] x86/mce: Need to let kill_proc() send signal to doomed process
Date: Tue, 10 Jul 2012 17:44:10 +0200	[thread overview]
Message-ID: <20120710154410.GA29892@aftab.osrc.amd.com> (raw)
In-Reply-To: <f830ac24f491389b0246af0fb31d0546f3583380.1341866155.git.tony.luck@intel.com>

On Mon, Jul 09, 2012 at 01:34:36PM -0700, Tony Luck wrote:
> In commit dad1743e5993f19b3d7e7bd0fb35dc45b5326626
>   x86/mce: Only restart instruction after machine check recovery if it is safe
> 
> we fixed mce_notify_process() to force a signal to the current process
> if it was not restartable (RIPV bit not set in MCG_STATUS). But doing
> it here means that the process doesn't get told the virtual address of
> the fault via siginfo_t->si_addr. This would prevent application level
> recovery from the fault.
> 
> Make a new MF_MUST_KILL flag bit for memory_failure() et. al. to use
> so that we will provide the right information with the signal.
> 
> Signed-off-by: Tony Luck <tony.luck@intel.com>
> ---
> 
> v2: Fix brainfart where I forgot to check mi->restartable to decide whether
>     to pass in the new MF_MUST_KILL bit [Thanks Boris for spotting this!]
>     Use same style syntax !!(flags & MF_MUST_KILL) [Also from Boris]
>     Faked tests with RIPV set and not set ... and found that we need one
>     more check on MF_MUST_KILL earlier in hwpoison_user_mappings() to
>     make sure it doesn't think the clean page case is recoverable.

Ok, now it makes pretty good sense.

Acked-by: Borislav Petkov <borislav.petkov@amd.com>

Thanks.

-- 
Regards/Gruss,
Boris.

Advanced Micro Devices GmbH
Einsteinring 24, 85609 Dornach
GM: Alberto Bozzo
Reg: Dornach, Landkreis Muenchen
HRB Nr. 43632 WEEE Registernr: 129 19551

  reply	other threads:[~2012-07-10 15:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-06 21:33 [PATCH] x86/mce: Need to let kill_proc() send signal to doomed process Tony Luck
2012-07-07  4:38 ` Borislav Petkov
2012-07-09 16:22   ` Luck, Tony
2012-07-09 20:34     ` Tony Luck
2012-07-10 15:44       ` Borislav Petkov [this message]
2012-07-10 17:12         ` Tony Luck
2012-07-10 18:36           ` Borislav Petkov

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=20120710154410.GA29892@aftab.osrc.amd.com \
    --to=bp@amd64.org \
    --cc=gong.chen@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=seto.hidetoshi@jp.fujitsu.com \
    --cc=tony.luck@intel.com \
    --cc=ying.huang@intel.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