NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: kern/57649: Uninitialized lock in gus.c
The following reply was made to PR kern/57649; it has been noted by GNATS.
From: Taylor R Campbell <riastradh%NetBSD.org@localhost>
To: Harold Gutch <logix%foobar.franken.de@localhost>
Cc: gnats-bugs%NetBSD.org@localhost
Subject: Re: kern/57649: Uninitialized lock in gus.c
Date: Tue, 10 Oct 2023 00:12:40 +0000
I think this can't be right.
sc->sc_lock and sc->sc_intr_lock appear to be totally unused. We
should just flush them, and delete the bogus
sc->sc_lock = sc->sc_codec.sc_ad1848.sc_lock;
sc->sc_intr_lock = sc->sc_codec.sc_ad1848.sc_intr_lock;
initalization, which has never made sense.
The real mutexes, returned by .get_locks = ad1848_get_locks, are
already initialized by ad1848_init_locks when gusattach calls that
early on.
So why are they uninitialized? Not sure! Maybe something is trying
to use sc->sc_mixer and sc->sc_codec (which are in a union) at the
same time and things are stomping all over each other? Time to printf
all the things?
Home |
Main Index |
Thread Index |
Old Index