Module Name: src
Committed By: pooka
Date: Thu Nov 6 01:29:25 UTC 2014
Modified Files:
src/sys/dev/pci: viornd.c
Log Message:
Abort only actually initialized slots.
To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/dev/pci/viornd.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/dev/pci/viornd.c
diff -u src/sys/dev/pci/viornd.c:1.3 src/sys/dev/pci/viornd.c:1.4
--- src/sys/dev/pci/viornd.c:1.3 Thu Nov 6 00:42:18 2014
+++ src/sys/dev/pci/viornd.c Thu Nov 6 01:29:25 2014
@@ -1,4 +1,4 @@
-/* $NetBSD: viornd.c,v 1.3 2014/11/06 00:42:18 pooka Exp $ */
+/* $NetBSD: viornd.c,v 1.4 2014/11/06 01:29:25 pooka Exp $ */
/* $OpenBSD: viornd.c,v 1.1 2014/01/21 21:14:58 sf Exp $ */
/*
@@ -102,10 +102,10 @@ viornd_get(size_t bytes, void *priv)
bus_dmamap_sync(vsc->sc_dmat, sc->sc_dmamap, 0, VIORND_BUFSIZE,
BUS_DMASYNC_PREREAD);
if (virtio_enqueue_prep(vsc, vq, &slot)) {
- virtio_enqueue_abort(vsc, vq, slot);
goto out;
}
if (virtio_enqueue_reserve(vsc, vq, slot, 1)) {
+ virtio_enqueue_abort(vsc, vq, slot);
goto out;
}
virtio_enqueue(vsc, vq, slot, sc->sc_dmamap, 0);