[PATCHv3 4/4] nvme: use return value from blk_execute_rq()

Keith Busch kbusch at kernel.org
Mon Jun 7 09:58:27 PDT 2021


On Mon, May 24, 2021 at 10:04:28AM +0200, Christoph Hellwig wrote:
> > @@ -168,7 +167,8 @@ static void nvmet_passthru_execute_cmd_work(struct work_struct *w)
> >  			nvmet_passthru_override_id_ns(req);
> >  			break;
> >  		}
> > -	}
> > +	} else if (status < 0)
> > +		status = NVME_SC_INTERNAL;
> 
> Don't we need a better translation here?

Did you have something in mind? I couldn't think of anything more
appropriate than the generic internal error. The errno's we get here are
-EINTR or -EIO. Both indicate we can't communicate with the back-end
device, but these problems are internal to the target from the host's
perspective.



More information about the Linux-nvme mailing list