1.1 --- a/idl/opener_context.idl Sun Aug 01 00:07:29 2021 +0200
1.2 +++ b/idl/opener_context.idl Sun Aug 08 23:10:47 2021 +0200
1.3 @@ -1,7 +1,7 @@
1.4 -#include <systypes/base.h> /* offset_t */
1.5 +#include <systypes/base.h> /* flags_t, object_flags_t, offset_t */
1.6
1.7 /* An interface providing a way of opening filesystem objects relying on a
1.8 - dataspace. */
1.9 + dataspace to transfer filesystem paths. */
1.10
1.11 interface OpenerContext
1.12 {
1.13 @@ -14,7 +14,11 @@
1.14
1.15 [opcode(1)] void getfs(out cap fs);
1.16
1.17 - /* Obtain a file reference given a path written to the dataspace. */
1.18 + /* Obtain a file reference given a path written to the context's dataspace. */
1.19
1.20 - [opcode(12)] void open(in flags_t flags, out offset_t size, out cap file);
1.21 + [opcode(12)] void open(in flags_t flags, out offset_t size, out cap file,
1.22 + out object_flags_t object_flags);
1.23 };
1.24 +
1.25 +/* vim: tabstop=2 expandtab shiftwidth=2
1.26 +*/
2.1 --- a/include/systypes/base.h Sun Aug 01 00:07:29 2021 +0200
2.2 +++ b/include/systypes/base.h Sun Aug 08 23:10:47 2021 +0200
2.3 @@ -30,7 +30,7 @@
2.4 /* unsigned long is a 64-bit type.
2.5 See: pkg/l4re-core/l4sys/include/l4int.h */
2.6
2.7 -/* Types for file access and IPC operations. */
2.8 +/* Types for file access (access flags, offsets) and IPC operations. */
2.9
2.10 typedef unsigned long flags_t;
2.11 typedef unsigned long offset_t;
2.12 @@ -52,6 +52,16 @@
2.13 NOTIFY_PEER_CLOSED = 4
2.14 };
2.15
2.16 +/* Filesystem object properties. */
2.17 +
2.18 +typedef unsigned long object_flags_t;
2.19 +
2.20 +enum object_flags
2.21 +{
2.22 + OBJECT_SUPPORTS_MMAP = 1,
2.23 + OBJECT_HAS_SIZE = 2
2.24 +};
2.25 +
2.26 /* Equivalent types are defined in sys/types.h typically. In newlib, they are
2.27 defined in sys/_types.h if not defined elsewhere (such as in
2.28 machine/_types.h). */