Skip to content

Commit

Permalink
Bluetooth: Controller: Remove legacy BT_CTLR_FAST_ENC option
Browse files Browse the repository at this point in the history
When the legacy LLCP implementation was removed this Kconfig option was
mistakenly left over. Remove it now with all its users.

Fixes #63212.

(cherry picked from commit a5e7ba3)

Original-Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
GitOrigin-RevId: a5e7ba3
Change-Id: Ib3c3e5df900da7f112aa19d55fa78c2c0da8a2f3
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/4919281
Tested-by: ChromeOS Prod (Robot) <chromeos-ci-prod@chromeos-bot.iam.gserviceaccount.com>
Reviewed-by: Yuval Peress <peress@google.com>
Tested-by: Yuval Peress <peress@google.com>
Commit-Queue: Yuval Peress <peress@google.com>
  • Loading branch information
carlescufi authored and Chromeos LUCI committed Oct 6, 2023
1 parent 125a5d3 commit 6267205
Show file tree
Hide file tree
Showing 10 changed files with 1 addition and 36 deletions.
5 changes: 0 additions & 5 deletions drivers/entropy/entropy_nrf5.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,6 @@ static int random_byte_get(void)
return retval;
}

#pragma GCC push_options
#if defined(CONFIG_BT_CTLR_FAST_ENC)
#pragma GCC optimize ("Ofast")
#endif
static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf, uint16_t len)
{
uint32_t last = rngp->last;
Expand Down Expand Up @@ -175,7 +171,6 @@ static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf, uint16_t len)

return len;
}
#pragma GCC pop_options

static int rng_pool_put(struct rng_pool *rngp, uint8_t byte)
{
Expand Down
5 changes: 0 additions & 5 deletions drivers/entropy/entropy_smartbond.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,6 @@ static int random_word_get(uint8_t buf[4])
return retval;
}

#pragma GCC push_options
#if defined(CONFIG_BT_CTLR_FAST_ENC)
#pragma GCC optimize("Ofast")
#endif
static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf, uint16_t len)
{
uint32_t last = rngp->last;
Expand Down Expand Up @@ -159,7 +155,6 @@ static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf, uint16_t len)

return len;
}
#pragma GCC pop_options

static int rng_pool_put(struct rng_pool *rngp, uint8_t byte)
{
Expand Down
9 changes: 1 addition & 8 deletions drivers/entropy/entropy_stm32.c
Original file line number Diff line number Diff line change
Expand Up @@ -378,13 +378,7 @@ static void pool_filling_work_handler(struct k_work *work)
}
}

#if defined(CONFIG_BT_CTLR_FAST_ENC)
#define __fast __attribute__((optimize("Ofast")))
#else
#define __fast
#endif

__fast static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf,
static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf,
uint16_t len)
{
uint32_t last = rngp->last;
Expand Down Expand Up @@ -449,7 +443,6 @@ __fast static uint16_t rng_pool_get(struct rng_pool *rngp, uint8_t *buf,

return len;
}
#undef __fast

static int rng_pool_put(struct rng_pool *rngp, uint8_t byte)
{
Expand Down
12 changes: 0 additions & 12 deletions subsys/bluetooth/controller/Kconfig.ll_sw_split
Original file line number Diff line number Diff line change
Expand Up @@ -760,18 +760,6 @@ config BT_CTLR_PARAM_CHECK

if BT_CONN

config BT_CTLR_FAST_ENC
bool "Fast Encryption Setup"
depends on BT_CTLR_LE_ENC
default y if BT_HCI_RAW
help
Enable connection encryption setup in 4 connection events.
Peripheral will respond to Encryption Request with Encryption Response
in the next connection event, and will transmit Start Encryption
Request PDU in the same connection event, hence completing encryption
setup in 4 connection events. Encrypted data would be transmitted as
fast as in 4th connection event from Encryption Request.

config BT_CTLR_LLCP_CONN
int "Number of connections with worst-case overlapping procedures"
default BT_MAX_CONN
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_4_0.conf
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=y
CONFIG_BT_CTLR_SCHED_ADVANCED=y
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=n
CONFIG_BT_CTLR_TIFS_HW=y
CONFIG_BT_CTLR_FAST_ENC=n
CONFIG_BT_CTLR_CONN_RSSI=n
CONFIG_BT_CTLR_ADV_INDICATION=n
CONFIG_BT_CTLR_SCAN_REQ_NOTIFY=n
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_4_0_dbg.conf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=y
CONFIG_BT_CTLR_SCHED_ADVANCED=y
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=n
CONFIG_BT_CTLR_TIFS_HW=y
CONFIG_BT_CTLR_FAST_ENC=n
CONFIG_BT_CTLR_CONN_RSSI=n
CONFIG_BT_CTLR_ADV_INDICATION=n
CONFIG_BT_CTLR_SCAN_REQ_NOTIFY=n
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_5_x_dbg.conf
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=n
CONFIG_BT_CTLR_SCHED_ADVANCED=y
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=y
CONFIG_BT_CTLR_TIFS_HW=n
CONFIG_BT_CTLR_FAST_ENC=y
CONFIG_BT_CTLR_TX_RETRY_DISABLE=y
CONFIG_BT_CTLR_CONN_RSSI=y
CONFIG_BT_CTLR_ADV_INDICATION=y
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_dbg.conf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=n
CONFIG_BT_CTLR_SCHED_ADVANCED=n
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=y
CONFIG_BT_CTLR_TIFS_HW=n
CONFIG_BT_CTLR_FAST_ENC=y
CONFIG_BT_CTLR_TX_RETRY_DISABLE=y
CONFIG_BT_CTLR_CONN_RSSI=y
CONFIG_BT_CTLR_ADV_INDICATION=y
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_ticker.conf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=n
CONFIG_BT_CTLR_SCHED_ADVANCED=n
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=y
CONFIG_BT_CTLR_TIFS_HW=n
CONFIG_BT_CTLR_FAST_ENC=y
CONFIG_BT_CTLR_TX_RETRY_DISABLE=y
CONFIG_BT_CTLR_CONN_RSSI=y
CONFIG_BT_CTLR_ADV_INDICATION=y
Expand Down
1 change: 0 additions & 1 deletion tests/bluetooth/init/prj_ctlr_tiny.conf
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ CONFIG_BT_CTLR_XTAL_ADVANCED=n
CONFIG_BT_CTLR_SCHED_ADVANCED=n
CONFIG_BT_CTLR_RADIO_ENABLE_FAST=n
CONFIG_BT_CTLR_TIFS_HW=y
CONFIG_BT_CTLR_FAST_ENC=n
CONFIG_BT_CTLR_CONN_RSSI=n
CONFIG_BT_CTLR_ADV_INDICATION=n
CONFIG_BT_CTLR_SCAN_REQ_NOTIFY=n
Expand Down

0 comments on commit 6267205

Please sign in to comment.