|
| 1 | +================================== |
| 2 | +libfuse API Changes (3.0 to 3.19) |
| 3 | +================================== |
| 4 | + |
| 5 | +This document describes API changes between FUSE_USE_VERSION values. |
| 6 | +Set FUSE_USE_VERSION before including fuse.h or fuse_lowlevel.h. |
| 7 | + |
| 8 | +Version 3.1 (FUSE_MAKE_VERSION(3, 1)) |
| 9 | +===================================== |
| 10 | + |
| 11 | +New Functions |
| 12 | +------------- |
| 13 | +* ``fuse_lib_help()`` - Print help for generic high-level FUSE options |
| 14 | +* ``fuse_invalidate_path()`` - Cache invalidation from high-level API |
| 15 | + |
| 16 | +Changed Functions |
| 17 | +----------------- |
| 18 | +* ``fuse_new()`` signature changed; applications should call ``fuse_lib_help()`` |
| 19 | + for --help instead of passing it to fuse_new() |
| 20 | + |
| 21 | +Version 3.2 (FUSE_MAKE_VERSION(3, 2)) |
| 22 | +===================================== |
| 23 | + |
| 24 | +Changed Functions |
| 25 | +----------------- |
| 26 | +* ``fuse_loop_mt()`` and ``fuse_session_loop_mt()`` now take a |
| 27 | + ``struct fuse_loop_config *`` parameter instead of a *clone_fd* boolean. |
| 28 | + The struct is public and can be directly initialized. |
| 29 | + |
| 30 | +Note: This change was implemented in libfuse release 3.1.1, but the API version |
| 31 | +that enables it is 32. |
| 32 | + |
| 33 | +Version 3.3 (FUSE_MAKE_VERSION(3, 3)) |
| 34 | +===================================== |
| 35 | + |
| 36 | +New Functions |
| 37 | +------------- |
| 38 | +* ``fuse_open_channel()`` - Open a FUSE file descriptor and set up mount |
| 39 | + (allows passing open /dev/fuse fd via ``/dev/fd/%u`` mountpoint format) |
| 40 | + |
| 41 | +Version 3.4 (FUSE_MAKE_VERSION(3, 4)) |
| 42 | +===================================== |
| 43 | + |
| 44 | +New Operations |
| 45 | +-------------- |
| 46 | +* ``copy_file_range`` - Efficient server-side file copying |
| 47 | + |
| 48 | +New Functions |
| 49 | +------------- |
| 50 | +* ``fuse_fs_copy_file_range()`` - High-level API wrapper |
| 51 | + |
| 52 | +Version 3.5 (FUSE_MAKE_VERSION(3, 5)) |
| 53 | +===================================== |
| 54 | + |
| 55 | +Changed Prototypes |
| 56 | +------------------ |
| 57 | +* ``ioctl`` handler: cmd parameter changed from ``int`` to ``unsigned int`` |
| 58 | + |
| 59 | + - Use FUSE_USE_VERSION < 35 for old ``int cmd`` prototype |
| 60 | + - Use FUSE_USE_VERSION >= 35 for new ``unsigned int cmd`` prototype |
| 61 | + |
| 62 | +Version 3.7 (FUSE_MAKE_VERSION(3, 7)) |
| 63 | +===================================== |
| 64 | + |
| 65 | +New Functions |
| 66 | +------------- |
| 67 | +* ``fuse_set_log_func()`` - Install custom log message handler |
| 68 | +* ``fuse_log()`` - Emit log messages (replaces direct stderr writes) |
| 69 | + |
| 70 | +Version 3.8 (FUSE_MAKE_VERSION(3, 8)) |
| 71 | +===================================== |
| 72 | + |
| 73 | +New Operations |
| 74 | +-------------- |
| 75 | +* ``lseek`` - Find next data or hole in sparse files (SEEK_DATA/SEEK_HOLE) |
| 76 | + |
| 77 | +New Functions |
| 78 | +------------- |
| 79 | +* ``fuse_fs_lseek()`` - High-level API wrapper |
| 80 | +* ``fuse_reply_lseek()`` - Low-level reply function |
| 81 | + |
| 82 | +Version 3.12 (FUSE_MAKE_VERSION(3, 12)) |
| 83 | +======================================= |
| 84 | + |
| 85 | +Major Changes |
| 86 | +------------- |
| 87 | +* ``struct fuse_loop_config`` is now **private** (opaque pointer) |
| 88 | +* Loop configuration must use accessor functions instead of direct struct access |
| 89 | +* The public struct from version 3.2-3.11 is renamed to ``struct fuse_loop_config_v1`` |
| 90 | + |
| 91 | +New Functions |
| 92 | +------------- |
| 93 | +* ``fuse_loop_cfg_create()`` - Create loop configuration |
| 94 | +* ``fuse_loop_cfg_destroy()`` - Free loop configuration |
| 95 | +* ``fuse_loop_cfg_set_idle_threads()`` - Set max idle threads |
| 96 | +* ``fuse_loop_cfg_set_max_threads()`` - Set max total threads |
| 97 | +* ``fuse_loop_cfg_set_clone_fd()`` - Enable/disable clone_fd |
| 98 | +* ``fuse_loop_cfg_convert()`` - Convert old config (v1) to new format |
| 99 | +* ``fuse_lowlevel_notify_expire_entry()`` - Expire dentry without full invalidation |
| 100 | + |
| 101 | +Changed Functions |
| 102 | +----------------- |
| 103 | +* ``fuse_session_loop_mt()`` now accepts NULL config pointer |
| 104 | +* ``fuse_parse_cmdline()`` now accepts ``max_threads`` option |
| 105 | + |
| 106 | +Deprecated |
| 107 | +---------- |
| 108 | +* ``max_idle_threads`` parameter (use ``max_threads`` instead) |
| 109 | + |
| 110 | +Version 3.17 (FUSE_MAKE_VERSION(3, 17)) |
| 111 | +======================================= |
| 112 | + |
| 113 | +New Functions |
| 114 | +------------- |
| 115 | +* ``fuse_set_fail_signal_handlers()`` - Handle fatal signals with backtrace |
| 116 | +* ``fuse_log_enable_syslog()`` - Redirect fuse_log() to syslog |
| 117 | +* ``fuse_log_close_syslog()`` - Close syslog connection |
| 118 | +* ``fuse_passthrough_open()`` - Setup passthrough backing file |
| 119 | +* ``fuse_passthrough_close()`` - Close passthrough connection |
| 120 | +* ``fuse_session_custom_io()`` - Custom I/O for FUSE daemon (signature extended) |
| 121 | + |
| 122 | +New Capabilities |
| 123 | +---------------- |
| 124 | +* ``FUSE_CAP_PASSTHROUGH`` - Enable passthrough read/write to backing file |
| 125 | +* ``FUSE_CAP_HANDLE_KILLPRIV_V2`` - Support for KILLPRIV_V2 |
| 126 | + |
| 127 | +New Mount Options |
| 128 | +----------------- |
| 129 | +* ``fmask`` - umask applied to non-directories (high-level API) |
| 130 | +* ``dmask`` - umask applied to directories (high-level API) |
| 131 | + |
| 132 | +Version 3.17.3 |
| 133 | +============== |
| 134 | + |
| 135 | +New Functions |
| 136 | +------------- |
| 137 | +* ``fuse_set_feature_flag()`` - Set capability in want_ext field |
| 138 | +* ``fuse_unset_feature_flag()`` - Unset capability in want_ext field |
| 139 | +* ``fuse_get_feature_flag()`` - Query capability in want_ext field |
| 140 | + |
| 141 | +Note: These replace direct manipulation of conn->want for 64-bit capability support. |
| 142 | + |
| 143 | +Version 3.18 (FUSE_MAKE_VERSION(3, 18)) |
| 144 | +======================================= |
| 145 | + |
| 146 | +New Operations |
| 147 | +-------------- |
| 148 | +* ``statx`` - Extended file attributes (struct statx support) |
| 149 | + |
| 150 | +New Functions |
| 151 | +------------- |
| 152 | +* ``fuse_fs_statx()`` - High-level API wrapper |
| 153 | +* ``fuse_reply_statx()`` - Low-level reply function |
| 154 | +* ``fuse_req_is_uring()`` - Check if request uses fuse-over-io-uring |
| 155 | +* ``fuse_req_get_payload()`` - Get request payload buffer (io-uring only) |
| 156 | +* ``fuse_lowlevel_notify_increment_epoch()`` - Increment epoch counter |
| 157 | + |
| 158 | +New Features |
| 159 | +------------ |
| 160 | +* fuse-over-io-uring communication support |
| 161 | +* Request timeouts for hung operation prevention |
| 162 | + |
| 163 | +Version 3.19 (FUSE_MAKE_VERSION(3, 19)) |
| 164 | +======================================= |
| 165 | + |
| 166 | +(Reserved for future use) |
| 167 | + |
| 168 | +Migration Notes |
| 169 | +=============== |
| 170 | + |
| 171 | +When upgrading FUSE_USE_VERSION: |
| 172 | + |
| 173 | +1. **3.0 → 3.1**: Handle --help in filesystem code, call fuse_lib_help() |
| 174 | +2. **3.1 → 3.2**: Update fuse_loop_mt() calls to use struct fuse_loop_config |
| 175 | +3. **< 3.5 → 3.5+**: Change ioctl cmd from int to unsigned int |
| 176 | +4. **< 3.12 → 3.12+**: Use fuse_loop_cfg_*() functions instead of direct struct access |
| 177 | +5. **< 3.17 → 3.17+**: Use fuse_set_feature_flag() instead of conn->want for new caps |
| 178 | + |
0 commit comments