summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/ic/mpi.c3
-rw-r--r--sys/dev/pci/mpi_pci.c5
2 files changed, 3 insertions, 5 deletions
diff --git a/sys/dev/ic/mpi.c b/sys/dev/ic/mpi.c
index a2030df2c01..7be91c8cf7f 100644
--- a/sys/dev/ic/mpi.c
+++ b/sys/dev/ic/mpi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpi.c,v 1.105 2008/11/18 21:52:39 marco Exp $ */
+/* $OpenBSD: mpi.c,v 1.106 2008/11/23 12:45:11 dlg Exp $ */
/*
* Copyright (c) 2005, 2006 David Gwynne <dlg@openbsd.org>
@@ -160,7 +160,6 @@ void mpi_refresh_sensors(void *);
#define DEVNAME(s) ((s)->sc_dev.dv_xname)
#define dwordsof(s) (sizeof(s) / sizeof(u_int32_t))
-#define sizeofa(s) (sizeof(s) / sizeof((s)[0]))
#define mpi_read_db(s) mpi_read((s), MPI_DOORBELL)
#define mpi_write_db(s, v) mpi_write((s), MPI_DOORBELL, (v))
diff --git a/sys/dev/pci/mpi_pci.c b/sys/dev/pci/mpi_pci.c
index 768863cf1d6..844f7ee63c9 100644
--- a/sys/dev/pci/mpi_pci.c
+++ b/sys/dev/pci/mpi_pci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpi_pci.c,v 1.22 2008/10/28 13:44:33 marco Exp $ */
+/* $OpenBSD: mpi_pci.c,v 1.23 2008/11/23 12:45:11 dlg Exp $ */
/*
* Copyright (c) 2005 David Gwynne <dlg@openbsd.org>
@@ -92,8 +92,7 @@ static const struct pci_matchid mpi_devices[] = {
int
mpi_pci_match(struct device *parent, void *match, void *aux)
{
- return (pci_matchbyid((struct pci_attach_args *)aux, mpi_devices,
- sizeof(mpi_devices) / sizeof(mpi_devices[0])));
+ return (pci_matchbyid(aux, mpi_devices, nitems(mpi_devices)));
}
void