Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/i386/stand/lib Use printf format macros for long lo...
details: https://anonhg.NetBSD.org/src/rev/4647c28faf55
branches: trunk
changeset: 760045:4647c28faf55
user: jakllsch <jakllsch%NetBSD.org@localhost>
date: Sat Dec 25 01:19:33 2010 +0000
description:
Use printf format macros for long longs.
diffstat:
sys/arch/i386/stand/lib/biosdisk.c | 12 ++++++------
sys/arch/i386/stand/lib/biosdisk_ll.c | 4 ++--
sys/arch/i386/stand/lib/bootinfo_biosgeom.c | 4 ++--
3 files changed, 10 insertions(+), 10 deletions(-)
diffs (85 lines):
diff -r df2e2e80fde0 -r 4647c28faf55 sys/arch/i386/stand/lib/biosdisk.c
--- a/sys/arch/i386/stand/lib/biosdisk.c Sat Dec 25 01:08:44 2010 +0000
+++ b/sys/arch/i386/stand/lib/biosdisk.c Sat Dec 25 01:19:33 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: biosdisk.c,v 1.32 2010/12/24 20:36:51 jakllsch Exp $ */
+/* $NetBSD: biosdisk.c,v 1.33 2010/12/25 01:19:33 jakllsch Exp $ */
/*
* Copyright (c) 1996, 1998
@@ -178,7 +178,7 @@
lp = (struct disklabel *) (d->buf + LABELOFFSET);
if (lp->d_magic != DISKMAGIC || dkcksum(lp)) {
#ifdef DISK_DEBUG
- printf("warning: no disklabel in sector %lld\n", sector);
+ printf("warning: no disklabel in sector %"PRId64"\n", sector);
#endif
return -1;
}
@@ -234,7 +234,7 @@
continue;
sector = this_ext + mbr[i].mbrp_start;
#ifdef DISK_DEBUG
- printf("ptn type %d in sector %lld\n", typ, sector);
+ printf("ptn type %d in sector %"PRId64"\n", typ, sector);
#endif
if (typ == MBR_PTYPE_NETBSD) {
error = check_label(d, sector);
@@ -334,10 +334,10 @@
printf(" size ");
size = ed.totsec * ed.sbytes;
if (size >= (10ULL * 1024 * 1024 * 1024))
- printf("%llu GB",
+ printf("%"PRIu64" GB",
size / (1024 * 1024 * 1024));
else
- printf("%llu MB",
+ printf("%"PRIu64" MB",
size / (1024 * 1024));
}
printf("\n");
@@ -386,7 +386,7 @@
int partition = 0;
struct disklabel *lp;
#ifdef DISK_DEBUG
- printf("looking for partition device %x, sector %lld\n", biosdev, sector);
+ printf("looking for partition device %x, sector %"PRId64"\n", biosdev, sector);
#endif
/* Look for netbsd partition that is the dos boot one */
diff -r df2e2e80fde0 -r 4647c28faf55 sys/arch/i386/stand/lib/biosdisk_ll.c
--- a/sys/arch/i386/stand/lib/biosdisk_ll.c Sat Dec 25 01:08:44 2010 +0000
+++ b/sys/arch/i386/stand/lib/biosdisk_ll.c Sat Dec 25 01:19:33 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: biosdisk_ll.c,v 1.27 2010/12/24 20:36:51 jakllsch Exp $ */
+/* $NetBSD: biosdisk_ll.c,v 1.28 2010/12/25 01:19:33 jakllsch Exp $ */
/*-
* Copyright (c) 2005 The NetBSD Foundation, Inc.
@@ -264,7 +264,7 @@
while ((nsec = do_read(d, dblk, maxsecs, trbuf)) < 0) {
#ifdef DISK_DEBUG
if (!cold)
- printf("read error dblk %lld-%lld\n",
+ printf("read error dblk %"PRId64"-%PRId64\n",
dblk, (dblk + maxsecs - 1));
#endif
if (--retries >= 0)
diff -r df2e2e80fde0 -r 4647c28faf55 sys/arch/i386/stand/lib/bootinfo_biosgeom.c
--- a/sys/arch/i386/stand/lib/bootinfo_biosgeom.c Sat Dec 25 01:08:44 2010 +0000
+++ b/sys/arch/i386/stand/lib/bootinfo_biosgeom.c Sat Dec 25 01:19:33 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bootinfo_biosgeom.c,v 1.20 2009/11/20 19:25:37 dsl Exp $ */
+/* $NetBSD: bootinfo_biosgeom.c,v 1.21 2010/12/25 01:19:33 jakllsch Exp $ */
/*
* Copyright (c) 1997
@@ -99,7 +99,7 @@
#ifdef GEOM_DEBUG
printf("#%d: %x: C %d H %d S %d\n", nvalid,
d.dev, d.cyl, d.head, d.sec);
- printf(" sz %d fl %x cyl %d head %d sec %d totsec %lld sbytes %d\n",
+ printf(" sz %d fl %x cyl %d head %d sec %d totsec %"PRId64" sbytes %d\n",
ed.size, ed.flags, ed.cyl, ed.head, ed.sec,
ed.totsec, ed.sbytes);
#endif
Home |
Main Index |
Thread Index |
Old Index