Skip to content

Commit b98f990

Browse files
committed
IoUring: fix and remove TODOs
backout from updating `pipe2` syscall to use Pipe2 flags Review if useful to implement - openat2*, f/madvice64 Signed-off-by: Bernard Assan <mega.alpha100@gmail.com>
1 parent abfe7da commit b98f990

File tree

2 files changed

+9
-70
lines changed

2 files changed

+9
-70
lines changed

lib/std/os/linux.zig

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1333,7 +1333,7 @@ pub fn pipe(fd: *[2]i32) usize {
13331333
}
13341334
}
13351335

1336-
pub fn pipe2(fd: *[2]i32, flags: Pipe2) usize {
1336+
pub fn pipe2(fd: *[2]i32, flags: O) usize {
13371337
return syscall2(.pipe2, @intFromPtr(fd), @as(u32, @bitCast(flags)));
13381338
}
13391339

@@ -3754,7 +3754,6 @@ pub const Futex2 = struct {
37543754
};
37553755

37563756
/// flags for `futex2_wait` syscall
3757-
// COMMIT: add mpol and fix private field as its 128 not 32
37583757
pub const Wait = packed struct(u32) {
37593758
size: Size,
37603759
numa: bool = false,
@@ -4474,7 +4473,6 @@ pub const Af = enum(u16) {
44744473
pub const MAX: u16 = @intFromEnum(Af.max);
44754474
};
44764475

4477-
// COMMIT: add new Typed So enum
44784476
/// SO_* type
44794477
pub const So = if (is_mips) enum(u16) {
44804478
debug = 1,
@@ -4766,7 +4764,6 @@ pub const So = if (is_mips) enum(u16) {
47664764
pub const detach_bpf: So = .detach_filter;
47674765
};
47684766

4769-
// COMMIT: add SO constants
47704767
/// Backwards-compatible SO_* constants
47714768
pub const SO = struct {
47724769
pub const DEBUG: u16 = @intFromEnum(So.debug);
@@ -5416,7 +5413,6 @@ pub const Msg = packed struct(u32) {
54165413
/// sendpage() internal: page may carry plain text and require encryption
54175414
sendpage_decrypted: bool = false,
54185415
_22: u4 = 0,
5419-
// COMMIT: new flags
54205416
/// Receive devmem skbs as cmsg
54215417
sock_devmem: bool = false,
54225418
/// Use user data in kernel path
@@ -6032,7 +6028,6 @@ pub const Epoll = if (is_mips) packed struct(u32) {
60326028
rdnorm: bool = false,
60336029
/// Priority data may be read
60346030
rdband: bool = false,
6035-
// COMMIT: new flags
60366031
/// Writing is now possible (normal data)
60376032
wrnorm: bool = false,
60386033
/// Priority data may be written
@@ -7015,7 +7010,6 @@ pub const utsname = extern struct {
70157010
};
70167011
pub const HOST_NAME_MAX = 64;
70177012

7018-
// COMMIT: RenameFlags
70197013
pub const Rename = packed struct(u32) {
70207014
/// Don't overwrite target
70217015
noreplace: bool = false,
@@ -7106,7 +7100,6 @@ pub const Statx = extern struct {
71067100

71077101
__pad2: [14]u64,
71087102

7109-
// COMMIT: add new StatxMask fields
71107103
// https://github.com/torvalds/linux/blob/755fa5b4fb36627796af19932a432d343220ec63/include/uapi/linux/stat.h#L203
71117104
/// matches STATX_* in kernel
71127105
pub const Mask = packed struct(u32) {
@@ -7164,7 +7157,6 @@ pub const Statx = extern struct {
71647157
};
71657158
};
71667159

7167-
// COMMIT: Statx as Packed Struct
71687160
// https://github.com/torvalds/linux/blob/755fa5b4fb36627796af19932a432d343220ec63/include/uapi/linux/stat.h#L248
71697161
/// matches STATX_ATTR_* in kernel
71707162
pub const Attr = packed struct(u64) {
@@ -8582,7 +8574,6 @@ pub const rlimit = extern struct {
85828574
/// DEPRECATED alias for Madvise
85838575
pub const MADV = Madvise;
85848576

8585-
// COMMIT: update MADV_* flags and type as enum
85868577
/// advice flags for `madvise`
85878578
/// matches MADV_* in kernel
85888579
pub const Madvise = enum(u32) {

0 commit comments

Comments
 (0)