lkml.org 
[lkml]   [2013]   [Mar]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH v13 4/8] add a new runstate: RUN_STATE_GUEST_PANICKED
    Il 05/03/2013 04:17, Hu Tao ha scritto:
    > Will
    >
    > if (runstate_check(RUN_STATE_INTERNAL_ERROR) ||
    > runstate_check(RUN_STATE_SHUTDOWN) ||
    > runstate_check(RUN_STATE_GUEST_PANICKED)) {
    > runstate_set(RUN_STATE_PAUSED);
    > }
    >
    > be OK? Or I must be misunderstanding you.
    >

    Please move

    return (runstate_check(RUN_STATE_INTERNAL_ERROR) ||
    runstate_check(RUN_STATE_SHUTDOWN) ||
    runstate_check(RUN_STATE_GUEST_PANICKED));

    to a separate function (runstate_needs_reset for example), so that you
    can reuse it in the two or three places that need it.

    Paolo


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