Re: [PATCH 1/1] ntfs: add ioctl support for named data streams
Namjae Jeon <[email protected]> Tue, 4 Aug 2026 09:01:07 +0900
| Newsgroups | org.kernel.vger.linux-fsdevel,dev.linux.lists.ntfs,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <CAKYAXd_oohSF2rLCns432OMACc6S-M7Hv8jCGtkD-rOd2QMYEQ@mail.gmail.com> |
On Mon, Aug 3, 2026 at 6:10=E2=80=AFPM Lionel Cons <[email protected]= m> wrote: > > On Wed, 29 Jul 2026 at 13:00, Namjae Jeon <[email protected]> wrote: > > > > Sebastian and Cedric requested NTFS driver support for an interface tha= t > > WINE can use to access named data streams. > > > > NTFS supports multiple named $DATA attributes, commonly known as altern= ate > > data streams, but they are not directly accessible through the existing > > file operations. Add NTFS-specific ioctl commands to let userspace list= , > > read, write, and remove named data streams on an opened file. > > > > The new UAPI provides separate commands for each operation: > > > > - NTFS_IOC_STREAM_READ > > - NTFS_IOC_STREAM_WRITE > > - NTFS_IOC_STREAM_REMOVE > > Wouldn't it be better to just provide an API to get a fd, relative to > a filename? Win32 named streams can be sparse, and it is common to > punch holes to deallocate sections of streams too. Streams do have > their own timestamps, too. I believe the current ioctl interface is the best fit for this support. It operates on an already-open base-file fd, avoids pathname ambiguity with :, supports UTF-16 stream names, and does not require a new system call or VFS changes. If WINE requires hole punching for sparse streams, I can extend the ioctl interface to support it. > > > - NTFS_IOC_LIST_STREAMS > > NTFS_IOC_LIST_STREAMS looks OK. Thanks!