Skip to content

Commit 573774a

Browse files
wboberjukkar
authored andcommitted
drivers/net/ieee802154: Change configuration prefix
This commit changes Kconfig prefix for ieee802154 drivers to IEEE802154_*. This is done for consistency with config prefixes used in other subsystems. Change-Id: Ibbb4d96d2b748f4f13135bde85304ec34c5a90a6 Signed-off-by: Wojciech Bober <[email protected]>
1 parent 8db13f9 commit 573774a

40 files changed

+141
-134
lines changed

boards/arm/frdm_k64f/pinmux.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ static int frdm_k64f_pinmux_init(struct device *dev)
5858
pinmux_pin_set(porte, 26, PORT_PCR_MUX(kPORT_MuxAsGpio));
5959
pinmux_pin_set(portb, 21, PORT_PCR_MUX(kPORT_MuxAsGpio));
6060

61-
#ifdef CONFIG_NXP_MCR20A
61+
#ifdef CONFIG_IEEE802154_MCR20A
6262
/* FRDM-MCR20A Reset (D5) */
6363
pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAsGpio));
6464
/* FRDM-MCR20A IRQ_B (D2) */

boards/x86/quark_se_c1000_devboard/Kconfig.defconfig

+9-9
Original file line numberDiff line numberDiff line change
@@ -46,26 +46,26 @@ endif
4646
config BLUETOOTH_MONITOR_ON_DEV_NAME
4747
default UART_QMSI_1_NAME if BLUETOOTH_DEBUG_MONITOR
4848

49-
if TI_CC2520_LEGACY || TI_CC2520 || TI_CC2520_RAW
49+
if IEEE802154_CC2520_LEGACY || IEEE802154_CC2520 || IEEE802154_CC2520_RAW
5050

5151
config SPI
5252
def_bool y
5353
config GPIO
5454
def_bool y
5555

56-
config TI_CC2520_SPI_DRV_NAME
56+
config IEEE802154_CC2520_SPI_DRV_NAME
5757
default SPI_1_NAME
58-
config TI_CC2520_SPI_FREQ
58+
config IEEE802154_CC2520_SPI_FREQ
5959
default 4
60-
config TI_CC2520_SPI_SLAVE
60+
config IEEE802154_CC2520_SPI_SLAVE
6161
default 1
6262

6363

6464
if GPIO_QMSI
6565

66-
config TI_CC2520_GPIO_0_NAME
66+
config IEEE802154_CC2520_GPIO_0_NAME
6767
default GPIO_QMSI_0_NAME
68-
config TI_CC2520_GPIO_1_NAME
68+
config IEEE802154_CC2520_GPIO_1_NAME
6969
default GPIO_QMSI_1_NAME
7070

7171
endif # GPIO_QMSI
@@ -77,14 +77,14 @@ config SPI_1_CS_GPIO_PORT
7777
default GPIO_QMSI_0_NAME
7878
config SPI_1_CS_GPIO_PIN
7979
default 11
80-
config TI_CC2520_GPIO_0_NAME
80+
config IEEE802154_CC2520_GPIO_0_NAME
8181
string
8282
default GPIO_QMSI_0_NAME
83-
config TI_CC2520_GPIO_1_NAME
83+
config IEEE802154_CC2520_GPIO_1_NAME
8484
string
8585
default GPIO_QMSI_1_NAME
8686
endif
8787

88-
endif # TI_CC2520_LEGACY || TI_CC2520 || TI_CC2520_RAW
88+
endif # IEEE802154_CC2520_LEGACY || IEEE802154_CC2520 || IEEE802154_CC2520_RAW
8989

9090
endif # BOARD_QUARK_SE_C1000_DEVBOARD

boards/x86/quark_se_c1000_devboard/board.c

+8-6
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
#include <device.h>
1111
#include <init.h>
1212

13-
#if defined(CONFIG_TI_CC2520_LEGACY) || \
14-
defined(CONFIG_TI_CC2520) || \
15-
defined(CONFIG_TI_CC2520_RAW)
13+
#if defined(CONFIG_IEEE802154_CC2520_LEGACY) || \
14+
defined(CONFIG_IEEE802154_CC2520) || \
15+
defined(CONFIG_IEEE802154_CC2520_RAW)
1616

1717
#include <ieee802154/cc2520.h>
1818
#include <gpio.h>
@@ -34,7 +34,7 @@ struct cc2520_gpio_configuration *cc2520_configure_gpios(void)
3434
GPIO_INT_ACTIVE_HIGH | GPIO_INT_DEBOUNCE);
3535
struct device *gpio;
3636

37-
gpio = device_get_binding(CONFIG_TI_CC2520_GPIO_1_NAME);
37+
gpio = device_get_binding(CONFIG_IEEE802154_CC2520_GPIO_1_NAME);
3838
gpio_pin_configure(gpio, cc2520_gpios[CC2520_GPIO_IDX_VREG_EN].pin,
3939
flags_noint_out);
4040
gpio_pin_configure(gpio, cc2520_gpios[CC2520_GPIO_IDX_RESET].pin,
@@ -43,7 +43,7 @@ struct cc2520_gpio_configuration *cc2520_configure_gpios(void)
4343
cc2520_gpios[CC2520_GPIO_IDX_VREG_EN].dev = gpio;
4444
cc2520_gpios[CC2520_GPIO_IDX_RESET].dev = gpio;
4545

46-
gpio = device_get_binding(CONFIG_TI_CC2520_GPIO_0_NAME);
46+
gpio = device_get_binding(CONFIG_IEEE802154_CC2520_GPIO_0_NAME);
4747
gpio_pin_configure(gpio, cc2520_gpios[CC2520_GPIO_IDX_SFD].pin,
4848
flags_int_in);
4949
gpio_pin_configure(gpio, cc2520_gpios[CC2520_GPIO_IDX_FIFOP].pin,
@@ -61,4 +61,6 @@ struct cc2520_gpio_configuration *cc2520_configure_gpios(void)
6161
return cc2520_gpios;
6262
}
6363

64-
#endif /* CONFIG_TI_CC2520_LEGACY || CONFIG_TI_CC2520 || CONFIG_TI_CC2520_RAW */
64+
#endif /* CONFIG_IEEE802154_CC2520_LEGACY || CONFIG_IEEE802154_CC2520 ||
65+
* CONFIG_IEEE802154_CC2520_RAW
66+
*/

boards/x86/quark_se_c1000_devboard/board.h

+6-4
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@
2121
#define LED0_GPIO_PORT CONFIG_GPIO_QMSI_0_NAME
2222
#define LED0_GPIO_PIN 25
2323

24-
#if defined(CONFIG_TI_CC2520_LEGACY) || \
25-
defined(CONFIG_TI_CC2520) || \
26-
defined(CONFIG_TI_CC2520_RAW)
24+
#if defined(CONFIG_IEEE802154_CC2520_LEGACY) || \
25+
defined(CONFIG_IEEE802154_CC2520) || \
26+
defined(CONFIG_IEEE802154_CC2520_RAW)
2727

2828
/* GPIO numbers where the TI cc2520 chip is connected to */
2929
#define CC2520_GPIO_VREG_EN 0 /* PIN ?, ATP_AON_INT0 (out) */
@@ -33,7 +33,9 @@
3333
#define CC2520_GPIO_CCA 6 /* PIN 6, GPIO6 (in) */
3434
#define CC2520_GPIO_SFD 29 /* PIN 33, GPIO29 (in) */
3535

36-
#endif /* CONFIG_TI_CC2520_LEGACY || CONFIG_TI_CC2520 || CONFIG_TI_CC2520_RAW */
36+
#endif /* CONFIG_IEEE802154_CC2520_LEGACY || CONFIG_IEEE802154_CC2520 ||
37+
* CONFIG_IEEE802154_CC2520_RAW
38+
*/
3739

3840
#if defined(CONFIG_USB)
3941
/* GPIO driver name */

drivers/ieee802154/Kconfig

+4-4
Original file line numberDiff line numberDiff line change
@@ -58,16 +58,16 @@ source "drivers/ieee802154/Kconfig.cc2520"
5858

5959
source "drivers/ieee802154/Kconfig.mcr20a"
6060

61-
menuconfig UPIPE_15_4
61+
menuconfig IEEE802154_UPIPE
6262
bool "UART PIPE fake radio driver support for QEMU"
6363
depends on BOARD_QEMU_X86
6464
select NETWORKING
6565
select UART_PIPE
6666
default n
6767

68-
config UPIPE_15_4_DRV_NAME
68+
config IEEE802154_UPIPE_DRV_NAME
6969
string "UART PIPE Driver name"
70-
default "upipe_15_4"
71-
depends on UPIPE_15_4
70+
default "IEEE802154_UPIPE"
71+
depends on IEEE802154_UPIPE
7272

7373
endmenu

drivers/ieee802154/Kconfig.cc2520

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,61 +1,61 @@
11
# Kconfig.cc2520 - TI CC2520 configuration options
22
#
33

4-
menuconfig TI_CC2520
4+
menuconfig IEEE802154_CC2520
55
bool "TI CC2520 Driver support"
66
depends on NETWORKING
77
select NET_L2_IEEE802154
88
default n
99

10-
menuconfig TI_CC2520_RAW
10+
menuconfig IEEE802154_CC2520_RAW
1111
bool "TI CC2520 Driver RAW channel"
1212
select NET_L2_RAW_CHANNEL
1313
default n
1414
help
15-
Enable TI_CC2520 driver with RAW channel
15+
Enable IEEE802154_CC2520 driver with RAW channel
1616

1717
The CC2520 driver with RAW channel allows to export radio interface
1818
over USB making an USB 802.15.4 dongle.
1919

20-
if TI_CC2520 || TI_CC2520_RAW
20+
if IEEE802154_CC2520 || IEEE802154_CC2520_RAW
2121

22-
config TI_CC2520_DRV_NAME
22+
config IEEE802154_CC2520_DRV_NAME
2323
string "TI CC2520 Driver's name"
2424
default "cc2520"
2525
help
2626
This option sets the driver name
2727

28-
config TI_CC2520_SPI_DRV_NAME
28+
config IEEE802154_CC2520_SPI_DRV_NAME
2929
string "SPI driver's name to use to access CC2520"
3030
default ""
3131
help
3232
This option is mandatory to set which SPI controller to use in order
3333
to actually control the CC2520 chip.
3434

35-
config TI_CC2520_SPI_FREQ
35+
config IEEE802154_CC2520_SPI_FREQ
3636
int "SPI system frequency"
3737
default 0
3838
help
3939
This option sets the SPI controller's frequency. Beware this value
4040
depends on the SPI controller being used and also on the system
4141
clock.
4242

43-
config TI_CC2520_SPI_SLAVE
43+
config IEEE802154_CC2520_SPI_SLAVE
4444
int "SPI slave linked to CC2520"
4545
default 0
4646
help
4747
This option sets the SPI slave number SPI controller has to switch
4848
to when dealing with CC2520 chip.
4949

50-
config TI_CC2520_RX_STACK_SIZE
50+
config IEEE802154_CC2520_RX_STACK_SIZE
5151
int "Driver's internal rx thread stack size"
5252
default 800
5353
help
5454
This option sets the driver's stack size for its internal rx thread.
5555
The default value should be sufficient, but in case it prooves to be
5656
a too little one, this option makes it easy to play with the size.
5757

58-
config TI_CC2520_INIT_PRIO
58+
config IEEE802154_CC2520_INIT_PRIO
5959
int "CC2520 intialization priority"
6060
default 80
6161
help

drivers/ieee802154/Kconfig.mcr20a

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,47 @@
11
# Kconfig.mcr20a - NXP MCR20A configuration options
22
#
33

4-
menuconfig NXP_MCR20A
4+
menuconfig IEEE802154_MCR20A
55
bool "NXP MCR20A Driver support"
66
depends on NETWORKING && SPI
77
select NET_L2_IEEE802154
88
default n
99

10-
menuconfig NXP_MCR20A_RAW
10+
menuconfig IEEE802154_MCR20A_RAW
1111
bool "NXP MCR20A Driver RAW channel"
1212
depends on SPI
1313
select NET_L2_RAW_CHANNEL
1414
default n
1515
help
16-
Enable NXP_MCR20A driver with RAW channel
16+
Enable IEEE802154_MCR20A driver with RAW channel
1717

1818
The MCR20A driver with RAW channel allows to export radio interface
1919
over USB making an USB 802.15.4 dongle.
2020

21-
if NXP_MCR20A || NXP_MCR20A_RAW
21+
if IEEE802154_MCR20A || IEEE802154_MCR20A_RAW
2222

23-
config NXP_MCR20A_DRV_NAME
23+
config IEEE802154_MCR20A_DRV_NAME
2424
string "NXP MCR20A Driver's name"
2525
default "mcr20a"
2626
help
2727
This option sets the driver name
2828

29-
config NXP_MCR20A_SPI_DRV_NAME
29+
config IEEE802154_MCR20A_SPI_DRV_NAME
3030
string "SPI driver's name to use to access MCR20A"
3131
default SPI_0_NAME
3232
help
3333
This option is mandatory to set which SPI controller to use in order
3434
to actually control the MCR20A chip.
3535

36-
config NXP_MCR20A_SPI_FREQ
36+
config IEEE802154_MCR20A_SPI_FREQ
3737
int "SPI system frequency"
3838
default 4000000
3939
help
4040
This option sets the SPI controller's frequency. Beware this value
4141
depends on the SPI controller being used and also on the system
4242
clock.
4343

44-
config NXP_MCR20A_SPI_SLAVE
44+
config IEEE802154_MCR20A_SPI_SLAVE
4545
int "SPI slave linked to MCR20A"
4646
default 0
4747
help
@@ -99,15 +99,15 @@ config MCR20A_CLK_OUT_32768HZ
9999

100100
endchoice
101101

102-
config NXP_MCR20A_RX_STACK_SIZE
102+
config IEEE802154_MCR20A_RX_STACK_SIZE
103103
int "Driver's internal rx thread stack size"
104104
default 800
105105
help
106106
This option sets the driver's stack size for its internal rx thread.
107107
The default value should be sufficient, but in case it proves to be
108108
a too little one, this option makes it easy to play with the size.
109109

110-
config NXP_MCR20A_INIT_PRIO
110+
config IEEE802154_MCR20A_INIT_PRIO
111111
int "MCR20A intialization priority"
112112
default 80
113113
help

drivers/ieee802154/Makefile

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
obj-$(CONFIG_TI_CC2520) += ieee802154_cc2520.o
2-
obj-$(CONFIG_TI_CC2520_RAW) += ieee802154_cc2520.o
3-
obj-$(CONFIG_UPIPE_15_4) += ieee802154_uart_pipe.o
4-
obj-$(CONFIG_NXP_MCR20A) += ieee802154_mcr20a.o
5-
obj-$(CONFIG_NXP_MCR20A_RAW) += ieee802154_mcr20a.o
1+
obj-$(CONFIG_IEEE802154_CC2520) += ieee802154_cc2520.o
2+
obj-$(CONFIG_IEEE802154_CC2520_RAW) += ieee802154_cc2520.o
3+
obj-$(CONFIG_IEEE802154_UPIPE) += ieee802154_uart_pipe.o
4+
obj-$(CONFIG_IEEE802154_MCR20A) += ieee802154_mcr20a.o
5+
obj-$(CONFIG_IEEE802154_MCR20A_RAW) += ieee802154_mcr20a.o

drivers/ieee802154/ieee802154_cc2520.c

+16-15
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,7 @@ static void cc2520_rx(int arg)
600600
goto flush;
601601
}
602602

603-
#if defined(CONFIG_TI_CC2520_RAW)
603+
#if defined(CONFIG_IEEE802154_CC2520_RAW)
604604
/**
605605
* Reserve 1 byte for length
606606
*/
@@ -615,7 +615,7 @@ static void cc2520_rx(int arg)
615615

616616
net_buf_frag_insert(buf, pkt_buf);
617617

618-
#if defined(CONFIG_TI_CC2520_RAW)
618+
#if defined(CONFIG_IEEE802154_CC2520_RAW)
619619
if (!read_rxfifo_content(&cc2520->spi, pkt_buf, pkt_len)) {
620620
SYS_LOG_ERR("No content read");
621621
goto flush;
@@ -651,7 +651,7 @@ static void cc2520_rx(int arg)
651651
goto out;
652652
}
653653

654-
#if defined(CONFIG_TI_CC2520_RAW)
654+
#if defined(CONFIG_IEEE802154_CC2520_RAW)
655655
net_buf_add_u8(pkt_buf, cc2520->lqi);
656656
#endif
657657

@@ -665,7 +665,7 @@ static void cc2520_rx(int arg)
665665

666666
net_analyze_stack("CC2520 Rx Fiber stack",
667667
(unsigned char *)cc2520->cc2520_rx_stack,
668-
CONFIG_TI_CC2520_RX_STACK_SIZE);
668+
CONFIG_IEEE802154_CC2520_RX_STACK_SIZE);
669669
continue;
670670
flush:
671671
_cc2520_print_exceptions(cc2520);
@@ -990,16 +990,17 @@ static inline int configure_spi(struct device *dev)
990990
struct cc2520_context *cc2520 = dev->driver_data;
991991
struct spi_config spi_conf = {
992992
.config = SPI_WORD(8),
993-
.max_sys_freq = CONFIG_TI_CC2520_SPI_FREQ,
993+
.max_sys_freq = CONFIG_IEEE802154_CC2520_SPI_FREQ,
994994
};
995995

996-
cc2520->spi.dev = device_get_binding(CONFIG_TI_CC2520_SPI_DRV_NAME);
996+
cc2520->spi.dev = device_get_binding(
997+
CONFIG_IEEE802154_CC2520_SPI_DRV_NAME);
997998
if (!cc2520->spi.dev) {
998999
SYS_LOG_ERR("Unable to get SPI device");
9991000
return -ENODEV;
10001001
}
10011002

1002-
cc2520->spi.slave = CONFIG_TI_CC2520_SPI_SLAVE;
1003+
cc2520->spi.slave = CONFIG_IEEE802154_CC2520_SPI_SLAVE;
10031004

10041005
if (spi_configure(cc2520->spi.dev, &spi_conf) != 0 ||
10051006
spi_slave_select(cc2520->spi.dev,
@@ -1037,7 +1038,7 @@ static int cc2520_init(struct device *dev)
10371038
}
10381039

10391040
k_thread_spawn(cc2520->cc2520_rx_stack,
1040-
CONFIG_TI_CC2520_RX_STACK_SIZE,
1041+
CONFIG_IEEE802154_CC2520_RX_STACK_SIZE,
10411042
(k_thread_entry_t)cc2520_rx,
10421043
dev, NULL, NULL,
10431044
K_PRIO_COOP(2), 0, 0);
@@ -1080,21 +1081,21 @@ static struct ieee802154_radio_api cc2520_radio_api = {
10801081
.get_lqi = cc2520_get_lqi,
10811082
};
10821083

1083-
#if defined(CONFIG_TI_CC2520_RAW)
1084-
DEVICE_AND_API_INIT(cc2520, CONFIG_TI_CC2520_DRV_NAME,
1084+
#if defined(CONFIG_IEEE802154_CC2520_RAW)
1085+
DEVICE_AND_API_INIT(cc2520, CONFIG_IEEE802154_CC2520_DRV_NAME,
10851086
cc2520_init, &cc2520_context_data, NULL,
1086-
POST_KERNEL, CONFIG_TI_CC2520_INIT_PRIO,
1087+
POST_KERNEL, CONFIG_IEEE802154_CC2520_INIT_PRIO,
10871088
&cc2520_radio_api);
10881089
#else
1089-
NET_DEVICE_INIT(cc2520, CONFIG_TI_CC2520_DRV_NAME,
1090+
NET_DEVICE_INIT(cc2520, CONFIG_IEEE802154_CC2520_DRV_NAME,
10901091
cc2520_init, &cc2520_context_data, NULL,
1091-
CONFIG_TI_CC2520_INIT_PRIO,
1092+
CONFIG_IEEE802154_CC2520_INIT_PRIO,
10921093
&cc2520_radio_api, IEEE802154_L2,
10931094
NET_L2_GET_CTX_TYPE(IEEE802154_L2), 125);
10941095

10951096
NET_STACK_INFO_ADDR(RX, cc2520,
1096-
CONFIG_TI_CC2520_RX_STACK_SIZE,
1097-
CONFIG_TI_CC2520_RX_STACK_SIZE,
1097+
CONFIG_IEEE802154_CC2520_RX_STACK_SIZE,
1098+
CONFIG_IEEE802154_CC2520_RX_STACK_SIZE,
10981099
((struct cc2520_context *)(&__device_cc2520))->
10991100
cc2520_rx_stack,
11001101
0);

0 commit comments

Comments
 (0)