linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCHv3 09/10] PCI: Unify device inaccessible
       [not found]   ` <e0606dfcf8780bf994432dc373581fdf0af18f8e.camel@kernel.crashing.org>
@ 2025-04-18  3:55     ` Lukas Wunner
  0 siblings, 0 replies; only message in thread
From: Lukas Wunner @ 2025-04-18  3:55 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Keith Busch, Linux PCI, Bjorn Helgaas, Sinan Kaya, Thomas Tai,
	poza, Christoph Hellwig, Mika Westerberg, Mahesh J Salgaonkar,
	Oliver O'Halloran, Madhavan Srinivasan, Michael Ellerman,
	linuxppc-dev

[cc += PowerPC / EEH maintainers]

Hi Ben,

On Tue, Sep 25, 2018 at 11:10:01AM +1000, Benjamin Herrenschmidt wrote:
> On Tue, 2018-09-18 at 17:57 -0600, Keith Busch wrote:
> > + * pci_dev_set_io_state - Set the new error state if possible.
> > + *
> > + * @dev - pci device to set new error_state
> > + * @new - the state we want dev to be in
> > + *
> > + * Must be called with device_lock held.
> 
> Any reason why you don't do cmpxchg as I originally suggested (sorry
> I've been away and may have missed some previous emails)
> 
> This won't work for PowerPC EEH. We will change the state from a
> readl() so at interrupt time or any other context.
> 
> We really need the cmpxchg variant.

Independently from your request, pci_dev_set_io_state() was
converted to cmpxchg() in 2023 with commit 74ff8864cc84
("PCI: hotplug: Allow marking devices as disconnected during
bind/unbind").

So you may now amend EEH to use pcie_do_recovery() or whatever
you needed this for.

I had kept your e-mail in my inbox as a reminder that there's a
remaining issue here and just came across it while clearing out
other messages.

Thanks,

Lukas


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-04-18  4:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20180918235702.26573-1-keith.busch@intel.com>
     [not found] ` <20180918235702.26573-10-keith.busch@intel.com>
     [not found]   ` <e0606dfcf8780bf994432dc373581fdf0af18f8e.camel@kernel.crashing.org>
2025-04-18  3:55     ` [PATCHv3 09/10] PCI: Unify device inaccessible Lukas Wunner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).