Add RWF_APPEND to RWF_SUPPORTED to support Linux kernel 4.16.
[BZ #22947]
* bits/uio-ext.h (RWF_APPEND): New.
* sysdeps/unix/sysv/linux/bits/uio-ext.h (RWF_APPEND): Likewise.
* manual/llio.texi: Document RWF_APPEND.
* misc/tst-preadvwritev2-common.c (RWF_APPEND): New.
(RWF_SUPPORTED): Add RWF_APPEND.
+2018-04-03 H.J. Lu <hongjiu.lu@intel.com>
+
+ [BZ #22947]
+ * bits/uio-ext.h (RWF_APPEND): New.
+ * sysdeps/unix/sysv/linux/bits/uio-ext.h (RWF_APPEND): Likewise.
+ * manual/llio.texi: Document RWF_APPEND.
+ * misc/tst-preadvwritev2-common.c (RWF_APPEND): New.
+ (RWF_SUPPORTED): Add RWF_APPEND.
+
2018-04-03 Adhemerval Zanella <adhemerval.zanella@linaro.org>
[BZ #22391]
#define RWF_DSYNC 0x00000002 /* per-IO O_DSYNC. */
#define RWF_SYNC 0x00000004 /* per-IO O_SYNC. */
#define RWF_NOWAIT 0x00000008 /* per-IO nonblocking mode. */
+#define RWF_APPEND 0x00000010 /* per-IO O_APPEND. */
#endif /* sys/uio_ext.h */
@item RWF_NOWAIT
Use nonblocking mode for this operation; that is, this call to @code{preadv2}
will fail and set @code{errno} to @code{EAGAIN} if the operation would block.
+
+@item RWF_APPEND
+Per-IO synchronization as if the file was opened with @code{O_APPEND} flag.
@end vtable
When the source file is compiled with @code{_FILE_OFFSET_BITS == 64} the
#ifndef RWF_NOWAIT
# define RWF_NOWAIT 0
#endif
-#define RWF_SUPPORTED (RWF_HIPRI | RWF_DSYNC | RWF_SYNC | RWF_NOWAIT)
+#ifndef RWF_APPEND
+# define RWF_APPEND 0
+#endif
+#define RWF_SUPPORTED (RWF_HIPRI | RWF_DSYNC | RWF_SYNC | RWF_NOWAIT \
+ | RWF_APPEND)
/* Set the next bit from the mask of all supported flags. */
int invalid_flag = RWF_SUPPORTED != 0 ? __builtin_clz (RWF_SUPPORTED) : 2;
invalid_flag = 0x1 << ((sizeof (int) * CHAR_BIT) - invalid_flag);
#define RWF_DSYNC 0x00000002 /* per-IO O_DSYNC. */
#define RWF_SYNC 0x00000004 /* per-IO O_SYNC. */
#define RWF_NOWAIT 0x00000008 /* per-IO nonblocking mode. */
+#define RWF_APPEND 0x00000010 /* per-IO O_APPEND. */
__END_DECLS