NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/52424 (Panic running usr.bin/mixerctl/t_mixerctl test)



The following reply was made to PR kern/52424; it has been noted by GNATS.

From: Nathanial Sloss <nat%netbsd.org@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: kern-bug-people%netbsd.org@localhost,
 netbsd-bugs%netbsd.org@localhost,
 gnats-admin%netbsd.org@localhost,
 Andreas Gustafsson <gson%gson.org@localhost>
Subject: Re: kern/52424 (Panic running usr.bin/mixerctl/t_mixerctl test)
Date: Mon, 24 Jul 2017 13:26:11 +1000

 --Boundary-00=_TjWdZgu0BDZNi5g
 Content-Type: Text/Plain;
   charset="iso-8859-15"
 Content-Transfer-Encoding: 7bit
 
 Please Try the attached patch to see if it solves the problem.
 
 Best regards,
 
 Nat
 
 
 --Boundary-00=_TjWdZgu0BDZNi5g
 Content-Type: text/x-patch;
   charset="iso-8859-15";
   name="mixerctl_t-audio.diff"
 Content-Transfer-Encoding: 7bit
 Content-Disposition: attachment;
 	filename="mixerctl_t-audio.diff"
 
 Index: src/sys/dev/audio.c
 ===================================================================
 RCS file: /cvsroot/src/sys/dev/audio.c,v
 retrieving revision 1.368
 diff -u -p -r1.368 audio.c
 --- src/sys/dev/audio.c	9 Jul 2017 12:08:39 -0000	1.368
 +++ src/sys/dev/audio.c	24 Jul 2017 03:23:20 -0000
 @@ -5807,6 +5807,9 @@ audio_query_devinfo(struct audio_softc *
  
  	KASSERT(mutex_owned(sc->sc_lock));
  
 +	if (sc->sc_static_nmixer_states == 0 || sc->sc_nmixer_states == 0)
 +		goto hardware;
 +
  	if (di->index >= sc->sc_static_nmixer_states - 1 &&
  	    di->index < sc->sc_nmixer_states) {
  		if (di->index == sc->sc_static_nmixer_states - 1) {
 @@ -5838,7 +5841,7 @@ audio_query_devinfo(struct audio_softc *
  		return 0;
  	}
  
 -
 +hardware:
  	return sc->hw_if->query_devinfo(sc->hw_hdl, di);
  }
  
 
 --Boundary-00=_TjWdZgu0BDZNi5g--
 


Home | Main Index | Thread Index | Old Index