Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Oct 2024 08:45:08 GMT
From:      Christos Margiolis <christos@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 0ff0a8234f83 - main - sound: Improve /dev/sndstat channel info readability
Message-ID:  <202410180845.49I8j8Rx088503@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by christos:

URL: https://cgit.FreeBSD.org/src/commit/?id=0ff0a8234f83e6b25e9a2f1b64623baaf723d6dc

commit 0ff0a8234f83e6b25e9a2f1b64623baaf723d6dc
Author:     Christos Margiolis <christos@FreeBSD.org>
AuthorDate: 2024-10-18 08:41:23 +0000
Commit:     Christos Margiolis <christos@FreeBSD.org>
CommitDate: 2024-10-18 08:41:23 +0000

    sound: Improve /dev/sndstat channel info readability
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      2 days
    Reviewed by:    dev_submerge.ch, zlei
    Differential Revision:  https://reviews.freebsd.org/D46857
---
 sys/dev/sound/pcm/sndstat.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/sys/dev/sound/pcm/sndstat.c b/sys/dev/sound/pcm/sndstat.c
index bc51da083439..b20b3f8f6158 100644
--- a/sys/dev/sound/pcm/sndstat.c
+++ b/sys/dev/sound/pcm/sndstat.c
@@ -1280,12 +1280,12 @@ sndstat_prepare_pcm(struct sbuf *s, device_t dev, int verbose)
 		}
 		sbuf_printf(s, "\n\t");
 
-		sbuf_printf(s, "interrupts %d, ", c->interrupts);
+		sbuf_printf(s, "\tinterrupts %d, ", c->interrupts);
 
 		if (c->direction == PCMDIR_REC)	{
 			sbuf_printf(s,
 			    "overruns %d, feed %u, hfree %d, "
-			    "sfree %d [b:%d/%d/%d|bs:%d/%d/%d]",
+			    "sfree %d\n\t\t[b:%d/%d/%d|bs:%d/%d/%d]",
 				c->xruns, c->feedcount,
 				sndbuf_getfree(c->bufhard),
 				sndbuf_getfree(c->bufsoft),
@@ -1298,7 +1298,7 @@ sndstat_prepare_pcm(struct sbuf *s, device_t dev, int verbose)
 		} else {
 			sbuf_printf(s,
 			    "underruns %d, feed %u, ready %d "
-			    "[b:%d/%d/%d|bs:%d/%d/%d]",
+			    "\n\t\t[b:%d/%d/%d|bs:%d/%d/%d]",
 				c->xruns, c->feedcount,
 				sndbuf_getready(c->bufsoft),
 				sndbuf_getsize(c->bufhard),
@@ -1310,14 +1310,14 @@ sndstat_prepare_pcm(struct sbuf *s, device_t dev, int verbose)
 		}
 		sbuf_printf(s, "\n\t");
 
-		sbuf_printf(s, "channel flags=0x%b", c->flags, CHN_F_BITS);
+		sbuf_printf(s, "\tchannel flags=0x%b", c->flags, CHN_F_BITS);
 		sbuf_printf(s, "\n\t");
 
 		if (c->parentchannel != NULL) {
-			sbuf_printf(s, "{%s}", (c->direction == PCMDIR_REC) ?
+			sbuf_printf(s, "\t{%s}", (c->direction == PCMDIR_REC) ?
 			    c->parentchannel->name : "userland");
 		} else {
-			sbuf_printf(s, "{%s}", (c->direction == PCMDIR_REC) ?
+			sbuf_printf(s, "\t{%s}", (c->direction == PCMDIR_REC) ?
 			    "hardware" : "userland");
 		}
 		sbuf_printf(s, " -> ");



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