28#include <seastar/util/modules.hh>
33SEASTAR_MODULE_EXPORT_BEGIN
52 return open_flags(std::underlying_type_t<open_flags>(a) | std::underlying_type_t<open_flags>(b));
60 return open_flags(std::underlying_type_t<open_flags>(a) & std::underlying_type_t<open_flags>(b));
81namespace internal::linux_abi {
85static_assert(
sizeof(ino_t) == 8,
"large file support not enabled");
86static_assert(
sizeof(off_t) == 8,
"large file support not enabled");
89struct linux_dirent64 {
92 unsigned short d_reclen;
112enum class access_flags {
122inline access_flags operator|(access_flags a, access_flags b) {
123 return access_flags(std::underlying_type_t<access_flags>(a) | std::underlying_type_t<access_flags>(b));
126inline access_flags operator&(access_flags a, access_flags b) {
127 return access_flags(std::underlying_type_t<access_flags>(a) & std::underlying_type_t<access_flags>(b));
131enum class file_permissions {
133 user_write = S_IWUSR,
134 user_execute = S_IXUSR,
136 group_read = S_IRGRP,
137 group_write = S_IWGRP,
138 group_execute = S_IXGRP,
140 others_read = S_IROTH,
141 others_write = S_IWOTH,
142 others_execute = S_IXOTH,
144 user_permissions = user_read | user_write | user_execute,
145 group_permissions = group_read | group_write | group_execute,
146 others_permissions = others_read | others_write | others_execute,
147 all_permissions = user_permissions | group_permissions | others_permissions,
149 default_file_permissions = user_read | user_write | group_read | group_write | others_read | others_write,
150 default_dir_permissions = all_permissions,
153inline constexpr file_permissions operator|(file_permissions a, file_permissions b) {
154 return file_permissions(std::underlying_type_t<file_permissions>(a) | std::underlying_type_t<file_permissions>(b));
157inline constexpr file_permissions operator&(file_permissions a, file_permissions b) {
158 return file_permissions(std::underlying_type_t<file_permissions>(a) & std::underlying_type_t<file_permissions>(b));
163SEASTAR_MODULE_EXPORT_END
directory_entry_type
Definition: file-types.hh:70
fs_type
Enumeration describing the type of a particular filesystem.
Definition: file-types.hh:100
open_flags
Definition: file-types.hh:41
Seastar API namespace.
Definition: abort_on_ebadf.hh:26