From: Holger Macht <hmacht@suse.de>
To: Shaohua Li <shaohua.li@intel.com>
Cc: linux acpi <linux-acpi@vger.kernel.org>,
Len Brown <lenb@kernel.org>, Andi Kleen <andi@firstfloor.org>,
Henrique de Moraes Holschuh <hmh@hmh.eng.br>,
mjg59 <mjg59@srcf.ucam.org>, Tejun Heo <htejun@gmail.com>
Subject: Re: [patch 1/11]avoid check _STA method
Date: Tue, 11 Nov 2008 13:17:34 +0100 [thread overview]
Message-ID: <20081111121734.GB32066@homac.suse.de> (raw)
In-Reply-To: <20080926010459.GA28382@sli10-desk.sh.intel.com>
On Fri 26. Sep - 09:04:59, Shaohua Li wrote:
> On Thu, Sep 25, 2008 at 10:49:45PM +0800, Holger Macht wrote:
> > On Wed 24. Sep - 10:51:05, Shaohua Li wrote:
> > > On Mon, 2008-09-22 at 18:57 +0800, Holger Macht wrote:
> > > > On Thu 28. Aug - 10:02:03, Shaohua Li wrote:
> > > > > In some BIOSes, every _STA method call will send a notification again,
> > > > > this cause freeze. And in some BIOSes, it appears _STA should be called
> > > > > after _DCK. This tries to avoid calls _STA, and still keep the device
> > > > > present check.
> > > > > http://bugzilla.kernel.org/show_bug.cgi?id=10431
> > > >
> > > > Finally found some time to test this...
> > > >
> > > > >
> > > > > Signed-off-by: Shaohua Li <shaohua.li@intel.com>
> > > > > ---
> > > > > drivers/acpi/dock.c | 5 ++++-
> > > > > 1 file changed, 4 insertions(+), 1 deletion(-)
> > > > >
> > > > > Index: linux/drivers/acpi/dock.c
> > > > > ===================================================================
> > > > > --- linux.orig/drivers/acpi/dock.c 2008-08-27 14:38:44.000000000 +0800
> > > > > +++ linux/drivers/acpi/dock.c 2008-08-28 09:33:02.000000000 +0800
> > > > > @@ -604,14 +604,17 @@ static int handle_eject_request(struct d
> > > > > static void dock_notify(acpi_handle handle, u32 event, void *data)
> > > > > {
> > > > > struct dock_station *ds = data;
> > > > > + struct acpi_device *tmp;
> > > > >
> > > > > switch (event) {
> > > > > case ACPI_NOTIFY_BUS_CHECK:
> > > > > - if (!dock_in_progress(ds) && dock_present(ds)) {
> > > > > + if (!dock_in_progress(ds) && acpi_bus_get_device(ds->handle,
> > > >
> > > > On the Thinkpad X60, when booting undocked, the first time I dock,
> > > > acpi_bus_get_device() returns 0, so hotplug is not performed
> > > > properly. Second time (undock->dock), it works.
> > > So the patch breaks your X60? acpi_bus_get_device() returns 0 means the
> > > device is already in ACPI device tree, but it shouldn't as it's not
> > > present.
> >
> > Do you have a model number of a system which needs this patch? If so,
> > maybe I could get my hands on one to do some more testing...maybe finding
> > another solution...
> please see the bugzilla above. I haven't a system which requires this at hand.
> I'm quite strange why acpi_bus_get_device() returns 0 for a non-present device,
> maybe you can dig into this. Is it possible the BIOS wrongly reported device
> status?
No, it was a bug in the acpi subsystem:
commit 39a0ad871000d2a016a4fa113a6e53d22aabf25d
Author: Zhao Yakui <yakui.zhao@intel.com>
Date: Mon Aug 11 13:40:22 2008 +0800
ACPI : Load device driver according to the status of acpi device
Regards,
Holger
next prev parent reply other threads:[~2008-11-11 12:17 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-28 2:02 [patch 1/11]avoid check _STA method Shaohua Li
2008-08-29 15:19 ` Thomas Renninger
2008-09-22 10:57 ` Holger Macht
2008-09-24 2:51 ` Shaohua Li
2008-09-24 12:17 ` Holger Macht
2008-09-25 14:49 ` Holger Macht
2008-09-26 1:04 ` Shaohua Li
2008-11-11 12:17 ` Holger Macht [this message]
2008-09-24 3:38 ` Len Brown
-- strict thread matches above, loose matches on Subject: below --
2008-08-27 3:14 Shaohua Li
2008-08-27 7:53 ` Andi Kleen
2008-08-27 8:24 ` Li, Shaohua
2008-08-27 8:56 ` Andi Kleen
2008-08-27 8:57 ` Alan Jenkins
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=20081111121734.GB32066@homac.suse.de \
--to=hmacht@suse.de \
--cc=andi@firstfloor.org \
--cc=hmh@hmh.eng.br \
--cc=htejun@gmail.com \
--cc=lenb@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=mjg59@srcf.ucam.org \
--cc=shaohua.li@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