All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] cxl/mailbox: Replace racy error checking with timeouts
@ 2021-12-03 19:28 Dan Williams
  2021-12-03 19:29 ` [PATCH 1/2] cxl/pci: Implement Interface Ready Timeout Dan Williams
  2021-12-03 19:29 ` [PATCH 2/2] cxl/pci: Defer mailbox status checks to command timeouts Dan Williams
  0 siblings, 2 replies; 10+ messages in thread
From: Dan Williams @ 2021-12-03 19:28 UTC (permalink / raw)
  To: linux-cxl
  Cc: Ben Widawsky, ben.widawsky, Jonathan.Cameron, alison.schofield,
	ira.weiny, vishal.l.verma

Quoting patch2:

    Device status can change without warning at any point in time. This
    effectively means that no amount of status checking before a command is
    submitted can guarantee that the device is not in an error condition
    when the command is later submitted. The clearest signal that a device
    is not able to process commands is if it fails to process commands.

So while "cxl/pci: Don't poll doorbell for mailbox access" [1] trimmed
cxl_pci_mbox_get() a bit, it still checks status in racy manner. Just
drop it altogether, add a doorbell sanity check to the initial
mailbox setup, and rely on timeouts to report errors.

Also, in anticipation of a 60s not being enough for device-bringup
scenarios, and a module parameter as an override.

This drops patch 3 [2], replaces patch 5 [3], and adds "cxl/pci: Defer
mailbox status checks to command timeouts" to the "CXL port prep work"
series [4]. Jonathan, given the policy tweaks and addition of a module
parameter I did not carry forward your reviewed-by for "cxl/pci:
Implement Interface Ready Timeout", please have another look when you
get a chance.

[1]: https://lore.kernel.org/r/20211129214721.1668325-6-ben.widawsky@intel.com
[2]: https://lore.kernel.org/r/20211129214721.1668325-4-ben.widawsky@intel.com
[3]: https://lore.kernel.org/r/20211129214721.1668325-6-ben.widawsky@intel.com
[4]: https://lore.kernel.org/r/20211129214721.1668325-1-ben.widawsky@intel.com

---

Ben Widawsky (1):
      cxl/pci: Implement Interface Ready Timeout

Dan Williams (1):
      cxl/pci: Defer mailbox status checks to command timeouts


 drivers/cxl/pci.c |  160 +++++++++++++++++++++--------------------------------
 1 file changed, 64 insertions(+), 96 deletions(-)

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2021-12-06 17:34 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-03 19:28 [PATCH 0/2] cxl/mailbox: Replace racy error checking with timeouts Dan Williams
2021-12-03 19:29 ` [PATCH 1/2] cxl/pci: Implement Interface Ready Timeout Dan Williams
2021-12-04  1:36   ` Ben Widawsky
2021-12-04  2:17     ` Dan Williams
2021-12-06 10:40   ` Jonathan Cameron
2021-12-03 19:29 ` [PATCH 2/2] cxl/pci: Defer mailbox status checks to command timeouts Dan Williams
2021-12-04  1:53   ` Ben Widawsky
2021-12-04  3:23     ` Dan Williams
2021-12-06 10:46   ` Jonathan Cameron
2021-12-06 17:33     ` Dan Williams

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.