From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Zdenek Kabelac <zkabelac@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Len Brown <lenb@kernel.org>,
Linux ACPI <linux-acpi@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: Acpi deadlocks with 3.7.0-rc4
Date: Thu, 29 Nov 2012 17:59:59 +0100 [thread overview]
Message-ID: <3859273.SNWgJH0Fv3@vostro.rjw.lan> (raw)
In-Reply-To: <50B75488.3090904@redhat.com>
On Thursday, November 29, 2012 01:26:48 PM Zdenek Kabelac wrote:
> Dne 29.11.2012 11:59, Rafael J. Wysocki napsal(a):
> > On Thursday, November 29, 2012 11:13:10 AM Zdenek Kabelac wrote:
> >> Dne 28.11.2012 20:07, Linus Torvalds napsal(a):
> >>> whole "prefix_node" pointer is bogus. It seems to have the value 0x1000.
> >>
> >> Tested also this patch with this result:
> >>
> >> https://bugzilla.kernel.org/show_bug.cgi?id=51071#c8
> >>
> >> So while it's made it pass suspend/resume, it's not really usable
> >> as docking then.
> >
> > This just makes acpi_ns_lookup() always return acpi_gbl_root_node
> > for things looked up by acpi_ns_get_node() as far as I can say.
> >
> > Hmm.
> >
> > If my theory correct, the patch below should catch the bug. Can you please
> > test it?
> >
>
> Ok now crashing right after 'undock' button press:
>
> https://bugzilla.kernel.org/show_bug.cgi?id=51071#c10
And that's because I made a mistake in the patch. We're currently testing
the appended one and it's showing that the added WARN_ON_ONCE() actually
triggers, so the theory appears to be correct.
I think we can debug this further in the Bugzilla.
Thanks,
Rafael
---
drivers/acpi/scan.c | 2 ++
drivers/pnp/pnpacpi/rsparser.c | 3 +++
2 files changed, 5 insertions(+)
Index: linux/drivers/acpi/scan.c
===================================================================
--- linux.orig/drivers/acpi/scan.c
+++ linux/drivers/acpi/scan.c
@@ -707,6 +707,8 @@ static void acpi_device_unregister(struc
acpi_device_remove_files(device);
device_unregister(&device->dev);
+
+ device->handle = ERR_PTR(-ENODEV);
}
/* --------------------------------------------------------------------------
Index: linux/drivers/pnp/pnpacpi/rsparser.c
===================================================================
--- linux.orig/drivers/pnp/pnpacpi/rsparser.c
+++ linux/drivers/pnp/pnpacpi/rsparser.c
@@ -611,6 +611,9 @@ int pnpacpi_build_resource_template(stru
int res_cnt = 0;
acpi_status status;
+ if (WARN_ON_ONCE(IS_ERR(handle)))
+ return PTR_ERR(handle);
+
status = acpi_walk_resources(handle, METHOD_NAME__CRS,
pnpacpi_count_resources, &res_cnt);
if (ACPI_FAILURE(status)) {
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
next prev parent reply other threads:[~2012-11-29 16:59 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <50A513A8.9010404@redhat.com>
2012-11-28 16:01 ` Acpi deadlocks with 3.7.0-rc4 Linus Torvalds
2012-11-28 16:21 ` Zdenek Kabelac
2012-11-28 17:02 ` Linus Torvalds
2012-11-28 17:27 ` Zdenek Kabelac
2012-11-28 19:07 ` Linus Torvalds
2012-11-28 20:05 ` Rafael J. Wysocki
2012-11-29 10:13 ` Zdenek Kabelac
2012-11-29 10:59 ` Rafael J. Wysocki
2012-11-29 12:26 ` Zdenek Kabelac
2012-11-29 16:59 ` Rafael J. Wysocki [this message]
2012-11-28 20:31 ` Rafael J. Wysocki
2012-11-29 9:03 ` Zdenek Kabelac
2012-11-29 10:09 ` Rafael J. Wysocki
2012-11-28 18:35 ` Rafael J. Wysocki
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=3859273.SNWgJH0Fv3@vostro.rjw.lan \
--to=rjw@sisk.pl \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
--cc=zkabelac@redhat.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