X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Flibsystemd-bus%2Fkdbus.h;h=168d08a3ec1d20c220898df3dbbe705633880925;hb=d90bb66996f5e3e9b6987e60980ff721b6fc2aff;hp=bded4dc68dd2358c934524d6b44ef0029d899ff3;hpb=9bb59c29f009079d871027686a72f091abd6a2a7;p=elogind.git diff --git a/src/libsystemd-bus/kdbus.h b/src/libsystemd-bus/kdbus.h index bded4dc68..168d08a3e 100644 --- a/src/libsystemd-bus/kdbus.h +++ b/src/libsystemd-bus/kdbus.h @@ -30,7 +30,8 @@ * struct kdbus_notify_name_change - name registry change message * @old_id: Former owner of a name * @new_id: New owner of a name - * @flags: flags from KDBUS_NAME_* + * @old_flags: flags from KDBUS_NAME_* the name entry used to have + * @new_flags: flags from KDBUS_NAME_* the name entry has now * @name: Well-known name * * Sent from kernel to userspace when the owner or starter of @@ -44,7 +45,8 @@ struct kdbus_notify_name_change { __u64 old_id; __u64 new_id; - __u64 flags; + __u64 old_flags; + __u64 new_flags; char name[0]; }; @@ -330,7 +332,7 @@ enum kdbus_msg_flags { */ enum kdbus_payload_type { KDBUS_PAYLOAD_KERNEL, - KDBUS_PAYLOAD_DBUS = 0x4442757356657231ULL, /* 'DBusVer1' */ + KDBUS_PAYLOAD_DBUS = 0x4442757344427573ULL, /* 'DBusDBus' */ }; /** @@ -485,8 +487,7 @@ enum kdbus_make_flags { * @bloom_size: Size of the bloom filter for this bus * @items: Items describing details such as the name of the bus * - * This structure is used with the KDBUS_CMD_BUS_MAKE ioctl. Refer to the - * documentation for more information. + * This structure is used with the KDBUS_CMD_BUS_MAKE ioctl. */ struct kdbus_cmd_bus_make { __u64 size; @@ -502,8 +503,7 @@ struct kdbus_cmd_bus_make { * @items: Items describing details such as the * name of the endpoint * - * This structure is used with the KDBUS_CMD_EP_MAKE ioctl. Refer to the - * documentation for more information. + * This structure is used with the KDBUS_CMD_EP_MAKE ioctl. */ struct kdbus_cmd_ep_make { __u64 size; @@ -518,8 +518,7 @@ struct kdbus_cmd_ep_make { * @items: Items describing details such as the * name of the namespace * - * This structure is used with the KDBUS_CMD_NS_MAKE ioctl. Refer to the - * documentation for more information. + * This structure is used with the KDBUS_CMD_NS_MAKE ioctl. */ struct kdbus_cmd_ns_make { __u64 size; @@ -530,18 +529,17 @@ struct kdbus_cmd_ns_make { /** * enum kdbus_name_flags - properties of a well-known name * @KDBUS_NAME_REPLACE_EXISTING: Try to replace name of other connections - * @KDBUS_NAME_QUEUE: Name should be queued if busy * @KDBUS_NAME_ALLOW_REPLACEMENT: Allow the replacement of the name + * @KDBUS_NAME_QUEUE: Name should be queued if busy * @KDBUS_NAME_IN_QUEUE: Name is queued + * @KDBUS_NAME_STARTER: Name is owned by a starter connection */ enum kdbus_name_flags { - /* userspace → kernel */ KDBUS_NAME_REPLACE_EXISTING = 1 << 0, - KDBUS_NAME_QUEUE = 1 << 1, - KDBUS_NAME_ALLOW_REPLACEMENT = 1 << 2, - - /* kernel → userspace */ - KDBUS_NAME_IN_QUEUE = 1 << 16, + KDBUS_NAME_ALLOW_REPLACEMENT = 1 << 1, + KDBUS_NAME_QUEUE = 1 << 2, + KDBUS_NAME_IN_QUEUE = 1 << 3, + KDBUS_NAME_STARTER = 1 << 4, }; /** @@ -554,7 +552,6 @@ enum kdbus_name_flags { * @name: The well-known name * * This structure is used with the KDBUS_CMD_NAME_ACQUIRE ioctl. - * Refer to the documentation for more information. */ struct kdbus_cmd_name { __u64 size; @@ -613,7 +610,7 @@ struct kdbus_name_list { * @name is required. kdbus will look up the name to determine * the ID in this case. * @offset: Returned offset in the caller's pool buffer where the - * kdbus_name_info struct result is stored. The user must + * kdbus_conn_info struct result is stored. The user must * use KDBUS_CMD_FREE to free the allocated memory. * @name: The optional well-known name to look up. Only needed in * case @id is zero. @@ -681,8 +678,7 @@ enum kdbus_match_type { * @items: A list of items for additional information * * This structure is used with the KDBUS_CMD_ADD_MATCH and - * KDBUS_CMD_REMOVE_MATCH ioctl. Refer to the documentation for more - * information. + * KDBUS_CMD_REMOVE_MATCH ioctl. */ struct kdbus_cmd_match { __u64 size; @@ -707,7 +703,6 @@ enum kdbus_monitor_flags { * @flags: Use KDBUS_MONITOR_ENABLE to enable eavesdropping * * This structure is used with the KDBUS_CMD_MONITOR ioctl. - * Refer to the documentation for more information. */ struct kdbus_cmd_monitor { __u64 id; @@ -817,6 +812,8 @@ enum kdbus_ioctl_type { /* * errno - api error codes * @E2BIG: A message contains too many records or items. + * @EADDRINUSE: A well-known bus name is already taken by another + * connection. * @EADDRNOTAVAIL: A message flagged not to activate a service, addressed * a service which is not currently running. * @EAGAIN: No messages are queued at the moment. @@ -824,8 +821,6 @@ enum kdbus_ioctl_type { * @EBADFD: A bus connection is in a corrupted state. * @EBADMSG: Passed data contains a combination of conflicting or * inconsistent types. - * @EBUSY: A well-known bus name is already taken by another - * connection. * @ECOMM: A peer does not accept the file descriptors addressed * to it. * @EDESTADDRREQ: The well-known bus name is required but missing.