linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Felipe Alfaro Solana <felipe_alfaro@linuxmail.org>
To: acpi-devel@lists.sourceforge.net
Cc: Linux Kernel Mailinglist <linux-kernel@vger.kernel.org>
Subject: about held locks in acpi_psx_execute()
Date: Sun, 30 Nov 2003 22:53:05 +0100	[thread overview]
Message-ID: <1070229185.2183.5.camel@teapot.felipe-alfaro.com> (raw)

Hi!

While looking at drivers/acpi/parser/psxface.c,I have noticed that the
acpi_psx_execute(0 function seems to held some structures referrenced
when an error occurs during its execution:


acpi_status
acpi_psx_execute (
        struct acpi_namespace_node      *method_node,
        union acpi_operand_object       **params,
        union acpi_operand_object       **return_obj_desc)
{
...
        if (params) {
                /*
                 * The caller "owns" the parameters, so give each one an
extra
                 * reference
                 */
                for (i = 0; params[i]; i++) {
                        acpi_ut_add_reference (params[i]);
                }
        }

        /*
         * 1) Perform the first pass parse of the method to enter any
         * named objects that it creates into the namespace
         */
        ACPI_DEBUG_PRINT ((ACPI_DB_PARSE,
                "**** Begin Method Parse **** Entry=%p obj=%p\n",
                method_node, obj_desc));

        /* Create and init a Root Node */

        op = acpi_ps_create_scope_op ();
        if (!op) {
                return_ACPI_STATUS (AE_NO_MEMORY);
        }

As you can see, acpi_psx_execute() will hold a lock for each element of
the params[] array if there's an error while invoking
acpi_ps_create_scope_op(), for example.

Is this intentional?
Thanks!


                 reply	other threads:[~2003-11-30 21:53 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1070229185.2183.5.camel@teapot.felipe-alfaro.com \
    --to=felipe_alfaro@linuxmail.org \
    --cc=acpi-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).