Skip to content

Commit

Permalink
[nrf noup] dts: Select SoftDevice Controller DTS binding as default
Browse files Browse the repository at this point in the history
The SoftDevice Controller is a different controller than
the open source link layer with a different set of quirks.
It should therefore have its own device tree binding.

This commit converts the SoftDevice Controller driver
to use this new DTS binding instead of reusing the existing one.

This commit updates or adds additional overlays for
existing samples, applications and tests that were using the
open source link layer.

Signed-off-by: Rubin Gerritsen <[email protected]>
  • Loading branch information
rugeGerritsen authored and carlescufi committed Nov 22, 2024
1 parent 4d768de commit 49004d0
Show file tree
Hide file tree
Showing 63 changed files with 365 additions and 120 deletions.
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52805.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -97,12 +97,13 @@
status = "okay";
ble-2mbps-supported;

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52810.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -101,12 +101,13 @@
status = "okay";
ble-2mbps-supported;

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52811.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -113,12 +113,13 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52820.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
/ {

chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -115,12 +115,13 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK another Bluetooth controller
* is added and set as the default.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52832.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -101,12 +101,13 @@
status = "okay";
ble-2mbps-supported;

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52833.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -115,12 +115,13 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf52840.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &cryptocell;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -103,12 +103,13 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
11 changes: 6 additions & 5 deletions dts/arm/nordic/nrf5340_cpunet.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &rng;
zephyr,flash-controller = &flash_controller;
};
Expand Down Expand Up @@ -102,12 +102,13 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "okay";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "okay";
status = "disabled";
};
};

Expand Down
4 changes: 2 additions & 2 deletions dts/arm/nordic/nrf54h20_cpurad.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ wdt011: &cpurad_wdt011 {};

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
};

soc {
Expand Down Expand Up @@ -104,6 +104,6 @@ wdt011: &cpurad_wdt011 {};
status = "okay";
};

&bt_hci_controller {
&bt_hci_sdc {
status = "okay";
};
4 changes: 2 additions & 2 deletions dts/arm/nordic/nrf54l_05_10_15_cpuapp.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ nvic: &cpuapp_nvic {};

/ {
chosen {
zephyr,bt-hci = &bt_hci_controller;
zephyr,bt-hci = &bt_hci_sdc;
zephyr,entropy = &psa_rng;
};

Expand All @@ -31,7 +31,7 @@ nvic: &cpuapp_nvic {};
};
};

&bt_hci_controller {
&bt_hci_sdc {
status = "okay";
};

Expand Down
7 changes: 4 additions & 3 deletions dts/common/nordic/nrf54h20.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -428,9 +428,10 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "disabled";
};
bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "disabled";
Expand Down
8 changes: 5 additions & 3 deletions dts/common/nordic/nrf54l_05_10_15.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -234,9 +234,11 @@
status = "disabled";
};

/* Note: In the nRF Connect SDK the SoftDevice Controller
* is added and set as the default Bluetooth Controller.
*/
bt_hci_sdc: bt_hci_sdc {
compatible = "nordic,bt-hci-sdc";
status = "disabled";
};

bt_hci_controller: bt_hci_controller {
compatible = "zephyr,bt-hci-ll-sw-split";
status = "disabled";
Expand Down
4 changes: 3 additions & 1 deletion samples/bluetooth/bap_broadcast_sink/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,7 @@ tests:
- nrf52_bsim
- nrf52833dk/nrf52833
- nrf52840dongle/nrf52840
extra_args: OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
extra_args:
- OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
- SNIPPET="bt-ll-sw-split"
tags: bluetooth
4 changes: 3 additions & 1 deletion samples/bluetooth/bap_broadcast_source/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,7 @@ tests:
- nrf52_bsim
- nrf52833dk/nrf52833
- nrf52840dongle/nrf52840
extra_args: OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
extra_args:
- OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
- SNIPPET="bt-ll-sw-split"
tags: bluetooth
4 changes: 4 additions & 0 deletions samples/bluetooth/bap_broadcast_source/sysbuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ if(SB_CONFIG_NET_CORE_IMAGE_HCI_IPC)
CACHE INTERNAL ""
)

list(APPEND ${NET_APP}_SNIPPET ${SNIPPET})
list(APPEND ${NET_APP}_SNIPPET bt-ll-sw-split)
set(${NET_APP}_SNIPPET ${${NET_APP}_SNIPPET} CACHE STRING "" FORCE)

native_simulator_set_child_images(${DEFAULT_IMAGE} ${NET_APP})
endif()

Expand Down
4 changes: 3 additions & 1 deletion samples/bluetooth/bap_unicast_client/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,7 @@ tests:
- nrf52840dk/nrf52840
integration_platforms:
- nrf52dk/nrf52832
extra_args: OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
extra_args:
- OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
- SNIPPET="bt-ll-sw-split"
tags: bluetooth
4 changes: 4 additions & 0 deletions samples/bluetooth/bap_unicast_client/sysbuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ if(SB_CONFIG_NET_CORE_IMAGE_HCI_IPC)
CACHE INTERNAL ""
)

list(APPEND ${NET_APP}_SNIPPET ${SNIPPET})
list(APPEND ${NET_APP}_SNIPPET bt-ll-sw-split)
set(${NET_APP}_SNIPPET ${${NET_APP}_SNIPPET} CACHE STRING "" FORCE)

native_simulator_set_child_images(${DEFAULT_IMAGE} ${NET_APP})
endif()

Expand Down
4 changes: 3 additions & 1 deletion samples/bluetooth/bap_unicast_server/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,7 @@ tests:
- nrf52840dk/nrf52840
integration_platforms:
- nrf52dk/nrf52832
extra_args: OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
extra_args:
- OVERLAY_CONFIG=overlay-bt_ll_sw_split.conf
- SNIPPET="bt-ll-sw-split"
tags: bluetooth
4 changes: 4 additions & 0 deletions samples/bluetooth/bap_unicast_server/sysbuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ if(SB_CONFIG_NET_CORE_IMAGE_HCI_IPC)
CACHE INTERNAL ""
)

list(APPEND ${NET_APP}_SNIPPET ${SNIPPET})
list(APPEND ${NET_APP}_SNIPPET bt-ll-sw-split)
set(${NET_APP}_SNIPPET ${${NET_APP}_SNIPPET} CACHE STRING "" FORCE)

native_simulator_set_child_images(${DEFAULT_IMAGE} ${NET_APP})
endif()

Expand Down
4 changes: 3 additions & 1 deletion samples/bluetooth/beacon/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ tests:
- nrf52dk/nrf52832
- nrf54l15dk/nrf54l15/cpuapp
sample.bluetooth.beacon-coex:
extra_args: CONF_FILE="prj-coex.conf"
extra_args:
- CONF_FILE="prj-coex.conf"
- SNIPPET="bt-ll-sw-split"
harness: bluetooth
platform_allow:
- nrf52840dk/nrf52840
Expand Down
4 changes: 4 additions & 0 deletions samples/bluetooth/cap_initiator/sysbuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ if(SB_CONFIG_NET_CORE_IMAGE_HCI_IPC)
CACHE INTERNAL ""
)

list(APPEND ${NET_APP}_SNIPPET ${SNIPPET})
list(APPEND ${NET_APP}_SNIPPET bt-ll-sw-split)
set(${NET_APP}_SNIPPET ${${NET_APP}_SNIPPET} CACHE STRING "" FORCE)

native_simulator_set_child_images(${DEFAULT_IMAGE} ${NET_APP})
endif()

Expand Down
15 changes: 12 additions & 3 deletions samples/bluetooth/direction_finding_central/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,24 @@ tests:
- nrf52833dk/nrf52833
- nrf52833dk/nrf52820
- nrf5340dk/nrf5340/cpuapp
sample.bluetooth.direction_finding.central.aod:
sample.bluetooth.direction_finding.central.aod_with_controller:
harness: bluetooth
extra_args: OVERLAY_CONFIG="overlay-aod.conf"
extra_args:
- OVERLAY_CONFIG="overlay-aod.conf"
- SNIPPET="bt-ll-sw-split"
platform_allow:
- nrf52833dk/nrf52833
- nrf52833dk/nrf52820
- nrf5340dk/nrf5340/cpuapp
tags: bluetooth
integration_platforms:
- nrf52833dk/nrf52833
- nrf52833dk/nrf52820
sample.bluetooth.direction_finding.central.aod_host_only:
harness: bluetooth
extra_args:
- OVERLAY_CONFIG="overlay-aod.conf"
platform_allow:
- nrf5340dk/nrf5340/cpuapp
tags: bluetooth
integration_platforms:
- nrf5340dk/nrf5340/cpuapp
Loading

0 comments on commit 49004d0

Please sign in to comment.