mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Lukas Wunner <lukas@wunner.de>
To: Zhu Qiyu <qiyuzhu2@amd.com>
Cc: Bjorn Helgaas <bhelgaas@google.com>,
	linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] PCI: pciehp: Avoid dropping hotplug interrupts due to stale HPIE
Date: Fri, 25 Sep 2026 20:49:26 +0200	[thread overview]
Message-ID: <arbCNu_Ozv2j_CEv@wunner.de> (raw)
In-Reply-To: <20260925114635.192878-1-qiyuzhu2@amd.com>

On Fri, Sep 25, 2026 at 11:46:35AM +0000, Zhu Qiyu wrote:
> pciehp_isr() uses the Hot-Plug Interrupt Enable (HPIE) bit in
> ctrl->slot_ctrl to reject interrupts when hotplug interrupts are
> disabled.  This check is needed because hotplug can share an interrupt
> with other sources, including native PME.
> 
> However, ctrl->slot_ctrl is updated from hardware on every Slot Control
> Register read-modify-write.  A firmware change to HPIE can race with an
> unrelated driver operation, such as an LED indicator update:

Firmware is not allowed to change the Slot Control Register once it has
granted control of PCI Express Native Hot Plug Control to the operating
system.

From PCIe r3.3 table 4-6 bit 0:

   "Additionally, after control is transferred to the operating system,
    firmware must not update the state of hot plug slots, including the
    state of the indicators and power controller."

Are you seeing this on a real-world system or is it an LLM-generated
hallucination?

If the former, please consider fixing this through a firmware update.

Thanks,

Lukas

  reply	other threads:[~2026-09-25 18:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-24 10:19 [PATCH] PCI: pciehp: Re-read Slot Control when cached HPIE is clear Zhu Qiyu
2026-09-25 11:46 ` [PATCH v2] PCI: pciehp: Avoid dropping hotplug interrupts due to stale HPIE Zhu Qiyu
2026-09-25 18:49   ` Lukas Wunner [this message]
2026-09-25 19:11     ` Lukas Wunner

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=arbCNu_Ozv2j_CEv@wunner.de \
    --to=lukas@wunner.de \
    --cc=bhelgaas@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=qiyuzhu2@amd.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®