summaryrefslogtreecommitdiffstats
path: root/sbin/mdconfig
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2015-08-06 06:47:28 +0000
committered <ed@FreeBSD.org>2015-08-06 06:47:28 +0000
commitad0a6d924b4314f1d8bbe323aeb6196b921d56eb (patch)
treea56156f75a5c8d0be9c50097e170560c1efd9583 /sbin/mdconfig
parent97d63e2d06ed669268e1f0feabc0d7437ad01fd3 (diff)
downloadFreeBSD-src-ad0a6d924b4314f1d8bbe323aeb6196b921d56eb.zip
FreeBSD-src-ad0a6d924b4314f1d8bbe323aeb6196b921d56eb.tar.gz
Add file_open(): the underlying system call of openat().
CloudABI purely operates on file descriptor rights (CAP_*). File descriptor access modes (O_ACCMODE) are emulated on top of rights. Instead of accepting the traditional flags argument, file_open() copies in an fdstat_t object that contains the initial rights the descriptor should have, but also file descriptor flags that should persist after opening (APPEND, NONBLOCK, *SYNC). Only flags that don't persist (EXCL, TRUNC, CREAT, DIRECTORY) are passed in as an argument. file_open() first converts the rights, the persistent flags and the non-persistent flags to fflags. It then calls into vn_open(). If successful, it installs the file descriptor with the requested rights, trimming off rights that don't apply to the type of the file that has been opened. Unlike kern_openat(), this function does not support /dev/fd/*. I can't think of a reason why we need to support this for CloudABI. Obtained from: https://github.com/NuxiNL/freebsd Differential Revision: https://reviews.freebsd.org/D3235
Diffstat (limited to 'sbin/mdconfig')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud