lkml.org 
[lkml]   [2013]   [Mar]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 0/1] poweroff: change orderly_poweroff() to use schedule_work()
Hi Oleg,

On Wed, Mar 13, 2013 at 2:46 PM, Oleg Nesterov <oleg@redhat.com> wrote:
> On 03/12, Oleg Nesterov wrote:
>>
>> On 03/12, Linus Torvalds wrote:
>> >
>> > So yeah, I guess
>> > everything could just go into a workqueue.
>>
>> OK, I'll try to make the patch tomorrow. Should be trivial but it is
>> not clear how we should pass "bool force" without allocating the
>> work_struct which would be nice to avoid.
>
> Yes, it would be nice to keep it simple and use a single work/arg.
>
> Could you review? The change is trivial but
>
> - orderly_poweroff() always return 0.
>
> - the patch assumes that orderly_poweroff(false) after
> orderly_poweroff(true) acts as "force = true". Only xen
> uses "false", I hope this is fine.
>
> In fact I think we can change poweroff_force argument
> unconditionally, this "if (force)" check is mostly
> documentation.

I'm not so familiar with this code, but for me it looks reasonable to
let orderly_poweroff(true) win even if there's an
orderly_poweroff(false) later.

>
> But we can add the locking or even allocate work_struct
> every time if this is wrong (or just looks wrong).
>
> - The patch assumes that orderly_poweroff() doesn't need
> the keventd_up() check, I hope this is correct...
>
>
> Lucas, Andrew, sorry. If this patch will be applied, then
>
> kernel-sysc-use-the-simpler-call_usermodehelper.patch

No problem for me... your patch already does what this one is doing.

Lucas De Marchi


\
 
 \ /
  Last update: 2013-03-14 01:21    [W:0.115 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site