Module Name: src
Committed By: tsutsui
Date: Sun Mar 20 10:29:12 UTC 2016
Modified Files:
src/sys/dev/scsipi: atapi_wdc.c
Log Message:
Pass a correct residual size to wdcbit_bucket() that drains extra bytes.
Seems broken (but almost harmless?) since rev 1.101 committed ~10 years ago:
http://mail-index.netbsd.org/source-changes/2006/09/07/0043.html
To generate a diff of this commit:
cvs rdiff -u -r1.120 -r1.121 src/sys/dev/scsipi/atapi_wdc.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/scsipi/atapi_wdc.c
diff -u src/sys/dev/scsipi/atapi_wdc.c:1.120 src/sys/dev/scsipi/atapi_wdc.c:1.121
--- src/sys/dev/scsipi/atapi_wdc.c:1.120 Sun Mar 20 09:47:58 2016
+++ src/sys/dev/scsipi/atapi_wdc.c Sun Mar 20 10:29:12 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: atapi_wdc.c,v 1.120 2016/03/20 09:47:58 tsutsui Exp $ */
+/* $NetBSD: atapi_wdc.c,v 1.121 2016/03/20 10:29:12 tsutsui Exp $ */
/*
* Copyright (c) 1998, 2001 Manuel Bouyer.
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: atapi_wdc.c,v 1.120 2016/03/20 09:47:58 tsutsui Exp $");
+__KERNEL_RCSID(0, "$NetBSD: atapi_wdc.c,v 1.121 2016/03/20 10:29:12 tsutsui Exp $");
#ifndef ATADEBUG
#define ATADEBUG
@@ -930,7 +930,7 @@ again:
end_piobm_datain:
#endif
if (xfer->c_lenoff > 0)
- wdcbit_bucket(chp, len - xfer->c_bcount);
+ wdcbit_bucket(chp, xfer->c_lenoff);
xfer->c_skip += len;
xfer->c_bcount -= len;