From patchwork Sun Oct 1 10:57:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pauli Virtanen X-Patchwork-Id: 728603 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BFEE4E748ED for ; Sun, 1 Oct 2023 10:57:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234864AbjJAK53 (ORCPT ); Sun, 1 Oct 2023 06:57:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234839AbjJAK52 (ORCPT ); Sun, 1 Oct 2023 06:57:28 -0400 Received: from meesny.iki.fi (meesny.iki.fi [IPv6:2001:67c:2b0:1c1::201]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 70D18AC for ; Sun, 1 Oct 2023 03:57:23 -0700 (PDT) Received: from monolith.lan (91-152-120-176.elisa-laajakaista.fi [91.152.120.176]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: pav) by meesny.iki.fi (Postfix) with ESMTPSA id 4Rz1Hx7293zybZ; Sun, 1 Oct 2023 13:57:16 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1696157838; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=9BlBv/2Xp8qYvgYxs+dlophEqLLDcw2DVFjV3yp2+Vc=; b=q4EPvWZSMfH0+ieeUXODq93UTDe99vH5xFPvdk6twFoHy2S/cX4H6awCuOIYmUTw6x/ct9 yZqGAOeZQftaTtif20iqPHxWbLVtbIirkeGi5CAB0phLzYnLlDqCzBU5SVjevII8uS7wLO LT48VDVRKIKdvLAA2z0Oet6amD5PBDM= ARC-Seal: i=1; s=meesny; d=iki.fi; t=1696157838; a=rsa-sha256; cv=none; b=vjLyrtLPVIHt/DmKtoBt4ClQA2KhgrqwOHhGFPxQEM/qg8/Krv6R46fns3ZMoAS2gLURs1 hh8qCAdJkZKWrfRvY1mMCHkyXdepGMaqGjj68dgQ9BWjWEXjq6Uiq4uz7AqwoFqtaVxH1O i65WgIF/pfI5agSaOEN+2iAGOvrH1m0= ARC-Authentication-Results: i=1; ORIGINATING; auth=pass smtp.auth=pav smtp.mailfrom=pav@iki.fi ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1696157838; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=9BlBv/2Xp8qYvgYxs+dlophEqLLDcw2DVFjV3yp2+Vc=; b=mv6ccJZ4e7UVqqxpT4jAKbV8nAUgoxmO7vHlByjYYyyIFQnLktQDZqaqxqyDO6HnaCBjsA 6rpNU+EtAIx0+whHoiF574Hdyt3FmqMW/seqBKxBPr0bHKdtTcuFxOMrXPHYOMx0P1NyTs GD4lfdFY8XY+jszj7uaUjFAWHNdwFkI= From: Pauli Virtanen To: linux-bluetooth@vger.kernel.org Cc: Pauli Virtanen Subject: [PATCH BlueZ 1/2] bap: use documented MediaEndpoint property names consistently Date: Sun, 1 Oct 2023 13:57:14 +0300 Message-ID: <3358dfd1591df242507755cea63d00db3d2c959e.1696157794.git.pav@iki.fi> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Use the documented name "MaximumLatency" for the MediaEndpoint QoS Max_Transport_Latency field, in SelectProperties input parameters and expected client MediaEndpoint properties. Use the name "Locations" for SelectProperties supported locations input parameter, to match the MediaEndpoint property name which indicates the same thing. --- profiles/audio/media.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/profiles/audio/media.c b/profiles/audio/media.c index 8345487d7..85ece47c4 100644 --- a/profiles/audio/media.c +++ b/profiles/audio/media.c @@ -965,7 +965,7 @@ static int pac_select(struct bt_bap_pac *lpac, struct bt_bap_pac *rpac, loc = bt_bap_pac_get_locations(rpac); if (loc) - g_dbus_dict_append_entry(&dict, "Location", DBUS_TYPE_UINT32, + g_dbus_dict_append_entry(&dict, "Locations", DBUS_TYPE_UINT32, &loc); if (metadata) { @@ -983,8 +983,8 @@ static int pac_select(struct bt_bap_pac *lpac, struct bt_bap_pac *rpac, g_dbus_dict_append_entry(&dict, "PHY", DBUS_TYPE_BYTE, &qos->phy); - g_dbus_dict_append_entry(&dict, "Latency", DBUS_TYPE_UINT16, - &qos->latency); + g_dbus_dict_append_entry(&dict, "MaximumLatency", + DBUS_TYPE_UINT16, &qos->latency); g_dbus_dict_append_entry(&dict, "MinimumDelay", DBUS_TYPE_UINT32, &qos->pd_min); @@ -2749,7 +2749,7 @@ static void app_register_endpoint(void *data, void *user_data) dbus_message_iter_get_basic(&iter, &qos.phy); } - if (g_dbus_proxy_get_property(proxy, "Latency", &iter)) { + if (g_dbus_proxy_get_property(proxy, "MaximumLatency", &iter)) { if (dbus_message_iter_get_arg_type(&iter) != DBUS_TYPE_UINT16) goto fail; From patchwork Sun Oct 1 10:57:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pauli Virtanen X-Patchwork-Id: 728372 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D1E9AE748E9 for ; Sun, 1 Oct 2023 10:57:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234848AbjJAK53 (ORCPT ); Sun, 1 Oct 2023 06:57:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42886 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234821AbjJAK52 (ORCPT ); Sun, 1 Oct 2023 06:57:28 -0400 Received: from meesny.iki.fi (meesny.iki.fi [IPv6:2001:67c:2b0:1c1::201]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71D86BD for ; Sun, 1 Oct 2023 03:57:23 -0700 (PDT) Received: from monolith.lan (91-152-120-176.elisa-laajakaista.fi [91.152.120.176]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: pav) by meesny.iki.fi (Postfix) with ESMTPSA id 4Rz1Hy21jHzydx; Sun, 1 Oct 2023 13:57:18 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1696157838; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eQ35q/P4+CU7zo6R1n/oJ2rODTOjJ+sM4iTry9nzjoo=; b=d+GYrNxR/T/ArLeC3Yer2uGotkB8qDc5Eqtz0NLRt9DG+R4RyCU+K1Rfy2p7T1HJ8ftRv5 rZXWOD2puaDbxIhjNcIZRZ/qaDhc0Z0/qvfsKRyE8kP7MiE2MS8NFTsVcssmVMS06wW+hk RnCgMo7xJBIMrYp3bPlKIXupKksV3aQ= ARC-Seal: i=1; s=meesny; d=iki.fi; t=1696157838; a=rsa-sha256; cv=none; b=nyNAD7MDctjRYPf7LcfVQR8CUnxE3wDv3zHHXPATeN9r+T6QuGdGWtrkOPsDiniaXodp0a fDH7dkgIQ/OIQ76w13y/2u4TcTt5jJ7djICKOLofayChuSHMH3CsX+8OHbYp1ijft+EQJn MwVSJ8qxuEy5tcPaBlUwuZZFw24d1QA= ARC-Authentication-Results: i=1; ORIGINATING; auth=pass smtp.auth=pav smtp.mailfrom=pav@iki.fi ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=meesny; t=1696157838; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eQ35q/P4+CU7zo6R1n/oJ2rODTOjJ+sM4iTry9nzjoo=; b=CUP7rTQSMtjYCHFivot5wx71cRNSGkvrpS2cVGwIXZ5qHZSr4kCYxbYVfUwHfGBe6UHlqp +nFykwGmp7d+NEMj+4r3IN9u+WKxITBIJXFxIfvTChnEukkIBANppRFr7inXIfYvax1ClD kYgtsNNuvUESJzaBqJUztJ0l9cg+MRA= From: Pauli Virtanen To: linux-bluetooth@vger.kernel.org Cc: Pauli Virtanen Subject: [PATCH BlueZ 2/2] doc: clarify org.bluez.MediaEndpoint documentation Date: Sun, 1 Oct 2023 13:57:15 +0300 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <3358dfd1591df242507755cea63d00db3d2c959e.1696157794.git.pav@iki.fi> References: <3358dfd1591df242507755cea63d00db3d2c959e.1696157794.git.pav@iki.fi> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Document the actual input and output parameter values used in SelectProperties. These differ from SetConfiguration. Mention SelectProperties is used for unicast only. Document SetConfiguration input parameters. --- doc/org.bluez.MediaEndpoint.rst | 42 ++++++++++++++++++++++++++------- 1 file changed, 34 insertions(+), 8 deletions(-) diff --git a/doc/org.bluez.MediaEndpoint.rst b/doc/org.bluez.MediaEndpoint.rst index 0e201ff9d..11b7280bd 100644 --- a/doc/org.bluez.MediaEndpoint.rst +++ b/doc/org.bluez.MediaEndpoint.rst @@ -24,14 +24,24 @@ Interface Methods ------- +.. _SetConfiguration: + void SetConfiguration(object transport, dict properties) ```````````````````````````````````````````````````````` Set configuration for the transport. - For client role transport must be set with a server endpoint oject which - will be configured and the properties must contain the following - properties: + :object transport: + + Configured transport object. + + :dict properties: + + Configured **org.bluez.MediaTransport(5)** properties. + + For client role transport must be set with a server endpoint + object which will be configured and the properties must + contain the following properties: :array{byte} Capabilities [Mandatory]: @@ -59,13 +69,29 @@ array{byte} SelectConfiguration(array{byte} capabilities) dict SelectProperties(dict capabilities) ```````````````````````````````````````` - Select configuration from the supported capabilities: + Select BAP unicast configuration from the supported capabilities: - :object Endpoint [ISO only]: - :Refer to SetConfiguration for the list of other possible properties.: + :object Endpoint: + :array{byte} Capabilities: + :array{byte} Metadata: + :uint32 Locations: + :byte Framing: + :byte PHY: + :uint16 MaximumLatency: + :uint32 MinimumDelay: + :uint32 MaximumDelay: + :uint32 PreferredMinimumDelay: + :uint32 PreferredMaximumDelay: - Returns a configuration which can be used to setup a transport, see - **org.bluez.MediaTransport(5)** for possible values. + See `MediaEndpoint Properties`_ for their possible values. + + Returns a configuration which can be used to setup a transport: + + :array{byte} Capabilities: + :array{byte} Metadata [optional]: + :dict QoS: + + See `SetConfiguration`_ for their possible values. Note: There is no need to cache the selected properties since on success the configuration is send back as parameter of SetConfiguration.