Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 5 Jan 2012 08:48:18 -0500
From:      John Baldwin <jhb@freebsd.org>
To:        freebsd-arch@freebsd.org
Cc:        freebsd-fs@freebsd.org, Adrian Chadd <adrian@freebsd.org>, freebsd-current <freebsd-current@freebsd.org>
Subject:   Re: Is it possible to make subr_acl_nfs4 and subr_acl_posix1e disabled?
Message-ID:  <201201050848.18414.jhb@freebsd.org>
In-Reply-To: <CAJ-Vmo=qNu9KpF6kSofychNcjwexFKvAT8bnwd3gVr-VPymN5w@mail.gmail.com>
References:  <CAJ-Vmo=qNu9KpF6kSofychNcjwexFKvAT8bnwd3gVr-VPymN5w@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
[ A bit excessive on the cross-posting?  arch@ alone was probably fine ]

On Thursday, January 05, 2012 2:57:44 am Adrian Chadd wrote:
> Hi,
> 
> I'm trying to slim down the freebsd kernel to fit on some devices with
> 4MB of flash.
> 
> Since I'm not using NFS or UFS_ACL, I wondered if that code required.
> It turns out I can just build a kernel with those two disabled.
> 
> Would it be possible to remove them from "standard" and make them
> optional? Or is there a reason to keep it in base?
> If so (eg so things can be kldload'ed that uses the ACL code) can we
> make it a build-time option, and/or a pair of loadable kernel modules?

NFS doesn't actually use them curently, only UFS and ZFS do.  Unfortunately
we've yet to make it possible to compile ZFS into the kernel, so you can't
make the sys/conf/files bits completely accurate yet (it would be nice to
let folks who don't need FFS for a ZFS-only system remove FFS and UFS, but
this would break that):

Index: files
===================================================================
--- files	(revision 229491)
+++ files	(working copy)
@@ -2393,8 +2393,9 @@ kern/sched_ule.c		optional sched_ule
 kern/serdev_if.m		standard
 kern/stack_protector.c		standard \
 	compile-with "${NORMAL_C:N-fstack-protector*}"
-kern/subr_acl_nfs4.c		standard
-kern/subr_acl_posix1e.c		standard
+# XXX: subr_acl_nfs4.c is also used by ZFS
+kern/subr_acl_nfs4.c		optional ufs_acl
+kern/subr_acl_posix1e.c		optional ufs_acl
 kern/subr_autoconf.c		standard
 kern/subr_blist.c		standard
 kern/subr_bus.c			standard

-- 
John Baldwin



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