Browse Source

drivers: lora: Place API into iterable section

Add wrapper DEVICE_API macro to all lora_driver_api instances.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
pull/82446/head
Pieter De Gendt 7 months ago committed by Benjamin Cabé
parent
commit
9518dbf3e0
  1. 2
      drivers/lora/rylrxxx.c
  2. 2
      drivers/lora/sx126x.c
  3. 2
      drivers/lora/sx127x.c

2
drivers/lora/rylrxxx.c

@ -664,7 +664,7 @@ static int rylr_init(const struct device *dev) @@ -664,7 +664,7 @@ static int rylr_init(const struct device *dev)
return err;
}
static const struct lora_driver_api rylr_lora_api = {
static DEVICE_API(lora, rylr_lora_api) = {
.config = rylr_config,
.send = rylr_send,
.send_async = rylr_send_async,

2
drivers/lora/sx126x.c

@ -463,7 +463,7 @@ static int sx126x_lora_init(const struct device *dev) @@ -463,7 +463,7 @@ static int sx126x_lora_init(const struct device *dev)
return 0;
}
static const struct lora_driver_api sx126x_lora_api = {
static DEVICE_API(lora, sx126x_lora_api) = {
.config = sx12xx_lora_config,
.send = sx12xx_lora_send,
.send_async = sx12xx_lora_send_async,

2
drivers/lora/sx127x.c

@ -625,7 +625,7 @@ static int sx127x_lora_init(const struct device *dev) @@ -625,7 +625,7 @@ static int sx127x_lora_init(const struct device *dev)
return 0;
}
static const struct lora_driver_api sx127x_lora_api = {
static DEVICE_API(lora, sx127x_lora_api) = {
.config = sx12xx_lora_config,
.send = sx12xx_lora_send,
.send_async = sx12xx_lora_send_async,

Loading…
Cancel
Save