Messages in this thread | | | Date | Sun, 22 Aug 2021 16:36:46 +0200 | From | Borislav Petkov <> | Subject | Re: [PATCH v2 1/3] x86/mce: Avoid infinite loop for copy from user recovery |
| |
On Fri, Aug 20, 2021 at 01:23:46PM -0700, Luck, Tony wrote: > To recover we need to have some other place to jump to (besides the > normal extable error return ... which isn't working if we find ourselves > in this situation) when we hit a fault covered by an extable entry. And > also know how many machine checks is "normal" before taking the other path.
Hohumm, we're on the same page here.
...
> Bottom line is that I don't think this panic can actually happen unless > there is some buggy kernel code that retries get_user() or copyin() > indefinitely.
You know how such statements of "well, this should not really happen in practice" get disproved by, well, practice. :-)
I guess we'll see anyway what actually happens in practice.
> Probably the same for the two different addresses case ... though I'm > not 100% confident about that. There could be some ioctl() that peeks > at two parts of a passed in structure, and the user might pass in a > structure that spans across a page boundary with both pages poisoned. > But that would only hit if the driver code ignored the failure of the > first get_user() and blindly tried the second. So I'd count that as a > critically bad driver bug.
Right.
-- Regards/Gruss, Boris.
https://people.kernel.org/tglx/notes-about-netiquette
| |