drivers: Manual const-ification of device driver instance
These are all the case that coccinelle cannot find as they are inside macro declarations. Fixed via: git grep -rlz -E "\(struct device \*" | xargs -0 sed -i 's/(struct device/(const struct device/g' Fixes #27399 Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
This commit is contained in:
parent
26cbd6a58c
commit
ef560e0a53
62 changed files with 142 additions and 143 deletions
|
@ -615,7 +615,7 @@ static const struct i2s_driver_api i2s_litex_driver_api = {
|
|||
sizeof(dir##_ring_buf) / sizeof(struct queue_item), \
|
||||
}; \
|
||||
\
|
||||
static void i2s_litex_irq_config_func_##dir(struct device *dev); \
|
||||
static void i2s_litex_irq_config_func_##dir(const struct device *dev); \
|
||||
\
|
||||
static struct i2s_litex_cfg i2s_litex_cfg_##dir = { \
|
||||
.base = DT_REG_ADDR_BY_NAME(DT_NODELABEL(i2s_##dir), control), \
|
||||
|
@ -630,7 +630,7 @@ static const struct i2s_driver_api i2s_litex_driver_api = {
|
|||
CONFIG_I2S_INIT_PRIORITY, \
|
||||
&i2s_litex_driver_api); \
|
||||
\
|
||||
static void i2s_litex_irq_config_func_##dir(struct device *dev) \
|
||||
static void i2s_litex_irq_config_func_##dir(const struct device *dev) \
|
||||
{ \
|
||||
IRQ_CONNECT(DT_IRQN(DT_NODELABEL(i2s_##dir)), \
|
||||
DT_IRQ(DT_NODELABEL(i2s_##dir), \
|
||||
|
|
|
@ -888,7 +888,7 @@ static const struct device *get_dev_from_tx_dma_channel(uint32_t dma_channel)
|
|||
#define I2S_INIT(index, clk_sel) \
|
||||
DEVICE_DECLARE(i2s_stm32_##index); \
|
||||
\
|
||||
static void i2s_stm32_irq_config_func_##index(struct device *dev); \
|
||||
static void i2s_stm32_irq_config_func_##index(const struct device *dev); \
|
||||
\
|
||||
static const struct i2s_stm32_cfg i2s_stm32_config_##index = { \
|
||||
.i2s = (SPI_TypeDef *) DT_REG_ADDR(DT_NODELABEL(i2s##index)), \
|
||||
|
@ -915,7 +915,7 @@ DEVICE_AND_API_INIT(i2s_stm32_##index, \
|
|||
&i2s_stm32_config_##index, POST_KERNEL, \
|
||||
CONFIG_I2S_INIT_PRIORITY, &i2s_stm32_driver_api); \
|
||||
\
|
||||
static void i2s_stm32_irq_config_func_##index(struct device *dev) \
|
||||
static void i2s_stm32_irq_config_func_##index(const struct device *dev) \
|
||||
{ \
|
||||
IRQ_CONNECT(DT_IRQN(DT_NODELABEL(i2s##index)), \
|
||||
DT_IRQ(DT_NODELABEL(i2s##index), priority), \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue