mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alan Stern <stern@rowland.harvard.edu>
To: Paul Menzel <pmenzel@molgen.mpg.de>
Cc: Marcel Holtmann <marcel@holtmann.org>,
	Johan Hedberg <johan.hedberg@gmail.com>,
	Luiz Augusto von Dentz <luiz.dentz@gmail.com>,
	linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-usb@vger.kernel.org, linux-pm@vger.kernel.org,
	Hans de Goede <hdegoede@redhat.com>, Mike Jones <mike@mjones.io>
Subject: Re: Qualcomm Atheros QCA61x4 keeps drawing 0.85 W despite Bluetooth being disable in GNOME
Date: Mon, 20 Nov 2023 13:10:29 -0500	[thread overview]
Message-ID: <41253614-764e-4e95-b052-a46bf5587c29@rowland.harvard.edu> (raw)
In-Reply-To: <de236c7d-e265-452a-a60e-b10293a5b944@molgen.mpg.de>

On Mon, Nov 20, 2023 at 08:52:19AM +0100, Paul Menzel wrote:
> Dear Alan,
> 
> 
> Than you again for your quick reply.
> 
> Am 20.11.23 um 03:26 schrieb Alan Stern:
> > On Sun, Nov 19, 2023 at 11:09:32PM +0100, Paul Menzel wrote:
> > > $ sudo modprobe btusb
> > 
> > > $ grep . /sys/bus/usb/devices/1-3/power/*
> > > /sys/bus/usb/devices/1-3/power/active_duration:119053224
> > > /sys/bus/usb/devices/1-3/power/async:enabled
> > > /sys/bus/usb/devices/1-3/power/autosuspend:2
> > > /sys/bus/usb/devices/1-3/power/autosuspend_delay_ms:2000
> > > /sys/bus/usb/devices/1-3/power/connected_duration:148065372
> > > /sys/bus/usb/devices/1-3/power/control:auto
> > > /sys/bus/usb/devices/1-3/power/level:auto
> > > /sys/bus/usb/devices/1-3/power/persist:1
> > > /sys/bus/usb/devices/1-3/power/runtime_active_kids:0
> > > /sys/bus/usb/devices/1-3/power/runtime_active_time:119060567
> > > /sys/bus/usb/devices/1-3/power/runtime_enabled:enabled
> > > /sys/bus/usb/devices/1-3/power/runtime_status:active
> > > /sys/bus/usb/devices/1-3/power/runtime_suspended_time:28831453
> > > /sys/bus/usb/devices/1-3/power/runtime_usage:0
> > > /sys/bus/usb/devices/1-3/power/wakeup:disabled
> > > ```
> > 
> > Hmmm.  It's not immediately clear why the device isn't being suspended.
> > The btusb driver does support autosuspend.
> > 
> > Can you also post the output from
> > 
> > 	grep . /sys/bus/usb/devices/1-3:*/power/*
> > 
> > with the driver module loaded?  I should have asked for it before.
> 
> ```
> $ sudo modprobe btusb
> $ sudo dmesg | tail -9
> [319747.390712] r8152 4-1.2:1.0 enx18dbf22dccf3: carrier on
> [320256.946094] bluetooth hci0: firmware: direct-loading firmware
> qca/rampatch_usb_00000302.bin
> [320256.949333] Bluetooth: hci0: using rampatch file:
> qca/rampatch_usb_00000302.bin
> [320256.949349] Bluetooth: hci0: QCA: patch rome 0x302 build 0x3e8, firmware
> rome 0x302 build 0x111
> [320256.949643] usbcore: registered new interface driver btusb
> [320257.308935] bluetooth hci0: firmware: direct-loading firmware
> qca/nvm_usb_00000302.bin
> [320257.309043] Bluetooth: hci0: using NVM file: qca/nvm_usb_00000302.bin
> [320257.336220] Bluetooth: hci0: HCI Enhanced Setup Synchronous Connection
> command is advertised, but not supported.
> [320257.638188] Bluetooth: MGMT ver 1.22
> $ /sbin/rfkill
> ID TYPE      DEVICE    SOFT      HARD
>  1 wlan      phy0   blocked unblocked
> 28 bluetooth hci0   blocked unblocked
> $ grep . /sys/bus/usb/devices/1-3:*/power/*
> /sys/bus/usb/devices/1-3:1.0/power/async:enabled
> /sys/bus/usb/devices/1-3:1.0/power/runtime_active_kids:0
> /sys/bus/usb/devices/1-3:1.0/power/runtime_enabled:enabled
> /sys/bus/usb/devices/1-3:1.0/power/runtime_status:suspended
> /sys/bus/usb/devices/1-3:1.0/power/runtime_usage:0
> /sys/bus/usb/devices/1-3:1.1/power/async:enabled
> /sys/bus/usb/devices/1-3:1.1/power/runtime_active_kids:0
> /sys/bus/usb/devices/1-3:1.1/power/runtime_enabled:enabled
> /sys/bus/usb/devices/1-3:1.1/power/runtime_status:suspended
> /sys/bus/usb/devices/1-3:1.1/power/runtime_usage:0
> ```

Again, nothing out of the ordinary.  Maybe dynamic debugging will give 
us a clue.  Try doing this:

	Unload the btusb module.

	echo module usbcore +p >/sys/kernel/debug/dynamic_debug/control

	Load the btusb module

	Make sure that Bluetooth is turned off in Gnome

	Wait a few seconds

	echo module usbcore -p >/sys/kernel/debug/dynamic_debug/control

Then let's see what the dmesg log contains for that time period.

Also, please post the output from "lsusb -v" for the Bluetooth device.

Alan Stern

  reply	other threads:[~2023-11-20 18:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-19 13:40 Qulcomm " Paul Menzel
2023-11-19 13:42 ` Qualcomm " Paul Menzel
2023-11-19 15:43   ` Alan Stern
2023-11-19 22:09     ` Paul Menzel
2023-11-20  2:26       ` Alan Stern
2023-11-20  7:52         ` Paul Menzel
2023-11-20 18:10           ` Alan Stern [this message]
2023-11-20 22:05             ` Paul Menzel
2023-11-21 16:23               ` Alan Stern
2023-11-21 17:12                 ` Paul Menzel
2023-11-21 17:40                   ` Alan Stern
2023-11-21 20:02                     ` Paul Menzel
2023-11-19 14:35 ` Qulcomm " Greg KH

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=41253614-764e-4e95-b052-a46bf5587c29@rowland.harvard.edu \
    --to=stern@rowland.harvard.edu \
    --cc=hdegoede@redhat.com \
    --cc=johan.hedberg@gmail.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=luiz.dentz@gmail.com \
    --cc=marcel@holtmann.org \
    --cc=mike@mjones.io \
    --cc=pmenzel@molgen.mpg.de \
    /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

all inboxes | Powered by JetHome®