lkml.org 
[lkml]   [2016]   [Apr]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] efibc: avoid stack overflow warning
On Sun, 01 May, at 12:34:29AM, Arnd Bergmann wrote:
>
> The sys_restart() system call takes a mutex before calling kernel_restart()
> or kernel_poweroff().
>
> I've had a closer look now and found that there are a few other
> callers of kernel_restart, so I guess if you restart using sysctl
> at the exact same time as calling /sbin/reboot, things may break.

Right. Or if the dm-verify-target driver saw an error.

> It's not something we'd have to worry about in practice, but it does
> make my patch incorrect. Should we come up with a different way to
> do it?

Jeremy proposed a patch to dynamically allocate the memory, which I
think is the correct way to go given that our (reasonable) assumptions
about reboot notifier concurrency are not guaranteed,

https://lkml.kernel.org/r/87h9eked24.fsf@jcompost-MOBL1.tl.intel.com

\
 
 \ /
  Last update: 2016-05-01 01:01    [W:0.668 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site