1io_uring_prep_unlinkat(3)       liburing Manual      io_uring_prep_unlinkat(3)
2
3
4

NAME

6       io_uring_prep_unlinkat - prepare an unlinkat request
7

SYNOPSIS

9       #include <fcntl.h>
10       #include <unistd.h>
11       #include <liburing.h>
12
13       void io_uring_prep_unlinkat(struct io_uring_sqe *sqe,
14                                   int dirfd,
15                                   const char *path,
16                                   int flags);
17
18       void io_uring_prep_unlink(struct io_uring_sqe *sqe,
19                                 const char *path,
20                                 int flags);
21

DESCRIPTION

23       The  io_uring_prep_unlinkat(3)  function  prepares an unlinkat request.
24       The submission queue entry sqe is setup to use the directory  file  de‐
25       scriptor pointed to by dirfd to start an unlinkat operation on the path
26       identified by path and using the flags given in flags.
27
28       The io_uring_prep_unlink(3) function prepares an  unlink  request.  The
29       submission  queue  entry sqe is setup to start an unlinkat operation on
30       the path identified by path relative to the current  working  directory
31       and using the flags given in flags.
32
33       These  functions prepare an async unlinkat(2) or unlink(2) request. See
34       those man pages for details.
35
36

RETURN VALUE

38       None
39

ERRORS

41       The CQE res field will contain the result of the operation. See the re‐
42       lated man page for details on possible values. Note that where synchro‐
43       nous system calls will return -1 on failure and set errno to the actual
44       error value, io_uring never uses errno.  Instead it returns the negated
45       errno directly in the CQE res field.
46

NOTES

48       As with any request that passes in data in a struct, that data must re‐
49       main  valid  until the request has been successfully submitted. It need
50       not remain valid until completion. Once a request has  been  submitted,
51       the in-kernel state is stable. Very early kernels (5.4 and earlier) re‐
52       quired state to be stable until the completion  occurred.  Applications
53       can  test for this behavior by inspecting the IORING_FEAT_SUBMIT_STABLE
54       flag passed back from io_uring_queue_init_params(3).
55

SEE ALSO

57       io_uring_get_sqe(3), io_uring_submit(3), unlinkat(2), unlink(2)
58
59
60
61liburing-2.2                    March 13, 2022       io_uring_prep_unlinkat(3)
Impressum