Source-Changes-HG archive

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

[src/trunk]: src/sys/dev Add a little more debug printing.



details:   https://anonhg.NetBSD.org/src/rev/809bc540f323
branches:  trunk
changeset: 480709:809bc540f323
user:      augustss <augustss%NetBSD.org@localhost>
date:      Tue Jan 18 18:49:35 2000 +0000

description:
Add a little more debug printing.

diffstat:

 sys/dev/midi.c |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (31 lines):

diff -r 0c3dc43d90a7 -r 809bc540f323 sys/dev/midi.c
--- a/sys/dev/midi.c    Tue Jan 18 18:41:29 2000 +0000
+++ b/sys/dev/midi.c    Tue Jan 18 18:49:35 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: midi.c,v 1.13 1999/10/19 16:04:52 soren Exp $  */
+/*     $NetBSD: midi.c,v 1.14 2000/01/18 18:49:35 augustss Exp $       */
 
 /*
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -235,7 +235,10 @@
                return;
        if (data == MIDI_ACK)
                return;
-       DPRINTFN(3, ("midi_in: %p 0x%02x\n", sc, data));
+
+       DPRINTFN(3, ("midi_in: sc=%p data=0x%02x state=%d pos=%d\n", 
+                    sc, data, sc->in_state, sc->in_pos));
+
        if (!(sc->flags & FREAD))
                return;         /* discard data if not reading */
 
@@ -268,8 +271,7 @@
                                        sc->in_state = MIDI_IN_DATA;
                                        sc->in_msg[0] = sc->in_status = data;
                                        sc->in_pos = 1;
-                                       sc->in_left = 
-                                               MIDI_LENGTH(sc->in_status);
+                                       sc->in_left = MIDI_LENGTH(data);
                                }
                                break;
                        }



Home | Main Index | Thread Index | Old Index