summaryrefslogtreecommitdiff
path: root/sys/arch/hppa64
diff options
context:
space:
mode:
authorJasper Lievisse Adriaanse <jasper@cvs.openbsd.org>2010-12-06 18:44:50 +0000
committerJasper Lievisse Adriaanse <jasper@cvs.openbsd.org>2010-12-06 18:44:50 +0000
commitc35b9bdae7316474e01b5a2ba9dcf3631b975901 (patch)
treee2584f7866a69b7d5115c88c8916474d2dc7c70b /sys/arch/hppa64
parentadc400522ede0d3382b10f47167d1652125bd6e6 (diff)
- drop NENTS(), which was yet another copy of nitems().
no binary change ok deraadt@
Diffstat (limited to 'sys/arch/hppa64')
-rw-r--r--sys/arch/hppa64/stand/boot/conf.c6
-rw-r--r--sys/arch/hppa64/stand/cdboot/cdboot.c6
-rw-r--r--sys/arch/hppa64/stand/libsa/cmd_hppa64.c6
-rw-r--r--sys/arch/hppa64/stand/libsa/dev_hppa64.c8
4 files changed, 13 insertions, 13 deletions
diff --git a/sys/arch/hppa64/stand/boot/conf.c b/sys/arch/hppa64/stand/boot/conf.c
index 2dfb1fced8f..29f196a4ff7 100644
--- a/sys/arch/hppa64/stand/boot/conf.c
+++ b/sys/arch/hppa64/stand/boot/conf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: conf.c,v 1.2 2008/04/19 23:20:22 weingart Exp $ */
+/* $OpenBSD: conf.c,v 1.3 2010/12/06 18:44:49 jasper Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -34,14 +34,14 @@ struct fs_ops file_system[] = {
{ lif_open, lif_close, lif_read, lif_write, lif_seek,
lif_stat, lif_readdir },
};
-int nfsys = NENTS(file_system);
+int nfsys = nitems(file_system);
struct devsw devsw[] = {
{ "dk", iodcstrategy, dkopen, dkclose, noioctl },
{ "ct", iodcstrategy, ctopen, ctclose, noioctl },
{ "lf", iodcstrategy, lfopen, lfclose, noioctl }
};
-int ndevs = NENTS(devsw);
+int ndevs = nitems(devsw);
struct consdev constab[] = {
{ ite_probe, ite_init, ite_getc, ite_putc },
diff --git a/sys/arch/hppa64/stand/cdboot/cdboot.c b/sys/arch/hppa64/stand/cdboot/cdboot.c
index 2ceb33315df..82fcb5abae9 100644
--- a/sys/arch/hppa64/stand/cdboot/cdboot.c
+++ b/sys/arch/hppa64/stand/cdboot/cdboot.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cdboot.c,v 1.1 2005/04/01 10:40:48 mickey Exp $ */
+/* $OpenBSD: cdboot.c,v 1.2 2010/12/06 18:44:49 jasper Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -37,12 +37,12 @@ struct fs_ops file_system[] = {
{ cd9660_open, cd9660_close, cd9660_read, cd9660_write, cd9660_seek,
cd9660_stat, cd9660_readdir },
};
-int nfsys = NENTS(file_system);
+int nfsys = nitems(file_system);
struct devsw devsw[] = {
{ "dk", iodcstrategy, dkopen, dkclose, noioctl },
};
-int ndevs = NENTS(devsw);
+int ndevs = nitems(devsw);
struct consdev constab[] = {
{ ite_probe, ite_init, ite_getc, ite_putc },
diff --git a/sys/arch/hppa64/stand/libsa/cmd_hppa64.c b/sys/arch/hppa64/stand/libsa/cmd_hppa64.c
index 1aa6117cb07..d782f5945ff 100644
--- a/sys/arch/hppa64/stand/libsa/cmd_hppa64.c
+++ b/sys/arch/hppa64/stand/libsa/cmd_hppa64.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd_hppa64.c,v 1.1 2005/04/01 10:40:48 mickey Exp $ */
+/* $OpenBSD: cmd_hppa64.c,v 1.2 2010/12/06 18:44:49 jasper Exp $ */
/*
* Copyright (c) 2002 Miodrag Vallat
@@ -337,13 +337,13 @@ set_serial(console, port, arg)
speed = 0;
if (arg == NULL || *arg == '\0') {
- for (i = 0; i < NENTS(i_speeds); i++)
+ for (i = 0; i < nitems(i_speeds); i++)
if (i_speeds[i] == 9600) {
speed = i;
break;
}
} else {
- for (i = 0; i < NENTS(c_speeds); i++)
+ for (i = 0; i < nitems(c_speeds); i++)
if (strcmp(arg, c_speeds[i]) == 0) {
speed = i;
break;
diff --git a/sys/arch/hppa64/stand/libsa/dev_hppa64.c b/sys/arch/hppa64/stand/libsa/dev_hppa64.c
index d081d5dfe12..74d6f51f5e7 100644
--- a/sys/arch/hppa64/stand/libsa/dev_hppa64.c
+++ b/sys/arch/hppa64/stand/libsa/dev_hppa64.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dev_hppa64.c,v 1.2 2005/05/29 18:53:54 miod Exp $ */
+/* $OpenBSD: dev_hppa64.c,v 1.3 2010/12/06 18:44:49 jasper Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -33,7 +33,7 @@ const char cdevs[][4] = {
"ite", "", "", "", "", "", "", "",
"", "", "", "", ""
};
-const int ncdevs = NENTS(cdevs);
+const int ncdevs = nitems(cdevs);
const struct pdc_devs {
char name[3];
@@ -69,11 +69,11 @@ devopen(f, fname, file)
printf("devopen: ");
#endif
- for (dp = pdc_devs; dp < &pdc_devs[NENTS(pdc_devs)]; dp++)
+ for (dp = pdc_devs; dp < &pdc_devs[nitems(pdc_devs)]; dp++)
if (!strncmp(fname, dp->name, sizeof(dp->name)-1))
break;
- if (dp >= &pdc_devs[NENTS(pdc_devs)] || dp->dev_type < 0)
+ if (dp >= &pdc_devs[nitems(pdc_devs)] || dp->dev_type < 0)
return ENODEV;
#ifdef DEBUGBUG
if (debug)