Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Mar 2002 23:21:13 +1100 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        John Baldwin <jhb@FreeBSD.ORG>
Cc:        Alfred Perlstein <bright@mu.org>, <davidc@FreeBSD.ORG>, <smp@FreeBSD.ORG>
Subject:   RE: select fix and giant pushdown patch
Message-ID:  <20020312231256.V11516-100000@gamplex.bde.org>
In-Reply-To: <XFMail.020311120529.jhb@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 11 Mar 2002, John Baldwin wrote:

> On 11-Mar-02 Alfred Perlstein wrote:
> > Index: dev/kbd/kbd.c
> > ===================================================================
> > RCS file: /home/ncvs/src/sys/dev/kbd/kbd.c,v
> > retrieving revision 1.27
> > diff -u -r1.27 kbd.c
> > --- dev/kbd/kbd.c     12 Sep 2001 08:37:06 -0000      1.27
> > +++ dev/kbd/kbd.c     10 Mar 2002 08:08:36 -0000
> > @@ -524,7 +524,7 @@
> >  #endif
> >       clist_alloc_cblocks(&sc->gkb_q, KB_QSIZE, KB_QSIZE/2); /* XXX */
> >       sc->gkb_rsel.si_flags = 0;
> > -     sc->gkb_rsel.si_pid = 0;
> > +     SEL_INIT(&sc->gkb_rsel);
> >       splx(s);
> >
> >       return 0;
>
> softc's are already zero'd so you don't need this at all.

SEL_INIT() might be magic though.  In practice, it only initializes to
0 and NULL, so it is only needed if the memory is already zero'd on
machines where NULL is not all zeros.  I dislike macros that do trivial
initializations anyway.

Bruce


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-smp" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020312231256.V11516-100000>