Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 8 Mar 2024 14:02:27 -0800
From:      Mark Millard <marklmi@yahoo.com>
To:        Konstantin Belousov <kib@freebsd.org>, dev-commits-src-main@freebsd.org
Subject:   Re: git: 8921216dbee6 - main - nullfs: add -o cache ["mount" not reporting cache vs. nocache status for listed mounts?]
Message-ID:  <C1D75BA4-40BB-42D7-B3BE-ECB8FA0D98FE@yahoo.com>
References:  <C1D75BA4-40BB-42D7-B3BE-ECB8FA0D98FE.ref@yahoo.com>

next in thread | previous in thread | raw e-mail | index | archive | help
[I'm picking one cache vs. nocache related message to use
to ask my question.]

Konstantin Belousov <kib_at_FreeBSD.org> wrote on
Date: Fri, 08 Mar 2024 18:44:52 UTC :

> The branch main has been updated by kib:
>=20
>> URL: =
https://cgit.FreeBSD.org/src/commit/?id=3D8921216dbee6884532e22d5347cff4d9=
ed23e782
>=20
> commit 8921216dbee6884532e22d5347cff4d9ed23e782
> Author: Konstantin Belousov <kib@FreeBSD.org>
> AuthorDate: 2024-03-08 18:26:02 +0000
> Commit: Konstantin Belousov <kib@FreeBSD.org>
> CommitDate: 2024-03-08 18:44:21 +0000
>=20
> nullfs: add -o cache
>=20
> to allow overwrite global default if needed.
>=20
> Sponsored by: The FreeBSD Foundation
> MFC after: 1 week
> ---
> sys/fs/nullfs/null_vfsops.c | 15 +++++++++------
> 1 file changed, 9 insertions(+), 6 deletions(-)
>=20
> diff --git a/sys/fs/nullfs/null_vfsops.c b/sys/fs/nullfs/null_vfsops.c
> index 7ee6ce53fbde..63bdcd4788d9 100644
> --- a/sys/fs/nullfs/null_vfsops.c
> +++ b/sys/fs/nullfs/null_vfsops.c
> @@ -205,12 +205,15 @@ nullfs_mount(struct mount *mp)
> MNT_IUNLOCK(mp);
> }
>=20
> - xmp->nullm_flags |=3D NULLM_CACHE;
> - if (!null_cache_vnodes ||
> - vfs_getopt(mp->mnt_optnew, "nocache", NULL, NULL) =3D=3D 0 ||
> - (xmp->nullm_vfs->mnt_kern_flag & MNTK_NULL_NOCACHE) !=3D 0)
> - xmp->nullm_flags &=3D ~NULLM_CACHE;
> -
> + if (vfs_getopt(mp->mnt_optnew, "cache", NULL, NULL) =3D=3D 0) {
> + xmp->nullm_flags |=3D NULLM_CACHE;
> + } else if (vfs_getopt(mp->mnt_optnew, "nocache", NULL, NULL) =3D=3D =
0) {
> + ;
> + } else if (null_cache_vnodes &&
> + (xmp->nullm_vfs->mnt_kern_flag & MNTK_NULL_NOCACHE) =3D=3D 0) {
> + xmp->nullm_flags |=3D NULLM_CACHE;
> + }
> +=20
> if ((xmp->nullm_flags & NULLM_CACHE) !=3D 0) {
> vfs_register_for_notification(xmp->nullm_vfs, mp,
> &xmp->notify_node);


Does the mount command report the cache vs. no cache status of the =
mounts
that it lists?

=
https://lists.freebsd.org/archives/freebsd-current/2024-March/005690.html

is is recent a report that it does not. A reply mentions that "ignore" =
vs.
not has a similar status of not being reported:

=
https://lists.freebsd.org/archives/freebsd-current/2024-March/005695.html

=3D=3D=3D
Mark Millard
marklmi at yahoo.com




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?C1D75BA4-40BB-42D7-B3BE-ECB8FA0D98FE>