From nobody Wed Nov 18 10:24:42 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4jTyQL6vzgz71JHN for ; Wed, 18 Nov 2026 10:24:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4jTyQL2RwPz4fmM for ; Wed, 18 Nov 2026 10:24:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1794997482; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/NsZdYO7kyYPo86/tY0JKYTea7UgQ3vOw4rxTGhRWO8=; b=hFYAbnuk8N/DCyJgf4n6t0D4aAFRzD4YwOUXa7sxo4ofMcId9pqvm+EiKrM60bXk8nsJ1b jZd+7/8qaK4t7moeYPd+0ugvU2IRMZFLPe/J0SCS1rwSdkBhcIrHzB8m6/mcghUaJXWVhF 13TTb0E1wUoXq1HqjvM9yR2SIN0KEeaIIhXKPdXLXu+YANb5b70KhARXAk+1gqx342RQUG qcbS/LFEDWDR644LU5VYGZZTHvd8yFOob9qxa/xJ0NSfX/Xs9OGDRAZR49cCoCIk/QI/5e e5mCQIHZGwTfEUY2xIXEyXrfbhH7qyCCwbEzBWTwOFJfFvPU75iOixKnh6BVSA== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1794997482; b=oEBZGqXczKSj9MSdIS2hI5ybTizgL3AQzZRQKXIjvozCAd1vs/3Cn7tpqfCNxvLyVcwc91 ditZqcqafPYdC06TkhfV4AXRpEKublLEVOGL4WA2UYQfSpTHjrKJPmCJccrLBOTRw3F1aN R5qiJP/pfVjiLFtfz14lQc8SAJyz3hRqdG9sSf01ih21qqDmtqdBI/PjzcbEpwCAaViWcE tTMdFWbUswC/aO3iWQeFMQH4YkoU/2RPD8ezs2Lc5rQtAknU7IqTpgvDI74UdB4muNirlE Q9hcKf69FtUSaqFWcPYKStu6VOMqADAMh/QDL89aLQjZhwhJIE6n2/Hnw3zfFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1794997482; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=/NsZdYO7kyYPo86/tY0JKYTea7UgQ3vOw4rxTGhRWO8=; b=Vri5tCQbXcPo78J/m/UbzeQjaFmSVbgnjOvl2e3E4xn5pM2iD0Ye30XkgvgCjl/gY+TQUQ LqwJxNBu79SwzkD0D2Ru1LZllgZLeZnq7qBZfxZwHYHfNYDfYJKRbxnFlHWD/NjJ46JTT+ 7IAVA+N35+oIEsBBFVJgXi5LJksgLd3sDQVQkpTu0/6ZrK1f/5DgRT2YGgzgOm5+4GfYC0 DsKUwwgInGeBbdPOklD6TpOTUmlBCuFt2Sw6xPLBL8RgjlrYTBHCXwk9Ru9rMY5mzH66qs lr7SItWcABsJyhClzkMHsbFKLX7xSpUpbx/SQmtilcaqGymKeJsdXKh4OOz0wA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4jTyQL1PjYz1Np1 for ; Wed, 18 Nov 2026 10:24:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3f7a by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Wed, 18 Nov 2026 10:24:42 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Christos Margiolis Subject: git: 6417651b4a9b - main - sound: Retire PCM_LOCK in sound_oss_card_info() List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all X-BeenThere: dev-commits-src-all@freebsd.org List-Id: Commit messages for all branches of the src repository List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: christos X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6417651b4a9bb84b3052a60d2966ea9c9ecb9499 Auto-Submitted: auto-generated Date: Wed, 18 Nov 2026 10:24:42 +0000 Message-Id: <6afd7cea.3f7a.67d2d68@gitrepo.freebsd.org> The branch main has been updated by christos: URL: https://cgit.FreeBSD.org/src/commit/?id=6417651b4a9bb84b3052a60d2966ea9c9ecb9499 commit 6417651b4a9bb84b3052a60d2966ea9c9ecb9499 Author: Christos Margiolis AuthorDate: 2026-11-18 10:21:50 +0000 Commit: Christos Margiolis CommitDate: 2026-11-18 10:21:50 +0000 sound: Retire PCM_LOCK in sound_oss_card_info() The handler reads the device name, its description and the status string. All three are set before pcm_register() makes the device visible, and never change afterwards. The topology lock, which is held across the whole function, makes sure the device is not freed. MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D60515 --- sys/dev/sound/pcm/sound.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index 267d48f79ad9..65b43a66d758 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -614,17 +614,12 @@ sound_oss_card_info(oss_card_info *si) si->hw_info[0] = '\0'; si->intr_count = si->ack_count = 0; } else { - PCM_UNLOCKASSERT(d); - PCM_LOCK(d); - strlcpy(si->shortname, device_get_nameunit(d->dev), sizeof(si->shortname)); strlcpy(si->longname, device_get_desc(d->dev), sizeof(si->longname)); strlcpy(si->hw_info, d->status, sizeof(si->hw_info)); si->intr_count = si->ack_count = 0; - - PCM_UNLOCK(d); } bus_topo_unlock();