Module Name:    src
Committed By:   isaki
Date:           Thu Feb  4 15:06:11 UTC 2021

Modified Files:
        src/sys/arch/hppa/gsc: harmony.c

Log Message:
Fix my mistakes in rev1.6.
- I had to merge the channel bit and the speed bits.
  Reported by macallan@.
- I also fix my indent, while I'm here.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/hppa/gsc/harmony.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/hppa/gsc/harmony.c
diff -u src/sys/arch/hppa/gsc/harmony.c:1.8 src/sys/arch/hppa/gsc/harmony.c:1.9
--- src/sys/arch/hppa/gsc/harmony.c:1.8	Wed Feb  3 15:13:49 2021
+++ src/sys/arch/hppa/gsc/harmony.c	Thu Feb  4 15:06:11 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: harmony.c,v 1.8 2021/02/03 15:13:49 isaki Exp $	*/
+/*	$NetBSD: harmony.c,v 1.9 2021/02/04 15:06:11 isaki Exp $	*/
 
 /*	$OpenBSD: harmony.c,v 1.23 2004/02/13 21:28:19 mickey Exp $	*/
 
@@ -437,7 +437,7 @@ harmony_query_format(void *vsc, audio_fo
 int
 harmony_set_format(void *vsc, int setmode,
     const audio_params_t *play, const audio_params_t *rec,
-	audio_filter_reg_t *pfil, audio_filter_reg_t *rfil)
+    audio_filter_reg_t *pfil, audio_filter_reg_t *rfil)
 {
 	struct harmony_softc *sc;
 	uint32_t bits;
@@ -467,7 +467,8 @@ harmony_set_format(void *vsc, int setmod
 
 	/* XXX modify harmony_speed_bits() not to rewrite rate */
 	rate = play->sample_rate;
-	sc->sc_cntlbits |= harmony_speed_bits(sc, &rate);
+	bits |= harmony_speed_bits(sc, &rate);
+	sc->sc_cntlbits = bits;
 	sc->sc_need_commit = 1;
 
 	return 0;

Reply via email to