Skip to content

cxl/mbox: Robustify handling of mbox_cmd.return_code

Davidlohr Bueso linux-cxl 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest4 patches 1 replyIn review
  2. v15 patches 12 repliesApplied

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4cxl/mbox: Drop mbox_mutex commentdrivers/cxl/core/mbox.c+1 -10 replies
2/4cxl/pci: Use CXL_MBOX_SUCCESS to check against mbox_cmd return codedrivers/cxl/pci.c+2 -20 replies
3/4cxl/mbox: Improve handling of mbox_cmd hw return codesdrivers/cxl/core/mbox.c drivers/cxl/cxlmem.h drivers/cxl/pci.c+54 -30 replies
4/4cxl/mbox: Use new return_code handlingdrivers/cxl/core/mbox.c drivers/cxl/pci.c+3 -30 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/4] cxl/mbox: Robustify handling of mbox_cmd.return_code

Hi,

Changes from v1 (https://lore.kernel.org/all/[email protected]/):
- Patch 1 now just removes the lock comment, instead of moving it. (Dan)
- Modified pach 3 to use CPP hackery + misc table improvements. (Dan and Adam)
- Dropped patch 5 per concerns about implications with FW. (Dan)
- Picked up Adam's review tags.

Currently the return_code from a completed mbox command is handled as either successful or not. This series teaches the driver to better deal with the different returns from the hardware, allowing better debugging and mapping to proper kernel errno semantics (which are left unchanged for now) as well as more ad-hoc handling.

Applies against linux-cxl's next branch.

Patches 1 and 2 are small nits.
Patch 3 and 4 implement and use the new calls.

Thanks!

Davidlohr Bueso (4):
cxl/mbox: Drop mbox_mutex comment
cxl/pci: Use CXL_MBOX_SUCCESS to check against mbox_cmd return code cxl/mbox: Improve handling of mbox_cmd hw return codes cxl/mbox: Use new return_code handling

 drivers/cxl/core/mbox.c |  7 +++---
 drivers/cxl/cxlmem.h    | 53 ++++++++++++++++++++++++++++++++++++++++-
 drivers/cxl/pci.c       |  7 +++---
 3 files changed, 59 insertions(+), 8 deletions(-)

--
2.26.2