linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: "Zheng, Lv" <lv.zheng@intel.com>
Cc: "Moore, Robert" <robert.moore@intel.com>,
	"linux-acpi@vger.kernel.org" <linux-acpi@vger.kernel.org>,
	"devel@acpica.org" <devel@acpica.org>
Subject: Re: [Devel] ACPICA: Resource Mgr: Prevent infinite loops in resource walks
Date: Wed, 23 Oct 2013 12:25:00 +0300	[thread overview]
Message-ID: <20131023092500.GE9378@mwanda> (raw)
In-Reply-To: <1AE640813FDE7649BE1B193DEA596E8802478147@SHSMSX101.ccr.corp.intel.com>

On Wed, Oct 23, 2013 at 06:06:46AM +0000, Zheng, Lv wrote:
> The last resource should always be ACPI_RESOURCE_TYPE_END_TAG and we
> have nsrepair mechanism to ensure that this entry is always there for
> resource based properties (there are still 2 kinds of properties
> haven't been fixed yet).
>
> If we do not want to rely on this logic, then we may need to use
> buffer->length and pass this one to the acpi_rs_get_aml_length to
> avoid potential infinite loop.
> I'll draft an ACPICA patch to achieve the latter.

Actually couldn't we just change the loop to:

	while (resource->type != ACPI_RESOURCE_TYPE_END_TAG) {

That would be my preference (as an ignorant third party).

regards,
dan carpenter


      reply	other threads:[~2013-10-23  9:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-17 12:28 ACPICA: Resource Mgr: Prevent infinite loops in resource walks Dan Carpenter
2013-10-22 21:36 ` Moore, Robert
2013-10-23  6:06   ` [Devel] " Zheng, Lv
2013-10-23  9:25     ` Dan Carpenter [this message]

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=20131023092500.GE9378@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=devel@acpica.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=lv.zheng@intel.com \
    --cc=robert.moore@intel.com \
    /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).