public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Implementing /bin/ionice,ioprio_set() support with FILE_IO_PRIORITY_HINT_INFO?
@ 2024-04-03  1:51 Martin Wege
  2024-04-03  8:39 ` Implementing /bin/ionice, ioprio_set() " Corinna Vinschen
  0 siblings, 1 reply; 2+ messages in thread
From: Martin Wege @ 2024-04-03  1:51 UTC (permalink / raw)
  To: cygwin

Hello,

could Cygwin implement support for /usr/bin/ionice and ioprio_set()
via FILE_IO_PRIORITY_HINT_INFO?

So basically implement ioprio_set() to store the value per process,
and for each file open() call this:

FILE_IO_PRIORITY_HINT_INFO priorityHint={0};
priorityHint.PriorityHint = ioniceprio2WinIoPriorityHint(ioniceprio);
result = SetFileInformationByHandle( hFile,
                                     FileIoPriorityHintInfo,
                                     &priorityHint,
                                     sizeof(PriorityHint));

NTFS and ReFS support FILE_IO_PRIORITY_HINT_INFO

Thanks,
Martin

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-04-03  8:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-03  1:51 Implementing /bin/ionice,ioprio_set() support with FILE_IO_PRIORITY_HINT_INFO? Martin Wege
2024-04-03  8:39 ` Implementing /bin/ionice, ioprio_set() " Corinna Vinschen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).