drivers: hwspinlock: constify config struct
`DEVICE_DT_INST_DEFINE` requires to pass pointer to the device's private constant data so make it const. Signed-off-by: Bartosz Bilas <bartosz.bilas@hotmail.com>
This commit is contained in:
parent
6e32f28a01
commit
ac9c74aa7c
1 changed files with 1 additions and 1 deletions
|
@ -136,7 +136,7 @@ static int sqn_hwspinlock_init(const struct device *dev)
|
||||||
|
|
||||||
#define SQN_HWSPINLOCK_INIT(idx) \
|
#define SQN_HWSPINLOCK_INIT(idx) \
|
||||||
static struct sqn_hwspinlock_data sqn_hwspinlock##idx##_data; \
|
static struct sqn_hwspinlock_data sqn_hwspinlock##idx##_data; \
|
||||||
static struct sqn_hwspinlock_config sqn_hwspinlock##idx##_config = { \
|
static const struct sqn_hwspinlock_config sqn_hwspinlock##idx##_config = { \
|
||||||
DEVICE_MMIO_ROM_INIT(DT_DRV_INST(idx)), \
|
DEVICE_MMIO_ROM_INIT(DT_DRV_INST(idx)), \
|
||||||
.num_locks = DT_INST_PROP(idx, num_locks), \
|
.num_locks = DT_INST_PROP(idx, num_locks), \
|
||||||
}; \
|
}; \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue