Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/gpib - fix warnings of printf(9) format and void poi...
details: https://anonhg.NetBSD.org/src/rev/cadc0c3b7bbf
branches: trunk
changeset: 747379:cadc0c3b7bbf
user: tsutsui <tsutsui%NetBSD.org@localhost>
date: Sat Sep 12 18:46:42 2009 +0000
description:
- fix warnings of printf(9) format and void pointer arithmetic
- use DTYPE_HPIB for now instead of nonexistent DTYPE_GPIB
diffstat:
sys/dev/gpib/rd.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diffs (45 lines):
diff -r 75d5902d5ba2 -r cadc0c3b7bbf sys/dev/gpib/rd.c
--- a/sys/dev/gpib/rd.c Sat Sep 12 18:44:36 2009 +0000
+++ b/sys/dev/gpib/rd.c Sat Sep 12 18:46:42 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rd.c,v 1.26 2009/05/12 14:21:58 cegger Exp $ */
+/* $NetBSD: rd.c,v 1.27 2009/09/12 18:46:42 tsutsui Exp $ */
/*-
* Copyright (c) 1996-2003 The NetBSD Foundation, Inc.
@@ -111,7 +111,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rd.c,v 1.26 2009/05/12 14:21:58 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rd.c,v 1.27 2009/09/12 18:46:42 tsutsui Exp $");
#include "rnd.h"
@@ -597,7 +597,7 @@
sc = device_lookup_private(&rd_cd, RDUNIT(bp->b_dev));
DPRINTF(RDB_FOLLOW,
- ("rdstrategy(%p): dev %x, bn %" PRId64 ", bcount %ld, %c\n",
+ ("rdstrategy(%p): dev %" PRIx64 ", bn %" PRId64 ", bcount %d, %c\n",
bp, bp->b_dev, bp->b_blkno, bp->b_bcount,
(bp->b_flags & B_READ) ? 'R' : 'W'));
@@ -1060,7 +1060,7 @@
memset((void *)lp, 0, sizeof(struct disklabel));
- lp->d_type = DTYPE_GPIB;
+ lp->d_type = DTYPE_HPIB /* DTYPE_GPIB */;
lp->d_secsize = DEV_BSIZE;
lp->d_nsectors = rdidentinfo[type].ri_nbpt;
lp->d_ntracks = rdidentinfo[type].ri_ntpc;
@@ -1202,7 +1202,7 @@
/* update block count */
totwrt -= nwrt;
blkno += nwrt;
- va += sectorsize * nwrt;
+ va = (char *)va + sectorsize * nwrt;
}
rddoingadump = 0;
return (0);
Home |
Main Index |
Thread Index |
Old Index