Page MenuHomeFreeBSD

rmacklem (Rick Macklem)
User

Projects

User Details

User Since
Jan 13 2015, 10:58 PM (538 w, 2 d)

Recent Activity

Tue, May 6

rmacklem committed rG0660de8172cd: runat: Add a runat(1) utility similar to the Solaris one (authored by rmacklem).
runat: Add a runat(1) utility similar to the Solaris one
Tue, May 6, 8:39 PM
rmacklem closed D49850: runat: A utility that executes a shell command on a named attribute.
Tue, May 6, 8:39 PM
rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

Added support for _PC_HAS_NAMEDATTR, which is
mainly a new function called zfs_has_namedattr().

Tue, May 6, 2:20 PM

Mon, May 5

rmacklem committed rGe4c7b2b6053f: nfsv4: Add support to NFSv4 for named attributes (authored by rmacklem).
nfsv4: Add support to NFSv4 for named attributes
Mon, May 5, 11:10 PM
rmacklem accepted D50169: mountd, showmount: move to the nfs package.
Mon, May 5, 10:13 PM
rmacklem accepted D50162: rpc.statd: move to nfs package.
Mon, May 5, 12:44 PM
rmacklem added a reverting change for rG9419e086e1a3: nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes: rG2c0e6f53171c: Revert "nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes".
Mon, May 5, 2:42 AM
rmacklem committed rG2c0e6f53171c: Revert "nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes" (authored by rmacklem).
Revert "nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes"
Mon, May 5, 2:42 AM
rmacklem committed rG4a795fb913fe: UPDATING: Add an entry for commit 9419e086e1a3 (authored by rmacklem).
UPDATING: Add an entry for commit 9419e086e1a3
Mon, May 5, 1:12 AM
rmacklem committed rG22d4fecbcf57: param.h: Bump __FreeBSD_version to 1500040 (authored by rmacklem).
param.h: Bump __FreeBSD_version to 1500040
Mon, May 5, 1:05 AM
rmacklem committed rG9419e086e1a3: nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes (authored by rmacklem).
nfscommon: Use _PC_HAS_NAMEDATTR to check for named attributes
Mon, May 5, 12:56 AM

Sun, May 4

rmacklem committed rG38eb41a3897a: pathconf.2: Document the _PC_HAS_NAMEDATTR name (authored by rmacklem).
pathconf.2: Document the _PC_HAS_NAMEDATTR name
Sun, May 4, 10:26 PM
rmacklem closed D50141: pathconf.2: Document the _PC_HAS_NAMEDATTR name.
Sun, May 4, 10:26 PM
rmacklem committed rG0f12c3cd0ddb: vfs_default.c: Add _PC_HAS_NAMEDATTR pathconf name (authored by rmacklem).
vfs_default.c: Add _PC_HAS_NAMEDATTR pathconf name
Sun, May 4, 10:13 PM
rmacklem closed D50140: vfs_default.c: Add _PC_HAS_NAMEDATTR pathconf name.
Sun, May 4, 10:13 PM
rmacklem committed rGf61844833ee8: vfs_vnops.c: Make O_NAMEDATTR Solaris compatible (authored by rmacklem).
vfs_vnops.c: Make O_NAMEDATTR Solaris compatible
Sun, May 4, 10:02 PM
rmacklem closed D50139: vfs_vnops.c: Make O_NAMEDATTR Solaris compatible.
Sun, May 4, 10:01 PM
rmacklem committed rG2773c07181a7: mountd: Fix updating the network/host(s) for an exports line (authored by rmacklem).
mountd: Fix updating the network/host(s) for an exports line
Sun, May 4, 7:17 PM
rmacklem added a comment to D50140: vfs_default.c: Add _PC_HAS_NAMEDATTR pathconf name.
In D50140#1143762, @kib wrote:

Does Solaris use the pathconf() to report xattr existence for the specific node?

It seems to do so. Solaris calls it _PC_XATTR_EXISTS.
It seems to work for local files on Solaris, but returns random junk for an NFSv4 mount.
(Since things look correct on the wire, I think this is just a Solaris bug?)

Sun, May 4, 3:23 PM
rmacklem committed rG70369e4c2c1a: mountd: Fix updating the network/host(s) for an exports line (authored by rmacklem).
mountd: Fix updating the network/host(s) for an exports line
Sun, May 4, 1:11 AM
rmacklem committed rG37abcf06f210: mountd: Fix updating the network/host(s) for an exports line (authored by rmacklem).
mountd: Fix updating the network/host(s) for an exports line
Sun, May 4, 1:09 AM
rmacklem added a comment to D50141: pathconf.2: Document the _PC_HAS_NAMEDATTR name.

Are these Function Arguments? Can I alphabetize these?

Sun, May 4, 12:55 AM

Sat, May 3

rmacklem requested review of D50141: pathconf.2: Document the _PC_HAS_NAMEDATTR name.
Sat, May 3, 10:14 PM
rmacklem updated the diff for D49851: Document the named attribute interface.

Clarified when named attributes and named attribute
directories are created.

Sat, May 3, 10:05 PM
rmacklem requested review of D50140: vfs_default.c: Add _PC_HAS_NAMEDATTR pathconf name.
Sat, May 3, 8:52 PM
rmacklem requested review of D50139: vfs_vnops.c: Make O_NAMEDATTR Solaris compatible.
Sat, May 3, 8:39 PM

Thu, May 1

rmacklem committed rG68daa781c1f1: mountd: Fix updating the network/host(s) for an exports line (authored by rmacklem).
mountd: Fix updating the network/host(s) for an exports line
Thu, May 1, 11:21 PM

Fri, Apr 25

rmacklem committed rG4fae019c2b8f: nfscommon: Prepare the NFS common code for named attributes (authored by rmacklem).
nfscommon: Prepare the NFS common code for named attributes
Fri, Apr 25, 1:12 AM

Wed, Apr 23

rmacklem updated the diff for D49851: Document the named attribute interface.

Replaced the copyright notice with the new recommended
short one, as suggested by ziaee@.

Wed, Apr 23, 1:09 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Removed the "." after my name in the copyright.

Wed, Apr 23, 12:58 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Added chdir(2) to the SEE ALSO section of the runat.1.

Wed, Apr 23, 12:43 AM
rmacklem added a comment to D49850: runat: A utility that executes a shell command on a named attribute.

Marked inline comments as done.

Wed, Apr 23, 12:29 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Updated the copyrights, as suggested by ziaa@.

Wed, Apr 23, 12:26 AM
rmacklem accepted D49953: mountd: use free_iovec for build_iovec cleanup.

Looks fine to me, rick

Wed, Apr 23, 12:08 AM

Tue, Apr 22

rmacklem added a comment to D49850: runat: A utility that executes a shell command on a named attribute.

Note that O_CLOEXEC is set in "fmode" near the top of main()
for the second open.

Tue, Apr 22, 11:06 AM
rmacklem added a comment to D49850: runat: A utility that executes a shell command on a named attribute.

Marked inline comments as done.

Tue, Apr 22, 11:02 AM
rmacklem added inline comments to D49850: runat: A utility that executes a shell command on a named attribute.
Tue, Apr 22, 11:01 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Missed a couple of cases for .Ar file. Fixed now.

Tue, Apr 22, 10:46 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Updated man page with changes suggested by ziaa@.

Tue, Apr 22, 10:39 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Updated the man page to reflect the use of /bin/sh.

Tue, Apr 22, 10:27 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

This version just does an execl() as suggested by kib@.

Tue, Apr 22, 3:19 AM
rmacklem added inline comments to D49850: runat: A utility that executes a shell command on a named attribute.
Tue, Apr 22, 2:45 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Oops, missed the last suggested change from kib@
the last time. It is here now.

Tue, Apr 22, 2:39 AM
rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Updated runat.c to apply kib@'s suggestions.
For some reason (don't know where I got it) I
thought that fchdir() directory change would
affect more than the process, which was why I
did the fork(). (I think it came from ancient
recollections of how 6th Edition worked in the
1970s. I'm gettin old;-)

Tue, Apr 22, 2:22 AM
rmacklem updated the diff for D49851: Document the named attribute interface.

Re-written to conform to the more Solaris-like
semantics of O_NAMEDATTR that is now implemented
in main.

Tue, Apr 22, 1:27 AM

Mon, Apr 21

rmacklem updated the diff for D49850: runat: A utility that executes a shell command on a named attribute.

Update runat.c to use the up to date more Solaris-like
O_NAMEDATTR flag.

Mon, Apr 21, 1:37 AM
rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

I misinterpreted the Solaris documentation for O_XATTR.
It is used for an openat() where the path is for a file in
the file system's namespace, to open a named attribute
for the file, not a named attribute directory.

Mon, Apr 21, 12:03 AM

Sun, Apr 20

rmacklem committed rGb1b607bd200f: vfs_vnops.c: Modify the O_NAMEDATTR check for Solaris compatibility (authored by rmacklem).
vfs_vnops.c: Modify the O_NAMEDATTR check for Solaris compatibility
Sun, Apr 20, 11:24 PM
rmacklem closed D49899: vfs_vnops.c: Modify the O_NAMEDATTR check for Solaris compatibility.
Sun, Apr 20, 11:24 PM
rmacklem committed rGee95e4d02dbd: vfs_vnops.c: Fix the named attribute check for open (authored by rmacklem).
vfs_vnops.c: Fix the named attribute check for open
Sun, Apr 20, 11:20 PM
rmacklem closed D49898: vfs_vnops.c: Fix the named attribute check for open.
Sun, Apr 20, 11:20 PM

Sat, Apr 19

rmacklem updated the diff for D49899: vfs_vnops.c: Modify the O_NAMEDATTR check for Solaris compatibility.

Cleaned up the "if" as suggested by kib@.

Sat, Apr 19, 8:58 PM
rmacklem updated the diff for D49898: vfs_vnops.c: Fix the named attribute check for open.

Added a helper function, as suggested by kib@.

Sat, Apr 19, 8:51 PM
rmacklem added a comment to D49898: vfs_vnops.c: Fix the named attribute check for open.

I now realize that the check for non-named attribute is in
ZFS's VOP_LOOKUP(), so this patch is not really needed,
but I think it is a good "safety belt" to put in.

Sat, Apr 19, 3:23 PM

Fri, Apr 18

rmacklem requested review of D49899: vfs_vnops.c: Modify the O_NAMEDATTR check for Solaris compatibility.
Fri, Apr 18, 11:32 PM
rmacklem requested review of D49898: vfs_vnops.c: Fix the named attribute check for open.
Fri, Apr 18, 11:27 PM
rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Oops, this is a bit embarrassing. I took another look
at the Solaris doc (which is confusing, too) and realized
I hadn't implemented what they did for their O_XATTR.

Fri, Apr 18, 11:17 PM
rmacklem added inline comments to D49691: open.2: Document the O_NAMEDATTR flag added recently.
Fri, Apr 18, 3:08 PM
rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Attempt #2 at explaining the use of O_NAMEDATTR
when opening a named attribute.

Fri, Apr 18, 3:01 AM
rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Added a sentence trying to explain the use
of O_NAMEDATTR for the openat() of a named
attribute. For this case, it performs a sanity check
to ensure the successful open is that of a named
attribute.

Fri, Apr 18, 2:29 AM
rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Rework the description for O_NAMEDATTR to try
and explain how it is used to open named attributes,
as suggested by kib@.

Fri, Apr 18, 1:46 AM
rmacklem added inline comments to D49691: open.2: Document the O_NAMEDATTR flag added recently.
Fri, Apr 18, 12:32 AM

Wed, Apr 16

rmacklem committed rG33e22c4f94d1: pathconf.2: Update man page for the _PC_NAMEDATTR_ENABLED flag (authored by rmacklem).
pathconf.2: Update man page for the _PC_NAMEDATTR_ENABLED flag
Wed, Apr 16, 10:38 PM
rmacklem added a reviewer for D49851: Document the named attribute interface: ziaee.
Wed, Apr 16, 1:44 PM
rmacklem requested review of D49851: Document the named attribute interface.
Wed, Apr 16, 1:44 PM
rmacklem requested review of D49850: runat: A utility that executes a shell command on a named attribute.
Wed, Apr 16, 2:16 AM

Tue, Apr 15

rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Tried to clarify when O_NAMEDATTR is used.

Tue, Apr 15, 3:01 PM
rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

I am now convinced that the check in zfs_freebsd_open()
for O_NAMEDATTR being set is not necessary at all.

Tue, Apr 15, 1:39 AM

Mon, Apr 14

rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

Checking for VIRF_NAMEDATTR in zfs_freebsd_open()
was not needed and broke the runat(1) utility I am writing.

Mon, Apr 14, 11:47 PM

Fri, Apr 11

rmacklem updated the diff for D49691: open.2: Document the O_NAMEDATTR flag added recently.

Add a missing '.' at the end of a statement.

Fri, Apr 11, 3:00 AM
rmacklem closed D49719: statfs.2: Document the new MNT_NAMEDATTR mount flag.
Fri, Apr 11, 1:03 AM
rmacklem committed rG964d0fd62431: statfs.2: Update man page for the MNT_NAMEDATTR flag (authored by rmacklem).
statfs.2: Update man page for the MNT_NAMEDATTR flag
Fri, Apr 11, 1:03 AM

Thu, Apr 10

rmacklem added a comment to D49718: fhopen.2: Document the O_NAMEDATTR flag.

Oops. I didn't see emaste@'s comment until after
doing the commit.

Thu, Apr 10, 2:02 AM
rmacklem committed rGdedbb972d294: fhopen.2: Update man page for O_NAMEDATTR flag (authored by rmacklem).
fhopen.2: Update man page for O_NAMEDATTR flag
Thu, Apr 10, 12:52 AM
rmacklem closed D49718: fhopen.2: Document the O_NAMEDATTR flag.
Thu, Apr 10, 12:52 AM

Wed, Apr 9

rmacklem added a comment to D49718: fhopen.2: Document the O_NAMEDATTR flag.

I do really love putting the commit that the work depends on in "Fixes: " instead of the introductory sentence of the commit message. It makes me feel like the the sentence is clean and just explaining for me, and very predictable to track the tree of events related to the commit.

Wed, Apr 9, 11:06 PM
rmacklem updated the diff for D49718: fhopen.2: Document the O_NAMEDATTR flag.

Removed the sentence w.r.t. the specific error, since
it is covered in the ERROR section. Also, moved the
ENOATTR entries so that they are in alphabetical order,
as suggested by ziaee@.

Wed, Apr 9, 8:08 PM
rmacklem updated the diff for D49719: statfs.2: Document the new MNT_NAMEDATTR mount flag.

Moved the MNT_NAMEDATTR entry up, to maintain
alphabetical ordering, as suggested by ziaee@.

Wed, Apr 9, 8:05 PM

Apr 9 2025

rmacklem added a comment to D49717: fhopen: Enable handling of O_PATH, fix some bugs.

Just to clarify what the previous comment was talking about.
Without this patch:
fhopen(&fh, O_RDONLY | O_NAMEDATTR | O_PATH) works
but
fhopen(&fh, O_EXEC | O_NAMEDATTR | O_PATH) fails with EINVAL
(You can basically ignore the O_NAMEDATTR. I just did the tests with
some test code I had lying about for O_NAMEDATTR.)

Apr 9 2025, 2:46 AM
rmacklem added a comment to D49717: fhopen: Enable handling of O_PATH, fix some bugs.

Without this patch:
kern_fhopen() requires FREAD or FWRITE.
It checks for these and fails with EINVAL if neither are set.

Apr 9 2025, 2:36 AM

Apr 8 2025

rmacklem accepted D49717: fhopen: Enable handling of O_PATH, fix some bugs.
Apr 8 2025, 11:38 PM
rmacklem requested review of D49719: statfs.2: Document the new MNT_NAMEDATTR mount flag.
Apr 8 2025, 10:12 PM
rmacklem requested review of D49718: fhopen.2: Document the O_NAMEDATTR flag.
Apr 8 2025, 10:07 PM

Apr 7 2025

rmacklem accepted D49674: copy_file_range: Fix overlap checking.

This looks fine to me.

Apr 7 2025, 12:28 PM

Apr 6 2025

rmacklem requested review of D49691: open.2: Document the O_NAMEDATTR flag added recently.
Apr 6 2025, 9:00 PM

Apr 5 2025

rmacklem added inline comments to D49674: copy_file_range: Fix overlap checking.
Apr 5 2025, 9:08 PM
rmacklem added inline comments to D49674: copy_file_range: Fix overlap checking.
Apr 5 2025, 4:57 PM

Apr 3 2025

rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

Cleanup up zfs_freebsd_lookup(), including adding some
comments to try and explain the named attribute case.

Apr 3 2025, 3:11 PM
rmacklem updated the diff for D49654: openzfs: Add support for Solaris style extended attributes.

Fixed a bug when open'ng "." in a named attribute directory.

Apr 3 2025, 4:04 AM

Apr 2 2025

rmacklem updated the summary of D49654: openzfs: Add support for Solaris style extended attributes.
Apr 2 2025, 11:53 PM
rmacklem requested review of D49654: openzfs: Add support for Solaris style extended attributes.
Apr 2 2025, 11:50 PM
rmacklem committed rG6441407b297e: vnode.h: Delete VA_NAMEDATTR_TYPE (authored by rmacklem).
vnode.h: Delete VA_NAMEDATTR_TYPE
Apr 2 2025, 9:19 PM
rmacklem accepted D49651: stat(2): add st_bsdflags field.

All looks good to me. (I am glad you did this. I would have missed
half of the places that needed to be changed.)

Apr 2 2025, 8:58 PM
rmacklem committed rG2ec2ba7e232d: vfs: Add VFS/syscall support for Solaris style extended attributes (authored by rmacklem).
vfs: Add VFS/syscall support for Solaris style extended attributes
Apr 2 2025, 8:47 PM
rmacklem closed D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).
Apr 2 2025, 8:47 PM
rmacklem added a comment to D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).
In D49583#1131634, @kib wrote:

Do you want me to prepare the generic patch for stat(2)? Then you would add the setting of the bits as the followup.

Apr 2 2025, 8:05 PM
rmacklem added a comment to D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).
In D49583#1131392, @kib wrote:
In D49583#1131379, @kib wrote:

I think fhopen() should require O_NAMEDATTR to successfully open the attribute inode' handle.
BTW, given a file descriptor, is there a way to understand if this is a regular fd or namedattr fd? In particular, does fstatat(2) return some distinguishing info?

Not a fd. The code needs to get the associated vnode and look for VIRF_NAMEDDIR or VIRF_NAMEDATTR being set.
(I'll tweak fhopen(2) to do that.)

No, I don't have fstatat(2) returning anything in "struct stat" that indicates "namedattr".
(st_flags seem to be all bits that can be set/cleared by chflags and I cannot see any
other field of "struct stat" that could be used to indicate a named attribute dir/attribute.)
Any suggestions?

The regular way would be to define new S_IFMT value for named attr files, but this probably would break too much.
We have st_padding0 field that can be used for additional flags, like st_bsd_flags or similar, and we can allocate the first bit there to mean named attr file. The rename of st_padding0 and the flag definition should be a separate commit.

Apr 2 2025, 1:40 PM
rmacklem updated the diff for D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).

Change fhopen(2) so that O_NAMEDATTR is required to
open a file handle that represents a named attribute or
named attribute directory.

Apr 2 2025, 1:52 AM
rmacklem added a comment to D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).
In D49583#1131379, @kib wrote:

I think fhopen() should require O_NAMEDATTR to successfully open the attribute inode' handle.
BTW, given a file descriptor, is there a way to understand if this is a regular fd or namedattr fd? In particular, does fstatat(2) return some distinguishing info?

Apr 2 2025, 12:31 AM

Apr 1 2025

rmacklem updated the diff for D49583: Add VFS/syscall support for Solaris style extended attributes (called named attributes by NFSv4).

Changed MNTK_NAMEDATTR to MNT_NAMEDATTR as
suggested by kib@.

Apr 1 2025, 10:52 PM