[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] minios (blkfront): Add more information on block error
commit 8bdd98744d678fc1ff8c7462c088e9fdee055ca2 Author: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx> AuthorDate: Thu Mar 20 13:10:22 2014 +0100 Commit: Ian Campbell <ian.campbell@xxxxxxxxxx> CommitDate: Fri Mar 21 11:49:23 2014 +0000 minios (blkfront): Add more information on block error This notably prints the offset and size of the block operation in error. Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxxxxxx> Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx> --- extras/mini-os/blkfront.c | 18 ++++++++++++++---- 1 files changed, 14 insertions(+), 4 deletions(-) diff --git a/extras/mini-os/blkfront.c b/extras/mini-os/blkfront.c index 62a32c5..59e576f 100644 --- a/extras/mini-os/blkfront.c +++ b/extras/mini-os/blkfront.c @@ -509,15 +509,19 @@ moretodo: aiocbp = (void*) (uintptr_t) rsp->id; status = rsp->status; - if (status != BLKIF_RSP_OKAY) - printk("block error %d for op %d\n", status, rsp->operation); - switch (rsp->operation) { case BLKIF_OP_READ: case BLKIF_OP_WRITE: { int j; + if (status != BLKIF_RSP_OKAY) + printk("%s error %d on %s at offset %llu, num bytes %llu\n", + rsp->operation == BLKIF_OP_READ?"read":"write", + status, aiocbp->aio_dev->nodename, + (unsigned long long) aiocbp->aio_offset, + (unsigned long long) aiocbp->aio_nbytes); + for (j = 0; j < aiocbp->n; j++) gnttab_end_access(aiocbp->gref[j]); @@ -525,11 +529,17 @@ moretodo: } case BLKIF_OP_WRITE_BARRIER: + if (status != BLKIF_RSP_OKAY) + printk("write barrier error %d\n", status); + break; case BLKIF_OP_FLUSH_DISKCACHE: + if (status != BLKIF_RSP_OKAY) + printk("flush error %d\n", status); break; default: - printk("unrecognized block operation %d response\n", rsp->operation); + printk("unrecognized block operation %d response (status %d)\n", rsp->operation, status); + break; } dev->ring.rsp_cons = ++cons; -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |