device: Fix structure attributes access
Since struct devconfig was merged earlier into struct device, let's fix accessing config_info, name, ... attributes everywhere via: grep -rlZ 'dev->config->' | xargs -0 sed -i 's/dev->config->/dev->/g' Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
This commit is contained in:
parent
8d7bb8ffd8
commit
97326c0445
348 changed files with 1155 additions and 1174 deletions
|
@ -100,7 +100,7 @@ struct gpio_pca95xx_drv_data {
|
|||
static int read_port_regs(struct device *dev, u8_t reg, u16_t *buf)
|
||||
{
|
||||
const struct gpio_pca95xx_config * const config =
|
||||
dev->config->config_info;
|
||||
dev->config_info;
|
||||
struct gpio_pca95xx_drv_data * const drv_data =
|
||||
(struct gpio_pca95xx_drv_data * const)dev->driver_data;
|
||||
struct device * const i2c_master = drv_data->i2c_master;
|
||||
|
@ -140,7 +140,7 @@ static int write_port_regs(struct device *dev, u8_t reg,
|
|||
u16_t *cache, u16_t value)
|
||||
{
|
||||
const struct gpio_pca95xx_config * const config =
|
||||
dev->config->config_info;
|
||||
dev->config_info;
|
||||
struct gpio_pca95xx_drv_data * const drv_data =
|
||||
(struct gpio_pca95xx_drv_data * const)dev->driver_data;
|
||||
struct device * const i2c_master = drv_data->i2c_master;
|
||||
|
@ -253,7 +253,7 @@ static int setup_pin_dir(struct device *dev, u32_t pin, int flags)
|
|||
static int setup_pin_pullupdown(struct device *dev, u32_t pin, int flags)
|
||||
{
|
||||
const struct gpio_pca95xx_config * const config =
|
||||
dev->config->config_info;
|
||||
dev->config_info;
|
||||
struct gpio_pca95xx_drv_data * const drv_data =
|
||||
(struct gpio_pca95xx_drv_data * const)dev->driver_data;
|
||||
u16_t reg_pud;
|
||||
|
@ -317,7 +317,7 @@ static int gpio_pca95xx_config(struct device *dev,
|
|||
|
||||
#if (CONFIG_GPIO_LOG_LEVEL >= LOG_LEVEL_DEBUG)
|
||||
const struct gpio_pca95xx_config * const config =
|
||||
dev->config->config_info;
|
||||
dev->config_info;
|
||||
u16_t i2c_addr = config->i2c_slave_addr;
|
||||
#endif
|
||||
|
||||
|
@ -471,7 +471,7 @@ static const struct gpio_driver_api gpio_pca95xx_drv_api_funcs = {
|
|||
static int gpio_pca95xx_init(struct device *dev)
|
||||
{
|
||||
const struct gpio_pca95xx_config * const config =
|
||||
dev->config->config_info;
|
||||
dev->config_info;
|
||||
struct gpio_pca95xx_drv_data * const drv_data =
|
||||
(struct gpio_pca95xx_drv_data * const)dev->driver_data;
|
||||
struct device *i2c_master;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue