mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sergey Lebedev <lsa.uz@pm.me>
To: Ravindra <ravindra@intel.com>,
	Luiz Augusto von Dentz <luiz.dentz@gmail.com>,
	Marcel Holtmann <marcel@holtmann.org>
Cc: "Vladimir V . Kondratyev" <vladimirkondratyev2@gmail.com>,
	Ferenc Lengyel <dev@lengyelf.eu>,
	Chethan Tumkur Narayan <chethan.tumkur.narayan@intel.com>,
	Paul Menzel <pmenzel@molgen.mpg.de>, Kiran K <kiran.k@intel.com>,
	Chandrashekar Devegowda <chandrashekar.devegowda@intel.com>,
	Mahalingeshwara Chambarakatta
	<mahalingeshwara.chambarakatta@intel.com>,
	Arnd Bergmann <arnd@arndb.de>,
	linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] Bluetooth: btintel_pcie: fix PM flow for S0ix, S3 and S4
Date: Sat, 26 Sep 2026 14:44:59 +0000	[thread overview]
Message-ID: <20260926144451.17188-1-lsa.uz@pm.me> (raw)
In-Reply-To: <IA1PR11MB786927FFF15A4863BB96AB4FDA8F2@IA1PR11MB7869.namprd11.prod.outlook.com>

Ravindra,

Thank you - all four are in. I checked them in the code, with v4 applied
from lore onto 671d566d3c3b and onto e40edfa04, where it lands identically.

Your D3 branch also closes a hole in what I proposed: if the handler's D0
case runs before the controller reaches D3, it breaks without recording
D3, the context stays D0, and the guard in the D0 branch then skips the
re-arm on resume. The bench shows it with and without your branch.

Bench: Surface Pro 11, BE201 8086:a876, the driver at bluetooth-next
e40edfa04 against the same plus v4, one instrumented build each. "HCI ok"
is Read Local Version returning status 0 after the cycle.

  first gp0 on D3 entry dropped, as a missed interrupt (1/4's case)
    stock  timeouts at retries 0, 1 and 2, -EBUSY, suspend aborted,
           HCI fails
    v4     one timeout, D3 recorded from the register, HCI ok (2 of 2)

  handler's D0 case forced to break on suspend
    v4 without the D3 branch   resume skips the re-arm, HCI fails
    v4                         D3 recorded, handler re-arms on resume,
                               HCI ok (2 of 2)

  handler's D3 case forced to break on resume
    stock  success reported with ctxt 6 (D3), then hw exception, FLR,
           0x0c01 tx timeout
    v4     re-armed to ctxt 5 (D0) either way the race falls: handler
           before the wait, 2.2 ms; during it, 208 ms; HCI ok (2 of 2)

  state check forced to fail three times on suspend
    v4     waits=3, none skipped, 413 ms, -EBUSY as forced

  plain s2idle
    v4     D3 in 1.5-1.6 ms, D0 in 1.5-1.7 ms, HCI ok (3 of 3)

  S4, in the kernel's suspend and test_resume hibernation modes
    stock  .thaw goes through FLR
    v4     .freeze: D3_COLD in 1.5-1.8 ms
           .thaw: D0 in 1.6 ms, HCI ok after (2 of 2)
           .restore: FLR, firmware reloaded, HCI ok (2 of 2)

S4 ran on the bench kernel, since the distribution kernel refuses it
under Secure Boot lockdown, and without cutting power, so .poweroff is
not covered. The firmware offers no S3.

After the FLR in .restore the log says "BT reprobe failed", on stock
too; the device probes again about a second later and works.

Tested-by for 4/4 follows in its own thread.

Sergey


  reply	other threads:[~2026-09-26 14:45 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-09 12:34 [PATCH 0/2] Bluetooth: btintel_pcie: two PM fixes, assembled as one series Sergey Lebedev
2026-09-09 12:34 ` [PATCH 1/2] Bluetooth: btintel_pcie: fix stale cache in set_dxstate fallback check Sergey Lebedev
2026-09-09 12:34 ` [PATCH 2/2] Bluetooth: btintel_pcie: fix PM flow for S0ix, S3 and S4 Sergey Lebedev
2026-09-09 18:33   ` Luiz Augusto von Dentz
2026-09-09 20:47     ` Sergey Lebedev
2026-09-20  4:27       ` Ravindra
2026-09-20  7:57         ` Sergey Lebedev
2026-09-23 18:23           ` Ravindra
2026-09-24 19:13             ` Sergey Lebedev
2026-09-26  8:43               ` Ravindra
2026-09-26 14:44                 ` Sergey Lebedev [this message]
2026-09-27 15:17                   ` Ravindra
2026-09-09 18:33 ` Consent for Assembly yCduIhFgkD
2026-09-29 15:10 ` [PATCH 0/2] Bluetooth: btintel_pcie: two PM fixes, assembled as one series patchwork-bot+bluetooth

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=20260926144451.17188-1-lsa.uz@pm.me \
    --to=lsa.uz@pm.me \
    --cc=arnd@arndb.de \
    --cc=chandrashekar.devegowda@intel.com \
    --cc=chethan.tumkur.narayan@intel.com \
    --cc=dev@lengyelf.eu \
    --cc=kiran.k@intel.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luiz.dentz@gmail.com \
    --cc=mahalingeshwara.chambarakatta@intel.com \
    --cc=marcel@holtmann.org \
    --cc=pmenzel@molgen.mpg.de \
    --cc=ravindra@intel.com \
    --cc=vladimirkondratyev2@gmail.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

all inboxes | Powered by JetHome®