diff mbox series

[v1] Bluetooth: Fix the HCI to MGMT status conversion table

Message ID 20210419165323.v1.1.I9f9e8bcc849d91c1bb588a5181317c3e2ad48461@changeid (mailing list archive)
State Awaiting Upstream
Delegated to: Netdev Maintainers
Headers show
Series [v1] Bluetooth: Fix the HCI to MGMT status conversion table | expand

Checks

Context Check Description
netdev/cover_letter success Link
netdev/fixes_present success Link
netdev/patch_count success Link
netdev/tree_selection success Guessed tree name to be net-next
netdev/subject_prefix warning Target tree name not specified in the subject
netdev/cc_maintainers success CCed 7 of 7 maintainers
netdev/source_inline success Was 0 now: 0
netdev/verify_signedoff success Link
netdev/module_param success Was 0 now: 0
netdev/build_32bit fail Errors and warnings before: 426 this patch: 17
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/verify_fixes success Link
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 15 lines checked
netdev/build_allmodconfig_warn success Errors and warnings before: 2 this patch: 2
netdev/header_inline success Link

Commit Message

Yu Liu April 19, 2021, 11:53 p.m. UTC
0x2B, 0x31 and 0x33 are reserved for future use but were not present in
the HCI to MGMT conversion table, this caused the conversion to be
incorrect for the HCI status code greater than 0x2A.

Reviewed-by: Miao-chen Chou <mcchou@chromium.org>
Signed-off-by: Yu Liu <yudiliu@google.com>
---

Changes in v1:
- Initial change

 net/bluetooth/mgmt.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Yu Liu April 28, 2021, 11:05 p.m. UTC | #1
Ping for attention, thanks.


On Mon, Apr 19, 2021 at 4:53 PM Yu Liu <yudiliu@google.com> wrote:
>
> 0x2B, 0x31 and 0x33 are reserved for future use but were not present in
> the HCI to MGMT conversion table, this caused the conversion to be
> incorrect for the HCI status code greater than 0x2A.
>
> Reviewed-by: Miao-chen Chou <mcchou@chromium.org>
> Signed-off-by: Yu Liu <yudiliu@google.com>
> ---
>
> Changes in v1:
> - Initial change
>
>  net/bluetooth/mgmt.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
> index 40f75b8e1416..b44e19c69c44 100644
> --- a/net/bluetooth/mgmt.c
> +++ b/net/bluetooth/mgmt.c
> @@ -252,12 +252,15 @@ static const u8 mgmt_status_table[] = {
>         MGMT_STATUS_TIMEOUT,            /* Instant Passed */
>         MGMT_STATUS_NOT_SUPPORTED,      /* Pairing Not Supported */
>         MGMT_STATUS_FAILED,             /* Transaction Collision */
> +       MGMT_STATUS_FAILED,             /* Reserved for future use */
>         MGMT_STATUS_INVALID_PARAMS,     /* Unacceptable Parameter */
>         MGMT_STATUS_REJECTED,           /* QoS Rejected */
>         MGMT_STATUS_NOT_SUPPORTED,      /* Classification Not Supported */
>         MGMT_STATUS_REJECTED,           /* Insufficient Security */
>         MGMT_STATUS_INVALID_PARAMS,     /* Parameter Out Of Range */
> +       MGMT_STATUS_FAILED,             /* Reserved for future use */
>         MGMT_STATUS_BUSY,               /* Role Switch Pending */
> +       MGMT_STATUS_FAILED,             /* Reserved for future use */
>         MGMT_STATUS_FAILED,             /* Slot Violation */
>         MGMT_STATUS_FAILED,             /* Role Switch Failed */
>         MGMT_STATUS_INVALID_PARAMS,     /* EIR Too Large */
> --
> 2.31.1.368.gbe11c130af-goog
>
Marcel Holtmann April 29, 2021, 7:36 a.m. UTC | #2
Hi Yu,

> 0x2B, 0x31 and 0x33 are reserved for future use but were not present in
> the HCI to MGMT conversion table, this caused the conversion to be
> incorrect for the HCI status code greater than 0x2A.
> 
> Reviewed-by: Miao-chen Chou <mcchou@chromium.org>
> Signed-off-by: Yu Liu <yudiliu@google.com>
> ---
> 
> Changes in v1:
> - Initial change
> 
> net/bluetooth/mgmt.c | 3 +++
> 1 file changed, 3 insertions(+)

patch has been applied to bluetooth-next tree.

Regards

Marcel
diff mbox series

Patch

diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c
index 40f75b8e1416..b44e19c69c44 100644
--- a/net/bluetooth/mgmt.c
+++ b/net/bluetooth/mgmt.c
@@ -252,12 +252,15 @@  static const u8 mgmt_status_table[] = {
 	MGMT_STATUS_TIMEOUT,		/* Instant Passed */
 	MGMT_STATUS_NOT_SUPPORTED,	/* Pairing Not Supported */
 	MGMT_STATUS_FAILED,		/* Transaction Collision */
+	MGMT_STATUS_FAILED,		/* Reserved for future use */
 	MGMT_STATUS_INVALID_PARAMS,	/* Unacceptable Parameter */
 	MGMT_STATUS_REJECTED,		/* QoS Rejected */
 	MGMT_STATUS_NOT_SUPPORTED,	/* Classification Not Supported */
 	MGMT_STATUS_REJECTED,		/* Insufficient Security */
 	MGMT_STATUS_INVALID_PARAMS,	/* Parameter Out Of Range */
+	MGMT_STATUS_FAILED,		/* Reserved for future use */
 	MGMT_STATUS_BUSY,		/* Role Switch Pending */
+	MGMT_STATUS_FAILED,		/* Reserved for future use */
 	MGMT_STATUS_FAILED,		/* Slot Violation */
 	MGMT_STATUS_FAILED,		/* Role Switch Failed */
 	MGMT_STATUS_INVALID_PARAMS,	/* EIR Too Large */