Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Feb 2025 11:48:23 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: 2868776c9c6f - main - sound: Update comment and channel insertion in vchan_create()
Message-ID:  <202502251148.51PBmNnu051167@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=2868776c9c6f5313a5676786f642b766f103d780

commit 2868776c9c6f5313a5676786f642b766f103d780
Author:     Christos Margiolis <christos@FreeBSD.org>
AuthorDate: 2025-02-25 11:44:30 +0000
Commit:     Christos Margiolis <christos@FreeBSD.org>
CommitDate: 2025-02-25 11:44:30 +0000

    sound: Update comment and channel insertion in vchan_create()
    
    The comment and rationale behind choosing CHN_INSERT_SORT_DESCEND()
    instead of CHN_INSERT_SORT_ASCEND() are no longer relevant as of FILLME
    ("sound: Allocate vchans on-demand").
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      1 week
    Differential Revision:  https://reviews.freebsd.org/D48962
---
 sys/dev/sound/pcm/vchan.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/sys/dev/sound/pcm/vchan.c b/sys/dev/sound/pcm/vchan.c
index 45f0a8b00bd2..27739fe68852 100644
--- a/sys/dev/sound/pcm/vchan.c
+++ b/sys/dev/sound/pcm/vchan.c
@@ -644,12 +644,7 @@ vchan_create(struct pcm_channel *parent, struct pcm_channel **child)
 	PCM_UNLOCK(d);
 
 	CHN_LOCK(parent);
-	/*
-	 * Add us to our parent channel's children in reverse order
-	 * so future destruction will pick the last (biggest number)
-	 * channel.
-	 */
-	CHN_INSERT_SORT_DESCEND(parent, ch, children);
+	CHN_INSERT_SORT_ASCEND(parent, ch, children);
 
 	*child = ch;
 



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