diff options
author | dwmalone <dwmalone@FreeBSD.org> | 2000-12-08 21:51:06 +0000 |
---|---|---|
committer | dwmalone <dwmalone@FreeBSD.org> | 2000-12-08 21:51:06 +0000 |
commit | dd75d1d73b4f3034c1d9f621a49fff58b1d71eb1 (patch) | |
tree | 197ae73617ae75afe008897f6906b84835589ea2 /sys/i386/isa/nmi.c | |
parent | ed5dbfbd3cd619638a7baac288f548aa1398edac (diff) | |
download | FreeBSD-src-dd75d1d73b4f3034c1d9f621a49fff58b1d71eb1.zip FreeBSD-src-dd75d1d73b4f3034c1d9f621a49fff58b1d71eb1.tar.gz |
Convert more malloc+bzero to malloc+M_ZERO.
Submitted by: josh@zipperup.org
Submitted by: Robert Drehmel <robd@gmx.net>
Diffstat (limited to 'sys/i386/isa/nmi.c')
-rw-r--r-- | sys/i386/isa/nmi.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/i386/isa/nmi.c b/sys/i386/isa/nmi.c index ffdcfc4..6f76185 100644 --- a/sys/i386/isa/nmi.c +++ b/sys/i386/isa/nmi.c @@ -546,10 +546,10 @@ inthand_add(const char *name, int irq, driver_intr_t handler, void *arg, if (ithd == NULL || ithd->it_ih == NULL) { /* first handler for this irq. */ if (ithd == NULL) { - ithd = malloc(sizeof (struct ithd), M_DEVBUF, M_WAITOK); + ithd = malloc(sizeof (struct ithd), M_DEVBUF, + M_WAITOK | M_ZERO); if (ithd == NULL) return (NULL); - bzero(ithd, sizeof(struct ithd)); ithd->irq = irq; ithds[irq] = ithd; } @@ -620,10 +620,9 @@ inthand_add(const char *name, int irq, driver_intr_t handler, void *arg, else strcat(p->p_comm, "+"); } - idesc = malloc(sizeof (struct intrhand), M_DEVBUF, M_WAITOK); + idesc = malloc(sizeof (struct intrhand), M_DEVBUF, M_WAITOK | M_ZERO); if (idesc == NULL) return (NULL); - bzero(idesc, sizeof (struct intrhand)); idesc->ih_handler = handler; idesc->ih_argument = arg; |