lkml.org 
[lkml]   [2009]   [Feb]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[patch 26/41] ACPICA: Fixed a couple memory leaks associated with "implicit return"

    2.6.27-stable review patch. If anyone has any objections, please let us know.

    ------------------

    From: Lin Ming <ming.m.lin@intel.com>

    commit d8a0ec914afa1a994d2f6184ac4c6668b5f8068f upstream

    Fixed a couple memory leaks associated with "implicit return" objects
    when the AML Interpreter slack mode is enabled.

    http://www.acpica.org/bugzilla/show_bug.cgi?id=349

    Signed-off-by: Lin Ming <ming.m.lin@intel.com>
    Signed-off-by: Bob Moore <robert.moore@intel.com>
    Signed-off-by: Len Brown <len.brown@intel.com>
    Cc: Thomas Renninger <trenn@suse.de>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

    ---
    drivers/acpi/dispatcher/dsmethod.c | 3 +++
    drivers/acpi/parser/psparse.c | 4 +++-
    2 files changed, 6 insertions(+), 1 deletion(-)

    --- a/drivers/acpi/dispatcher/dsmethod.c
    +++ b/drivers/acpi/dispatcher/dsmethod.c
    @@ -103,6 +103,9 @@ acpi_ds_method_error(acpi_status status,
    NULL);
    acpi_ex_enter_interpreter();
    }
    +
    + acpi_ds_clear_implicit_return(walk_state);
    +
    #ifdef ACPI_DISASSEMBLER
    if (ACPI_FAILURE(status)) {

    --- a/drivers/acpi/parser/psparse.c
    +++ b/drivers/acpi/parser/psparse.c
    @@ -641,10 +641,12 @@ acpi_status acpi_ps_parse_aml(struct acp
    ACPI_WALK_METHOD_RESTART;
    }
    } else {
    - /* On error, delete any return object */
    + /* On error, delete any return object or implicit return */

    acpi_ut_remove_reference(previous_walk_state->
    return_desc);
    + acpi_ds_clear_implicit_return
    + (previous_walk_state);
    }
    }



    \
     
     \ /
      Last update: 2009-02-04 20:05    [W:0.023 / U:0.240 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site