linux-user: SIGSEGV on signal entry need not be fatal
authorPeter Maydell <peter.maydell@linaro.org>
Thu, 28 Jul 2016 15:44:47 +0000 (16:44 +0100)
committerRiku Voipio <riku.voipio@linaro.org>
Wed, 21 Sep 2016 19:01:45 +0000 (22:01 +0300)
commit09391669975a0e2882c181982d4ddee35a0080bb
treec41c5bc4677c75dd3df28b58b6f99151f79b83d3
parent9d2803f720d5b71937c0f564bb2c16d8f5e18c8c
linux-user: SIGSEGV on signal entry need not be fatal

A failed write to memory trying to set up the signal frame
should trigger a SIGSEGV, but this need not be fatal: the
guest has a chance to catch it. Implement this via a force_sigsegv()
function with the same behaviour as the kernel function of that
name: make sure that we don't try to re-take a failed SIGSEGV,
and force a synchronous signal.

Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
linux-user/signal.c