Bug 238197 - [FUSEFS] fusefs supports neither chflags(2) not stat.st_birthtim
Summary: [FUSEFS] fusefs supports neither chflags(2) not stat.st_birthtim
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Many People
Assignee: Alan Somers
URL: https://reviews.freebsd.org/D20453
Depends on:
Reported: 2019-05-28 20:21 UTC by Alan Somers
Modified: 2019-08-25 16:05 UTC (History)
3 users (show)

See Also:

Add st_birthtime support to FUSEFS backwards-incompatibly (10.88 KB, patch)
2019-05-28 20:21 UTC, Alan Somers
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alan Somers freebsd_committer 2019-05-28 20:21:39 UTC
Created attachment 204675 [details]
Add st_birthtime support to FUSEFS backwards-incompatibly

The FUSE protocol does not support chflags(2) at all, and the FUSE_GETATTR and FUSE_SETATTR messages have no fields for st_birthtime.  This is a direct result of its Linux-only origins.  OSXFuse extended the protocol to add those features (and others), but they had to fork libfuse to do it.  FreeBSD has thus far had a policy of no changes to libfuse.  Even if we were to abandon that policy, we can't add chflags and st_birthtime support without bumping the FUSE kernel API version past the most recently published version in libfuse.  The reason is because libfuse includes its own copy of the kernel API header.  Changing the FUSE protocol without reving the kernel API past what is already published by libfuse would thus break existing binaries.

Attached is a patch that adds st_birthtime support to fusefs(5).  However, it adds it at protocol version 7.9, so it breaks compatibility with existing binaries.  The patch also includes some OSX definitions.  I thought that including them would make it easier to update libfuse.
Comment 1 Conrad Meyer freebsd_committer 2019-05-28 20:48:44 UTC
Can you post the patch on phabricator?
Comment 2 Alan Somers freebsd_committer 2019-05-28 23:33:31 UTC
Review added.
Comment 3 Conrad Meyer freebsd_committer 2019-05-28 23:34:47 UTC