blobfs: Check fs error info in __do_blob_read

We should check the value of error info. If it
is error, we should not do the read anymore.

Change-Id: Ie3527766779a1f4ed98dde7d9881fe66720badc4
Signed-off-by: Ziye Yang <optimistyzy@gmail.com>
Reviewed-on: https://review.gerrithub.io/420335
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
Ziye Yang 2018-07-25 13:49:02 +08:00 committed by Jim Harris
parent d2e7441edd
commit f4ba32fcda

View File

@ -1555,6 +1555,10 @@ __do_blob_read(void *ctx, int fserrno)
struct spdk_fs_request *req = ctx;
struct spdk_fs_cb_args *args = &req->args;
if (fserrno) {
__rw_done(req, fserrno);
return;
}
spdk_blob_io_read(args->file->blob, args->op.rw.channel,
args->op.rw.pin_buf,
args->op.rw.start_page, args->op.rw.num_pages,