drivers: constify all device instances
Run cocci script to constify device instances. Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
This commit is contained in:
parent
d75f00a513
commit
16062c2e5a
11 changed files with 14 additions and 14 deletions
|
@ -593,7 +593,7 @@ static int IRAM_ATTR i2c_esp32_transfer(const struct device *dev, struct i2c_msg
|
|||
|
||||
static void IRAM_ATTR i2c_esp32_isr(void *arg)
|
||||
{
|
||||
struct device *dev = (struct device *)arg;
|
||||
const struct device *dev = (const struct device *)arg;
|
||||
struct i2c_esp32_data *data = (struct i2c_esp32_data *const)(dev)->data;
|
||||
i2c_intr_event_t evt_type = I2C_INTR_EVENT_ERR;
|
||||
|
||||
|
|
|
@ -883,7 +883,7 @@ static int i2c_it8xxx2_transfer(const struct device *dev, struct i2c_msg *msgs,
|
|||
|
||||
static void i2c_it8xxx2_isr(void *arg)
|
||||
{
|
||||
struct device *dev = (struct device *)arg;
|
||||
const struct device *dev = (const struct device *)arg;
|
||||
struct i2c_it8xxx2_data *data = dev->data;
|
||||
const struct i2c_it8xxx2_config *config = dev->config;
|
||||
|
||||
|
|
|
@ -726,7 +726,7 @@ static int i2c_xec_transfer(const struct device *dev, struct i2c_msg *msgs,
|
|||
static void i2c_xec_bus_isr(void *arg)
|
||||
{
|
||||
#ifdef CONFIG_I2C_SLAVE
|
||||
struct device *dev = (struct device *)arg;
|
||||
const struct device *dev = (const struct device *)arg;
|
||||
const struct i2c_xec_config *config =
|
||||
(const struct i2c_xec_config *const) (dev->config);
|
||||
struct i2c_xec_data *data = dev->data;
|
||||
|
|
|
@ -801,7 +801,7 @@ static int i2c_xec_transfer(const struct device *dev, struct i2c_msg *msgs,
|
|||
static void i2c_xec_bus_isr(void *arg)
|
||||
{
|
||||
#ifdef CONFIG_I2C_SLAVE
|
||||
struct device *dev = (struct device *)arg;
|
||||
const struct device *dev = (const struct device *)arg;
|
||||
const struct i2c_xec_config *cfg =
|
||||
(const struct i2c_xec_config *const) (dev->config);
|
||||
struct i2c_xec_data *data = dev->data;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue