• Rafael J. Wysocki's avatar
    ACPI: glue: Rearrange find_child_checks() · b7fbf4ce
    Rafael J. Wysocki authored
    Notice that it is not necessary to evaluate _STA in find_child_checks()
    if the device is expected to have children, but there are none, so
    move the children check to the front of the function.
    
    Also notice that FIND_CHILD_MIN_SCORE can be returned right away if
    _STA is missing, so make the function do so.
    
    Finally, replace the ternary operator in the return statement argument
    with an if () and a standalone return which is somewhat easier to
    follow.
    Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
    b7fbf4ce
glue.c 8.13 KB