Bluetooth: Don't mask ECDH related events if CONFIG_BT_ECC disabled
It is related to b904ad387f
.
This fixes checking ECDH related events in event mask.
If ECDH support is disabled in host, there is no need to check
if those are supported in the controller.
Signed-off-by: Mariusz Skamra <mariusz.skamra@codecoup.pl>
This commit is contained in:
parent
b7a5874830
commit
474b2b3e94
1 changed files with 2 additions and 1 deletions
|
@ -3825,7 +3825,8 @@ static int le_set_event_mask(void)
|
|||
* If "LE Read Local P-256 Public Key" and "LE Generate DH Key" are
|
||||
* supported we need to enable events generated by those commands.
|
||||
*/
|
||||
if ((BT_CMD_TEST(bt_dev.supported_commands, 34, 1)) &&
|
||||
if (IS_ENABLED(CONFIG_BT_ECC) &&
|
||||
(BT_CMD_TEST(bt_dev.supported_commands, 34, 1)) &&
|
||||
(BT_CMD_TEST(bt_dev.supported_commands, 34, 2))) {
|
||||
mask |= BT_EVT_MASK_LE_P256_PUBLIC_KEY_COMPLETE;
|
||||
mask |= BT_EVT_MASK_LE_GENERATE_DHKEY_COMPLETE;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue