Re: Is it possible to make subr_acl_nfs4 and subr_acl_posix1e disabled?

From: John Baldwin <jhb_at_freebsd.org>
Date: Thu, 5 Jan 2012 08:48:18 -0500
[ A bit excessive on the cross-posting?  arch_at_ 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)
_at__at_ -2393,8 +2393,9 _at__at_ 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
Received on Thu Jan 05 2012 - 12:48:20 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:22 UTC