On Thu, Aug 13 2020 at 11:36am -0400, Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote: > On Thu, Aug 13, 2020 at 10:48:11AM -0400, Mike Snitzer wrote: > > Commit 764e9332098c0 ("nvme-multipath: do not reset on unknown > > status"), among other things, fixed NVME_SC_CMD_INTERRUPTED error > > handling by changing multipathing's nvme_failover_req() to short-circuit > > path failover and then fallback to NVMe's normal error handling (which > > takes care of NVME_SC_CMD_INTERRUPTED). > > > > This detour through native NVMe multipathing code is unwelcome because > > it prevents NVMe core from handling NVME_SC_CMD_INTERRUPTED independent > > of any multipathing concerns. > > > > Introduce nvme_status_needs_local_error_handling() to prioritize > > non-failover retry, when appropriate, in terms of normal NVMe error > > handling. nvme_status_needs_local_error_handling() will naturely evolve > > to include handling of any other errors that normal error handling must > > be used for. > > > > nvme_failover_req()'s ability to fallback to normal NVMe error handling > > has been preserved because it may be useful for future NVME_SC that > > nvme_status_needs_local_error_handling() hasn't been trained for yet. > > > > Signed-off-by: Mike Snitzer <snitzer@xxxxxxxxxx> > > I don't see how this would change anything. nvme_failover_req simply > retuns false for NVME_SC_CMD_INTERRUPTED, so your change is a no-op. This is just a tweak to improve the high-level fault tree of core NVMe error handling. No functional change, but for such basic errors, avoiding entering nvme_failover_req is meaningful on a code flow level. Makes code to handle errors that need local retry clearer by being more structured, less circuitous. Allows NVMe core's handling of such errors to be more explicit and live in core.c rather than multipath.c -- so things like ACRE handling can be made explicitly part of core and not nested under nvme_failover_req's relatively obscure failsafe that returns false for anything it doesn't care about. Mike -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel