From nobody Mon Dec 13 11:52:28 2021 X-Original-To: dev-commits-src-main@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 6440118E5241; Mon, 13 Dec 2021 11:52:29 +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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JCKcs180hz4hRL; Mon, 13 Dec 2021 11:52:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 075BD142BF; Mon, 13 Dec 2021 11:52:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1BDBqSkk079931; Mon, 13 Dec 2021 11:52:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1BDBqSHo079930; Mon, 13 Dec 2021 11:52:28 GMT (envelope-from git) Date: Mon, 13 Dec 2021 11:52:28 GMT Message-Id: <202112131152.1BDBqSHo079930@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Andriy Gapon Subject: git: 8b37048bc548 - main - Revert "mmc_sim: fix setting of the mutex name" List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: avg X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 8b37048bc5482ffe46404dbe6311f0530d2c150b Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1639396349; 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=dj8omL1wN3qXT7uU5xMmMc56R7Jsrpy8NkZkqNtbsJk=; b=TjbSQ+UKannGZcBLgcPOa8pFxSmjQTTNQLPYdiCr0vM7uhujFs5iz4Q5rgcIvF9XPbEjeb 1SFzBlbuPOPGcfX3+xAuy7+AlFzDtkJfh0LpTw2lNVPbt6KszInCYUAqWao6qirKi/Sjq3 Wvddhptk+n+fdfCEQySHy5U/B/maRRNGv5DlsoEPNHwePfD7BjNePcFoyunavLFfP8z5zJ tlRebDi3yl4LYnbkV3Yx7byQjUD5h05Gbl0GLheDYeHCF/cak9IdwJsOqvgWeHg/lQnqDE ouvSSRvCkVlJ0kyxjTTVNyvSSCv7YuoP+l0TWvcU++N7/TeDBJ9PbQjySr2srg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1639396349; a=rsa-sha256; cv=none; b=cSwzrSWyPgPf+RZGrd63UsJtwA09oZ6yprz5F1uKPVVseqqA79hvEXKWkPY12oeyGOvjWm APkPJBtPiYAmADajgMXylvSoP6RPpUAfKQfQ87hHFbKPPaLhVIUEuNTh/91tiv3V9gc4UY G/4OeQfMQsT9YEgP5Lvhrw3KlN8Mar88Bi3U9sbxD0dim8mP3GDJ6p/fHS126KoP7lJhGn eQTluBw7yKirjyo2brb6yVAvh7C0rbGEDjuhxSm7O1wyqLz5+u8jaGnUI7EzDTGH7y3blW bRf4nC17amsrviDh48R7DUzoxdFwOIuAp2DWRk+jZvpi4rB11ynfJe2dgb2V5w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by avg: URL: https://cgit.FreeBSD.org/src/commit/?id=8b37048bc5482ffe46404dbe6311f0530d2c150b commit 8b37048bc5482ffe46404dbe6311f0530d2c150b Author: Andriy Gapon AuthorDate: 2021-12-13 11:51:47 +0000 Commit: Andriy Gapon CommitDate: 2021-12-13 11:51:47 +0000 Revert "mmc_sim: fix setting of the mutex name" This reverts commit df472af034e7726dea533ac7f44440dad4ba6a34. The change hasn't been reviewed. --- sys/cam/mmc/mmc_sim.c | 9 ++++++--- sys/cam/mmc/mmc_sim.h | 1 - 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/sys/cam/mmc/mmc_sim.c b/sys/cam/mmc/mmc_sim.c index 792551a93511..45d706f61d0a 100644 --- a/sys/cam/mmc/mmc_sim.c +++ b/sys/cam/mmc/mmc_sim.c @@ -191,6 +191,7 @@ mmc_cam_sim_default_action(struct cam_sim *sim, union ccb *ccb) int mmc_cam_sim_alloc(device_t dev, const char *name, struct mmc_sim *mmc_sim) { + char sim_name[64], mtx_name[64]; mmc_sim->dev = dev; @@ -198,11 +199,13 @@ mmc_cam_sim_alloc(device_t dev, const char *name, struct mmc_sim *mmc_sim) goto fail; } - snprintf(mmc_sim->name, sizeof(mmc_sim->name), "%s_sim", name); - mtx_init(&mmc_sim->mtx, mmc_sim->name, NULL, MTX_DEF); + snprintf(sim_name, sizeof(sim_name), "%s_sim", name); + snprintf(mtx_name, sizeof(mtx_name), "%s_mtx", name); + + mtx_init(&mmc_sim->mtx, sim_name, NULL, MTX_DEF); mmc_sim->sim = cam_sim_alloc(mmc_cam_sim_default_action, mmc_cam_default_poll, - mmc_sim->name, mmc_sim, device_get_unit(dev), + name, mmc_sim, device_get_unit(dev), &mmc_sim->mtx, 1, 1, mmc_sim->devq); if (mmc_sim->sim == NULL) { diff --git a/sys/cam/mmc/mmc_sim.h b/sys/cam/mmc/mmc_sim.h index 10bd183c307d..2b1159a9758e 100644 --- a/sys/cam/mmc/mmc_sim.h +++ b/sys/cam/mmc/mmc_sim.h @@ -33,7 +33,6 @@ struct mmc_sim { struct mmc_cam_sim_softc *sc; struct mtx mtx; - char name[64]; struct cam_devq *devq; struct cam_sim *sim; device_t dev;