git: d325cd4a5302 - stable/14 - sound: Remove dead code in pcm_register()

From: Christos Margiolis <christos_at_FreeBSD.org>
Date: Wed, 10 Jul 2024 16:49:08 UTC
The branch stable/14 has been updated by christos:

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

commit d325cd4a530276cc05167e4a750fd53f32dbf86a
Author:     Christos Margiolis <christos@FreeBSD.org>
AuthorDate: 2024-07-06 18:22:55 +0000
Commit:     Christos Margiolis <christos@FreeBSD.org>
CommitDate: 2024-07-10 16:48:13 +0000

    sound: Remove dead code in pcm_register()
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      2 days
    Differential Revision:  https://reviews.freebsd.org/D45831
    
    (cherry picked from commit a9f08df3e9004f431e98f67afc1ac2b2f773ec14)
---
 sys/dev/sound/pcm/sound.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c
index 8d97dcd60231..b18b83468150 100644
--- a/sys/dev/sound/pcm/sound.c
+++ b/sys/dev/sound/pcm/sound.c
@@ -558,14 +558,7 @@ pcm_register(device_t dev, void *devinfo, int numplay, int numrec)
 	d->lock = snd_mtxcreate(device_get_nameunit(dev), "sound cdev");
 	cv_init(&d->cv, device_get_nameunit(dev));
 	PCM_ACQUIRE_QUICK(d);
-#if 0
-	/*
-	 * d->flags should be cleared by the allocator of the softc.
-	 * We cannot clear this field here because several devices set
-	 * this flag before calling pcm_register().
-	 */
-	d->flags = 0;
-#endif
+
 	i = 0;
 	if (resource_int_value(device_get_name(dev), device_get_unit(dev),
 	    "vpc", &i) != 0 || i != 0)