From nobody Thu Aug 11 16:27:43 2022 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 4M3XKC3VYkz4Yrxp; Thu, 11 Aug 2022 16:27:43 +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 4M3XKC2TNBz3q2c; Thu, 11 Aug 2022 16:27:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660235263; 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=LnlRYx8t8IxLQ71Rwr6ZX+yHRFyE1drPKIIlp7Y7SnU=; b=E3brAhvGC0v9M/R1bRskABHKoDZPKBwzy9+1HbHwPYORnPVGr7RYXgWHIc92TlhIVVGKnF Slopfq1uXbb6ALrCfzL1e9lwH3y9MHnFFgw1o25PoaZMoeN9A5YJXMlAXYCPwvGg+susOE GnJb80ceyt6SA3cw+Z1Zx8bSPNrpI4rOlWYIgx7WdkSMHAh8Z6G18lEaOXpkQIh3DN5/cA OA4fSOUW7wM0uMTf8038H97QmaVwba9fuo1B7VSkGCcQ/eJ/YI+7v+/B8O0q4pxBA18FcI BpLfzRwaXYX1EVGPn9isS3UaFljt1+aI5xNCw4BEl0VeamZ+EGdGbChoXmtGJg== 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 4M3XKC1Zj9zy4j; Thu, 11 Aug 2022 16:27:43 +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 27BGRhZu055402; Thu, 11 Aug 2022 16:27:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 27BGRhsK055401; Thu, 11 Aug 2022 16:27:43 GMT (envelope-from git) Date: Thu, 11 Aug 2022 16:27:43 GMT Message-Id: <202208111627.27BGRhsK055401@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: ec9f3e776f39 - main - stand: Use devformat rather than disk_devfmt 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: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ec9f3e776f39286ccec9915f38cca9729e6f9241 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660235263; 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=LnlRYx8t8IxLQ71Rwr6ZX+yHRFyE1drPKIIlp7Y7SnU=; b=r4BIfxIMxOXQE46oVRVnd51t89W43zP1uQmEc+65Oii47bGZ9N5ET9pJzBBdlWMmbXeD1c jEK7PmQftlDIwLjug+qjuo0aIp6CxsLRE5/PC4+ep+cNrKA90C4xOINHh0HoVEm7qWQLg+ wgSmPxTzKC3K2UFDvQl4nuj5J9A/mzwSktbpplamGDtmGJ7OSrk31tAqP+DG2mtIZeJJ69 ktQw2ThOO9qG5b/9TZV63CVRlpPPuHqgnmVBschWvQbdbfdJBq74s+Swz/7CUGRHbyJRdD ayIIeS9jysNnVDM0O2WZ83fi44kBym+slBf7l/Ew441A5aE4mlLNsDuDb5fiNg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1660235263; a=rsa-sha256; cv=none; b=kQ5qkfMHfIs4bHzpQEB/+t04w8qjQP5AtourGzznZhLKmBwZMVcQTKwR5Wb5jWLcDBucmr WGqwvaqWElGJdnouW+8gVi0BylpGcbSsIbSSDk1a8PYuJtwFQRgZ60CdBcwPSMFMUy99Gy AmkVzkjm9ytGPxr4tKDnvjlwz16dlCFUOfVSc/uvkjUoZnOzfjTWzzw6xXkX2GqJl52ydH hLBzJ4LE+qKOJB8fCHYYDH1uie2vKX2AwFAXfFTXKG1ZyDETe/Kt1UVEDj0hqnv58b4lKC DPllGEyDMR9bkAZd9ISjsRRi6c5tNDq2W/tMZ3kf/+piXMFOPZ/RTgjvpUEDPw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=ec9f3e776f39286ccec9915f38cca9729e6f9241 commit ec9f3e776f39286ccec9915f38cca9729e6f9241 Author: Warner Losh AuthorDate: 2022-08-11 15:06:53 +0000 Commit: Warner Losh CommitDate: 2022-08-11 16:27:16 +0000 stand: Use devformat rather than disk_devfmt Fix layering violation and use devformat to get the string representation of the device to see if we're mounted yet or not. Remove added include to pickup disk.h. Sponsored by: Netflix Reviewed by: tsoome (prior version) Differential Revision: https://reviews.freebsd.org/D35919 --- stand/libsa/Makefile | 1 - stand/libsa/dosfs.c | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/stand/libsa/Makefile b/stand/libsa/Makefile index de25a596d1ec..c2372e192b38 100644 --- a/stand/libsa/Makefile +++ b/stand/libsa/Makefile @@ -170,7 +170,6 @@ SRCS+= time.c .PATH: ${SRCTOP}/sys/ufs/ffs SRCS+=ffs_subr.c ffs_tables.c -CFLAGS.dosfs.c+= -I${LDRSRC} CFLAGS.ufs.c+= -I${LDRSRC} CFLAGS.gzipfs.c+= ${ZLIB_CFLAGS} CFLAGS.pkgfs.c+= ${ZLIB_CFLAGS} diff --git a/stand/libsa/dosfs.c b/stand/libsa/dosfs.c index 452a79ae12dc..09f09dc66809 100644 --- a/stand/libsa/dosfs.c +++ b/stand/libsa/dosfs.c @@ -38,7 +38,6 @@ __FBSDID("$FreeBSD$"); #include #include "stand.h" -#include "disk.h" #include "dosfs.h" @@ -314,7 +313,7 @@ dos_open(const char *path, struct open_file *fd) u_int size, clus; int err; - dev = disk_fmtdev(fd->f_devdata); + dev = devformat((struct devdesc *)fd->f_devdata); STAILQ_FOREACH(mnt, &mnt_list, dos_link) { if (strcmp(dev, mnt->dos_dev) == 0) break;