Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/sdmmc Ensure that the task is returned to the free t...
details: https://anonhg.NetBSD.org/src/rev/d17905e5ba37
branches: trunk
changeset: 823419:d17905e5ba37
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Sat Apr 22 14:19:36 2017 +0000
description:
Ensure that the task is returned to the free task list in an error branch.
diffstat:
sys/dev/sdmmc/ld_sdmmc.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diffs (37 lines):
diff -r 8756593cc590 -r d17905e5ba37 sys/dev/sdmmc/ld_sdmmc.c
--- a/sys/dev/sdmmc/ld_sdmmc.c Sat Apr 22 13:26:05 2017 +0000
+++ b/sys/dev/sdmmc/ld_sdmmc.c Sat Apr 22 14:19:36 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ld_sdmmc.c,v 1.25 2017/01/07 16:24:40 martin Exp $ */
+/* $NetBSD: ld_sdmmc.c,v 1.26 2017/04/22 14:19:36 jmcneill Exp $ */
/*
* Copyright (c) 2008 KIYOHARA Takashi
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ld_sdmmc.c,v 1.25 2017/01/07 16:24:40 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ld_sdmmc.c,v 1.26 2017/04/22 14:19:36 jmcneill Exp $");
#ifdef _KERNEL_OPT
#include "opt_sdmmc.h"
@@ -248,8 +248,8 @@
bp->b_rawblkno, sc->sc_sf->csd.capacity);
bp->b_error = EINVAL;
bp->b_resid = bp->b_bcount;
- lddone(&sc->sc_ld, bp);
- return;
+
+ goto done;
}
if (bp->b_flags & B_READ)
@@ -277,6 +277,7 @@
bp->b_resid = 0;
}
+done:
TAILQ_INSERT_TAIL(&sc->sc_freeq, &task->task, next);
lddone(&sc->sc_ld, bp);
Home |
Main Index |
Thread Index |
Old Index