public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Fabio Baltieri <fabio.baltieri@linaro.org>
To: Dave Jones <davej@redhat.com>
Cc: Greg KH <gregkh@linuxfoundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	tianyu.lan@intel.com,
	"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
	linux-acpi@vger.kernel.org
Subject: Re: [GIT PATCH] USB patches for 3.9-rc1
Date: Sat, 23 Feb 2013 01:10:55 +0100	[thread overview]
Message-ID: <20130223001055.GA1622@balto.lan> (raw)
In-Reply-To: <20130222222304.GA19546@redhat.com>

On Fri, Feb 22, 2013 at 05:23:04PM -0500, Dave Jones wrote:
> On Fri, Feb 22, 2013 at 10:51:58PM +0100, Fabio Baltieri wrote:
>  > On Fri, Feb 22, 2013 at 03:59:54AM -0500, Dave Jones wrote:
>  > > On Thu, Feb 21, 2013 at 10:40:10AM -0800, Greg KH wrote:
>  > > 
>  > > It looks like every port on my laptop is powered down, as I can't
>  > > even charge devices with it.
>  > 
>  > I have the same problem (and almost the same laptop, Thinkpad T430
>  > here), all external USB ports without power - even the always-on one
>  > :-).
>  > 
>  > The bug seems to be ACPI related, I bisected it down to this patch:
>  > 
>  > f95988d ACPI / scan: Treat power resources in a special way
>  > 
>  > In the dmesg I have some error like these:
>  > 
>  > ACPI: Power Resource [PUBS] (on)
>  > ...
>  > pci 0000:00:14.0: System wakeup disabled by ACPI
>  > 
>  > for the USB controllers in the broken kernel, there are some in your
>  > dmesg too.  I'll try to come up with a fix for current mainline, but all
>  > the acpi stuff is quite obscure to me and the patch does not revert
>  > cleanly, maybe Rafael (in CC) has some idea!
> 
> Good find. I see the same thing.
> 
> [    0.930283] ACPI _OSC control for PCIe not granted, disabling ASPM
> [    0.933527] pci 0000:00:14.0: System wakeup disabled by ACPI
> [    0.935982] pci 0000:00:19.0: System wakeup disabled by ACPI
> [    0.937898] pci 0000:00:1a.0: System wakeup disabled by ACPI
> [    0.939835] pci 0000:00:1b.0: System wakeup disabled by ACPI
> [    0.940700] ACPI: PCI Interrupt Routing Table [\_SB_.PCI0.EXP1._PRT]
> [    0.942195] ACPI: PCI Interrupt Routing Table [\_SB_.PCI0.EXP2._PRT]
> [    0.943737] ACPI: PCI Interrupt Routing Table [\_SB_.PCI0.EXP3._PRT]
> [    0.944564] pci 0000:00:1c.2: System wakeup disabled by ACPI
> [    0.966491] pci 0000:00:1d.0: System wakeup disabled by ACPI
> 
> I must have pulled in the acpi bits the same time as the usb pull,
> because I don't recall seeing this problem before last night.

Definitely.

Well, this did the trick in my case:

--- >8 ---
diff --git a/drivers/acpi/power.c b/drivers/acpi/power.c
index b820528..54175a0 100644
--- a/drivers/acpi/power.c
+++ b/drivers/acpi/power.c
@@ -795,7 +795,7 @@ int acpi_add_power_resource(acpi_handle handle)
        int state, result = -ENODEV;
 
        acpi_bus_get_device(handle, &device);
-       if (device)
+       if (!device)
                return 0;
 
        resource = kzalloc(sizeof(*resource), GFP_KERNEL);
--- >8 ---

But I guess it's working as a coincidence and something else is wrong -
I'll not even try to make a patch out of it and will leave the dirty
work to the ACPI guys instead.

Fabio

-- 
Fabio Baltieri

  reply	other threads:[~2013-02-23  0:11 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20130222085954.GA4352@redhat.com>
2013-02-22 21:51 ` [GIT PATCH] USB patches for 3.9-rc1 Fabio Baltieri
2013-02-22 22:23   ` Dave Jones
2013-02-23  0:10     ` Fabio Baltieri [this message]
2013-02-23  0:35       ` Rafael J. Wysocki
2013-02-23  1:44         ` Fabio Baltieri
2013-02-23  4:33           ` Rafael J. Wysocki
2013-02-23 11:49             ` Fabio Baltieri
2013-02-23 14:18               ` [PATCH] ACPI / PM: Take unusual configurations of power resources into account (was: Re: [GIT PATCH] USB patches for 3.9-rc1) Rafael J. Wysocki
2013-02-23 14:48                 ` Fabio Baltieri
2013-02-23 22:29                   ` Rafael J. Wysocki
2013-02-23  0:20     ` [GIT PATCH] USB patches for 3.9-rc1 Rafael J. Wysocki
2013-02-23  0:19   ` Rafael J. Wysocki
2013-02-23  0:30     ` Linus Torvalds
2013-02-23  0:48       ` Rafael J. Wysocki
2013-02-23  1:10         ` Linus Torvalds
2013-02-23  2:01           ` Rafael J. Wysocki
2013-02-23  1:00   ` 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=20130223001055.GA1622@balto.lan \
    --to=fabio.baltieri@linaro.org \
    --cc=akpm@linux-foundation.org \
    --cc=davej@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=rafael.j.wysocki@intel.com \
    --cc=tianyu.lan@intel.com \
    --cc=torvalds@linux-foundation.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