forked from Minki/linux
- Fix the vDSO exception handling return path to disable interrupts
again. - A fix for the CE collector to return the proper return values to its callers which are used to convey what the collector has done with the error address. -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEzv7L6UO9uDPlPSfHEsHwGGHeVUoFAmByunsACgkQEsHwGGHe VUo+rRAAmhs1CRMKMcha3KoQM5e3QUk8dA8xYuuHa9UJve6r2HXzSwldAGpYmSKS v3Pcdeue0INovp+HWSe1UJa/U6ugQ6KcjGy+xMx01VHAuWjAv/O7wMDRfxMDOnJI XmgXJG6IhjZUlRuD7BNkFRkUnsk5dABFTlm3OXcpmOyXBsvRPm2M6n4/ILjIlYI+ kZCyPf0wmR2VpmwCAkhye1tdWBBmT3I3DNwgq15bhAGf6Eh7fqcieqRmBgwYpHhJ bOKx7WeRJa4VayV7uvRId9MAyhi9MY66Mb+CIsK0sxkcza2KizquwapN5zUNKpu2 i24huaNDljB8n0EV8ZJZpI9Xs9QJUBYL10w3LvaSwEySwnN7QrTWzEn5/gYAS7+J wR4og5eDMGzgojZi56adQdnrg3thkGPviikU2lUbXo0mpeoT5I6zaQYdkbBq9r9/ g6LhM86dOeXqpFDPwSRKCoUgiARDoj+woi+4GF1Hc+bIaffP46K4FnOEUODePS3c EXWEpJC2DGZq+QfXBViJKcrQi+0/n9jDD6hY5N4TBsyxuN4iUX60rLiMwNJiphmI xMwd7Gcr92K3yiEd7zkav2ncuqBk/OCSadubaDyMQFb0F95evBv09yQKN/RImmZq Ywt83UG4x+OXIlbQpAXkgLGMhFkH1GtQJ2DOssT6zrw2PFpjP5w= =aV+H -----END PGP SIGNATURE----- Merge tag 'x86_urgent_for_v5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Borislav Petkov: - Fix the vDSO exception handling return path to disable interrupts again. - A fix for the CE collector to return the proper return values to its callers which are used to convey what the collector has done with the error address. * tag 'x86_urgent_for_v5.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/traps: Correct exc_general_protection() and math_error() return paths RAS/CEC: Correct ce_add_elem()'s returned values
This commit is contained in:
commit
06f838e02d
@ -556,7 +556,7 @@ DEFINE_IDTENTRY_ERRORCODE(exc_general_protection)
|
||||
tsk->thread.trap_nr = X86_TRAP_GP;
|
||||
|
||||
if (fixup_vdso_exception(regs, X86_TRAP_GP, error_code, 0))
|
||||
return;
|
||||
goto exit;
|
||||
|
||||
show_signal(tsk, SIGSEGV, "", desc, regs, error_code);
|
||||
force_sig(SIGSEGV);
|
||||
@ -1057,7 +1057,7 @@ static void math_error(struct pt_regs *regs, int trapnr)
|
||||
goto exit;
|
||||
|
||||
if (fixup_vdso_exception(regs, trapnr, 0, 0))
|
||||
return;
|
||||
goto exit;
|
||||
|
||||
force_sig_fault(SIGFPE, si_code,
|
||||
(void __user *)uprobe_get_trap_addr(regs));
|
||||
|
@ -309,11 +309,20 @@ static bool sanity_check(struct ce_array *ca)
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* cec_add_elem - Add an element to the CEC array.
|
||||
* @pfn: page frame number to insert
|
||||
*
|
||||
* Return values:
|
||||
* - <0: on error
|
||||
* - 0: on success
|
||||
* - >0: when the inserted pfn was offlined
|
||||
*/
|
||||
static int cec_add_elem(u64 pfn)
|
||||
{
|
||||
struct ce_array *ca = &ce_arr;
|
||||
int count, err, ret = 0;
|
||||
unsigned int to = 0;
|
||||
int count, ret = 0;
|
||||
|
||||
/*
|
||||
* We can be called very early on the identify_cpu() path where we are
|
||||
@ -330,8 +339,8 @@ static int cec_add_elem(u64 pfn)
|
||||
if (ca->n == MAX_ELEMS)
|
||||
WARN_ON(!del_lru_elem_unlocked(ca));
|
||||
|
||||
ret = find_elem(ca, pfn, &to);
|
||||
if (ret < 0) {
|
||||
err = find_elem(ca, pfn, &to);
|
||||
if (err < 0) {
|
||||
/*
|
||||
* Shift range [to-end] to make room for one more element.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user