mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
hw/i2c: Rename i2c_set_slave_address() -> i2c_slave_set_address()
Other functions from I2C slave API are named "i2c_slave_XXX()". Follow that pattern with set_address(). Add docstring along. No logical change. Patch created mechanically using: $ sed -i s/i2c_set_slave_address/i2c_slave_set_address/ \ $(git grep -l i2c_set_slave_address) Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Acked-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Corey Minyard <cminyard@mvista.com>
This commit is contained in:
parent
2038a2907c
commit
c8665a5997
8 changed files with 15 additions and 9 deletions
|
@ -66,7 +66,7 @@ I2CBus *i2c_init_bus(DeviceState *parent, const char *name)
|
|||
return bus;
|
||||
}
|
||||
|
||||
void i2c_set_slave_address(I2CSlave *dev, uint8_t address)
|
||||
void i2c_slave_set_address(I2CSlave *dev, uint8_t address)
|
||||
{
|
||||
dev->address = address;
|
||||
}
|
||||
|
|
|
@ -171,7 +171,7 @@ static void imx_i2c_write(void *opaque, hwaddr offset,
|
|||
switch (offset) {
|
||||
case IADR_ADDR:
|
||||
s->iadr = value & IADR_MASK;
|
||||
/* i2c_set_slave_address(s->bus, (uint8_t)s->iadr); */
|
||||
/* i2c_slave_set_address(s->bus, (uint8_t)s->iadr); */
|
||||
break;
|
||||
case IFDR_ADDR:
|
||||
s->ifdr = value & IFDR_MASK;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue