From: Marcel Holtmann <marcel@holtmann.org>
To: SpoorthiX K <spoorthix.k@intel.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH] LE Ping: Changes implement LE Ping feature
Date: Sat, 29 Dec 2018 08:33:07 +0100 [thread overview]
Message-ID: <A06EFCA4-24CB-46B3-BCD5-AF7781B82E04@holtmann.org> (raw)
In-Reply-To: <1545970554-2316-1-git-send-email-spoorthix.k@intel.com>
Hi,
> As per the Core Specification 5.0, Volume 2, Part E, Section 7.3.94
> the following code changes implements HCI Write Authenticated Payload Timeout
> command for LE Ping feature.
>
> Signed-off-by: SpoorthiX <spoorthix.k@intel.com>
> ---
> include/net/bluetooth/hci.h | 6 +++
> include/net/bluetooth/mgmt.h | 9 +++++
> net/bluetooth/hci_event.c | 28 ++++++++++++++
> net/bluetooth/mgmt.c | 92 ++++++++++++++++++++++++++++++++++++++++++++
> 4 files changed, 135 insertions(+)
>
> diff --git a/include/net/bluetooth/hci.h b/include/net/bluetooth/hci.h
> index c36dc1e..c2a8080 100644
> --- a/include/net/bluetooth/hci.h
> +++ b/include/net/bluetooth/hci.h
> @@ -1130,6 +1130,12 @@ struct hci_cp_write_sc_support {
> __u8 support;
> } __packed;
>
> +#define HCI_OP_WRITE_AUTH_PAYLOAD_TO 0x0c7c
> +struct hci_cp_write_auth_payload_to {
> + __u16 conn_handle;
> + __u16 timeout;
> +} __packed;
> +
> #define HCI_OP_READ_LOCAL_OOB_EXT_DATA 0x0c7d
> struct hci_rp_read_local_oob_ext_data {
> __u8 status;
> diff --git a/include/net/bluetooth/mgmt.h b/include/net/bluetooth/mgmt.h
> index 9cee7dd..22c3052 100644
> --- a/include/net/bluetooth/mgmt.h
> +++ b/include/net/bluetooth/mgmt.h
> @@ -654,6 +654,15 @@ struct mgmt_cp_set_phy_confguration {
> } __packed;
> #define MGMT_SET_PHY_CONFIGURATION_SIZE 4
>
> +
> +#define MGMT_OP_WRITE_AUTH_PAYLOAD_TO 0x0046
> +struct mgmt_cp_write_auth_payload_to {
> + __le16 conn_handle;
> + __le16 auth_to;
> +} __packed;
> +#define MGMT_OP_WRITE_AUTH_PAYLOAD_TO_SIZE 4
there is no benefit for this kind of pass-through MGMT -> HCI. If you want to provide a default auth timeout that then gets programmed to every connection, fine, but this is of no use. bluetoothd will not track a connection and then change the auth timeout. And even if we would provide an API for that, then it would be done through the L2CAP socket that has an underlying HCI connection.
Regards
Marcel
prev parent reply other threads:[~2018-12-29 7:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-28 4:15 [PATCH] LE Ping: Changes implement LE Ping feature SpoorthiX K
2018-12-28 4:41 ` kbuild test robot
2018-12-29 7:33 ` Marcel Holtmann [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=A06EFCA4-24CB-46B3-BCD5-AF7781B82E04@holtmann.org \
--to=marcel@holtmann.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=spoorthix.k@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).