Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Jun 2025 21:37:24 GMT
From:      Jessica Clarke <jrtc27@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: c4d3a1836d50 - main - msdosfs: Don't #ifdef out msdosfsmount members
Message-ID:  <202506162137.55GLbOg6073022@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by jrtc27:

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

commit c4d3a1836d50f66de71384bf7e824b2c49f914a3
Author:     Jessica Clarke <jrtc27@FreeBSD.org>
AuthorDate: 2025-06-16 21:33:07 +0000
Commit:     Jessica Clarke <jrtc27@FreeBSD.org>
CommitDate: 2025-06-16 21:33:07 +0000

    msdosfs: Don't #ifdef out msdosfsmount members
    
    Whilst these aren't used by makefs, they do little harm existing once
    the needed headers are included, and having structs change layout based
    on defines like this can be fraught. This will be particularly true once
    this code is exposed by defines other than _KERNEL and MAKEFS, as any
    consumer will be able to opt into exposing this kernel type and all the
    definitions should match.
    
    Reviewed by:    markj
    Differential Revision:  https://reviews.freebsd.org/D50885
---
 sys/fs/msdosfs/msdosfsmount.h | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/sys/fs/msdosfs/msdosfsmount.h b/sys/fs/msdosfs/msdosfsmount.h
index 8f15bc2eaf42..adfc7e4d0e88 100644
--- a/sys/fs/msdosfs/msdosfsmount.h
+++ b/sys/fs/msdosfs/msdosfsmount.h
@@ -58,8 +58,11 @@
 #ifndef MAKEFS
 #include <sys/lock.h>
 #include <sys/lockmgr.h>
-#include <sys/_task.h>
+#else
+#include <sys/_lock.h>
+#include <sys/_lockmgr.h>
 #endif
+#include <sys/_task.h>
 #include <sys/tree.h>
 
 #ifdef MALLOC_DECLARE
@@ -114,11 +117,9 @@ struct msdosfsmount {
 	void *pm_w2u;	/* Unicode->Local iconv handle */
 	void *pm_u2d;	/* Unicode->DOS iconv handle */
 	void *pm_d2u;	/* DOS->Local iconv handle */
-#ifndef MAKEFS
 	struct lock pm_fatlock;	/* lockmgr protecting allocations */
 	struct lock pm_checkpath_lock; /* protects doscheckpath result */
 	struct task pm_rw2ro_task; /* context for emergency remount ro */
-#endif
 };
 
 /*



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