[lkml]   [2008]   [May]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: ACPI: kmemcheck: Caught 16-bit read from freed memory (f7c12ec6)

    On Thu, May 8, 2008 at 7:35 AM, Lin Ming <> wrote:
    > Here comes a simple patch that fixes the warning in my machine.
    > Vegard, would you please help to test it in your machine?

    Thanks for the try, but unfortunately this does not solve the problem.

    Please note that kmemcheck is an patch to the kernel; without it you
    will never see the warning. You can pull it from
    git:// current
    though it is unlikely that it will help you more than looking at the
    code (or the report) will do.

    > Thanks,
    > Lin Ming
    > Signed-off-by: Lin Ming <>
    > ---
    > diff --git a/drivers/acpi/parser/psargs.c b/drivers/acpi/parser/psargs.c
    > index f1e8bf6..ef55d24 100644
    > --- a/drivers/acpi/parser/psargs.c
    > +++ b/drivers/acpi/parser/psargs.c
    > @@ -268,7 +268,7 @@ acpi_ps_get_next_namepath(struct acpi_walk_state
    > *walk_state,

    > */
    > if (ACPI_SUCCESS(status) &&
    > possible_method_call && (node->type == ACPI_TYPE_METHOD)) {
    > - if (walk_state->op->common.aml_opcode == AML_UNLOAD_OP) {
    > + if (walk_state->op && walk_state->op->common.aml_opcode ==
    > AML_UNLOAD_OP) {
    > /*
    > * acpi_ps_get_next_namestring has increased the AML pointer,
    > * so we need to restore the saved AML pointer for method call.

    Also, noticing your change, I can see why it makes no difference:
    Pekka already found that it is walk_state->op that has the value of
    0xf7c12ec6 (e.g. the pointer being dereferenced), so the test will
    still succeed.

    On the other hand, I have discovered what seems to be a deficiency in
    kmemcheck (i.e. it might be my fault entirely), so it is possible that
    the warning is bogus. Will send an update shortly.


    "The animistic metaphor of the bug that maliciously sneaked in while
    the programmer was not looking is intellectually dishonest as it
    disguises that the error is the programmer's own creation."
    -- E. W. Dijkstra, EWD1036

     \ /
      Last update: 2008-05-08 08:09    [W:0.021 / U:16.108 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site