Skip to content

Commit 57c6cfc

Browse files
ananglioannisg
authored andcommitted
nordic: Use hal/ in all inclusions of nrfx HAL header files
Header files of nrfx HALs are not supposed to be included directly but only with their names prepended with the hal/ directory (so that an inclusion of an nrfx HAL header clearly differs from an inclusion of an nrfx driver header). Signed-off-by: Andrzej Głąbek <[email protected]>
1 parent cacb529 commit 57c6cfc

File tree

12 files changed

+13
-15
lines changed

12 files changed

+13
-15
lines changed

boards/arm/nrf52840_pca10059/board.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66

77
#include <init.h>
8-
#include <nrf_power.h>
8+
#include <hal/nrf_power.h>
99

1010
static int board_nrf52840_pca10059_init(struct device *dev)
1111
{

drivers/clock_control/nrf_power_clock.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
#include <device.h>
1212
#include <drivers/clock_control.h>
1313
#include <sys/__assert.h>
14-
#include <nrf_clock.h>
14+
#include <hal/nrf_clock.h>
1515
#if defined(CONFIG_USB) && defined(CONFIG_SOC_NRF52840)
16-
#include <nrf_power.h>
16+
#include <hal/nrf_power.h>
1717
#include <drivers/clock_control/nrf_clock_control.h>
1818
#endif
1919

drivers/entropy/entropy_nrf5.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include <drivers/entropy.h>
99
#include <sys/atomic.h>
1010
#include <soc.h>
11-
#include "nrf_rng.h"
11+
#include <hal/nrf_rng.h>
1212

1313
/*
1414
* The nRF5 RNG HW has several characteristics that need to be taken

drivers/sensor/nrf5/temp_nrf5.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#include <drivers/sensor.h>
1010
#include <drivers/clock_control.h>
1111
#include <logging/log.h>
12-
#include <nrf_temp.h>
12+
#include <hal/nrf_temp.h>
1313

1414
LOG_MODULE_REGISTER(temp_nrf5, CONFIG_SENSOR_LOG_LEVEL);
1515

drivers/timer/nrf_rtc_timer.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#include <drivers/clock_control/nrf_clock_control.h>
1111
#include <drivers/timer/system_timer.h>
1212
#include <sys_clock.h>
13-
#include <nrf_rtc.h>
13+
#include <hal/nrf_rtc.h>
1414
#include <spinlock.h>
1515

1616
#define RTC NRF_RTC1

include/drivers/clock_control/nrf_clock_control.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#if defined(CONFIG_USB) && defined(CONFIG_SOC_NRF52840)
1111
#include <device.h>
1212
#endif
13-
#include <nrf_clock.h>
13+
#include <hal/nrf_clock.h>
1414

1515
/* TODO: move all these to clock_control.h ? */
1616

soc/arm/nordic_nrf/nrf51/power.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66
#include <zephyr.h>
77
#include <power/power.h>
8-
#include <nrf_power.h>
8+
#include <hal/nrf_power.h>
99

1010
#include <logging/log.h>
1111
LOG_MODULE_DECLARE(soc, CONFIG_SOC_LOG_LEVEL);

soc/arm/nordic_nrf/nrf51/soc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#include <kernel.h>
1717
#include <init.h>
1818
#include <nrfx.h>
19-
#include <nrf_power.h>
19+
#include <hal/nrf_power.h>
2020
#include <soc/nrfx_coredep.h>
2121
#include <logging/log.h>
2222

soc/arm/nordic_nrf/nrf52/power.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66
#include <zephyr.h>
77
#include <power/power.h>
8-
#include <nrf_power.h>
8+
#include <hal/nrf_power.h>
99

1010
#include <logging/log.h>
1111
LOG_MODULE_DECLARE(soc, CONFIG_SOC_LOG_LEVEL);

soc/arm/nordic_nrf/nrf52/soc.c

+1-3
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#include <init.h>
1717
#include <cortex_m/exc.h>
1818
#include <nrfx.h>
19-
#include <nrf_power.h>
19+
#include <hal/nrf_power.h>
2020
#include <soc/nrfx_coredep.h>
2121
#include <logging/log.h>
2222

@@ -39,8 +39,6 @@ extern void z_NmiInit(void);
3939
#error "Unknown SoC."
4040
#endif
4141

42-
#include <hal/nrf_power.h>
43-
4442
#define LOG_LEVEL CONFIG_SOC_LOG_LEVEL
4543
LOG_MODULE_REGISTER(soc);
4644

subsys/bluetooth/controller/ll_sw/nordic/hal/nrf5/cntr.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#define LOG_MODULE_NAME bt_ctlr_cntr
1414
#include "common/log.h"
1515
#include "hal/debug.h"
16-
#include "nrf_rtc.h"
16+
#include <nrfx/hal/nrf_rtc.h>
1717

1818
#ifndef NRF_RTC
1919
#define NRF_RTC NRF_RTC0

subsys/bluetooth/controller/ll_sw/nordic/hal/nrf5/ecb.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#include "common/log.h"
1818
#include "hal/debug.h"
1919

20-
#include "nrf_ecb.h"
20+
#include <nrfx/hal/nrf_ecb.h>
2121

2222
struct ecb_param {
2323
u8_t key[16];

0 commit comments

Comments
 (0)