i2c: Whitespace cleanups
Remove extraneous whitespace from various i2c headers and core files, like space-before-tab and whitespace at end of line. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Jean Delvare <khali@linux-fr.org>
This commit is contained in:
parent
2c003e8e1c
commit
438d6c2c01
|
@ -757,7 +757,7 @@ int i2c_probe(struct i2c_adapter *adapter,
|
|||
if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_QUICK)) {
|
||||
if (address_data->probe[0] == I2C_CLIENT_END
|
||||
&& address_data->normal_i2c[0] == I2C_CLIENT_END)
|
||||
return 0;
|
||||
return 0;
|
||||
|
||||
dev_warn(&adapter->dev, "SMBus Quick command not supported, "
|
||||
"can't probe for chips\n");
|
||||
|
@ -897,7 +897,7 @@ static int i2c_smbus_check_pec(u8 cpec, struct i2c_msg *msg)
|
|||
s32 i2c_smbus_write_quick(struct i2c_client *client, u8 value)
|
||||
{
|
||||
return i2c_smbus_xfer(client->adapter,client->addr,client->flags,
|
||||
value,0,I2C_SMBUS_QUICK,NULL);
|
||||
value,0,I2C_SMBUS_QUICK,NULL);
|
||||
}
|
||||
|
||||
s32 i2c_smbus_read_byte(struct i2c_client *client)
|
||||
|
@ -1103,14 +1103,14 @@ static s32 i2c_smbus_xfer_emulated(struct i2c_adapter * adapter, u16 addr,
|
|||
if (i) {
|
||||
/* Compute PEC if first message is a write */
|
||||
if (!(msg[0].flags & I2C_M_RD)) {
|
||||
if (num == 1) /* Write only */
|
||||
if (num == 1) /* Write only */
|
||||
i2c_smbus_add_pec(&msg[0]);
|
||||
else /* Write followed by read */
|
||||
partial_pec = i2c_smbus_msg_pec(0, &msg[0]);
|
||||
}
|
||||
/* Ask for PEC if last message is a read */
|
||||
if (msg[num-1].flags & I2C_M_RD)
|
||||
msg[num-1].len++;
|
||||
msg[num-1].len++;
|
||||
}
|
||||
|
||||
if (i2c_transfer(adapter, msg, num) < 0)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* ------------------------------------------------------------------------- */
|
||||
/* */
|
||||
/* */
|
||||
/* i2c-id.h - identifier values for i2c drivers and adapters */
|
||||
/* */
|
||||
/* */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Copyright (C) 1995-1999 Simon G. Vogl
|
||||
|
||||
|
@ -40,10 +40,10 @@
|
|||
#define I2C_DRIVERID_SAA7120 11 /* video encoder */
|
||||
#define I2C_DRIVERID_SAA7121 12 /* video encoder */
|
||||
#define I2C_DRIVERID_SAA7185B 13 /* video encoder */
|
||||
#define I2C_DRIVERID_CH7003 14 /* digital pc to tv encoder */
|
||||
#define I2C_DRIVERID_CH7003 14 /* digital pc to tv encoder */
|
||||
#define I2C_DRIVERID_PCF8574A 15 /* i2c expander - 8 bit in/out */
|
||||
#define I2C_DRIVERID_PCF8582C 16 /* eeprom */
|
||||
#define I2C_DRIVERID_AT24Cxx 17 /* eeprom 1/2/4/8/16 K */
|
||||
#define I2C_DRIVERID_AT24Cxx 17 /* eeprom 1/2/4/8/16 K */
|
||||
#define I2C_DRIVERID_TEA6300 18 /* audio mixer */
|
||||
#define I2C_DRIVERID_BT829 19 /* pc to tv encoder */
|
||||
#define I2C_DRIVERID_TDA9850 20 /* audio mixer */
|
||||
|
@ -162,7 +162,7 @@
|
|||
* ---- Adapter types ----------------------------------------------------
|
||||
*/
|
||||
|
||||
/* --- Bit algorithm adapters */
|
||||
/* --- Bit algorithm adapters */
|
||||
#define I2C_HW_B_LP 0x010000 /* Parallel port Philips style */
|
||||
#define I2C_HW_B_SER 0x010002 /* Serial line interface */
|
||||
#define I2C_HW_B_BT848 0x010005 /* BT848 video boards */
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* ------------------------------------------------------------------------- */
|
||||
/* */
|
||||
/* */
|
||||
/* i2c.h - definitions for the i2c-bus interface */
|
||||
/* */
|
||||
/* */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Copyright (C) 1995-2000 Simon G. Vogl
|
||||
|
||||
|
@ -145,7 +145,7 @@ struct i2c_driver {
|
|||
*/
|
||||
struct i2c_client {
|
||||
unsigned int flags; /* div., see below */
|
||||
unsigned short addr; /* chip address - NOTE: 7bit */
|
||||
unsigned short addr; /* chip address - NOTE: 7bit */
|
||||
/* addresses are stored in the */
|
||||
/* _LOWER_ 7 bits */
|
||||
struct i2c_adapter *adapter; /* the adapter we sit on */
|
||||
|
@ -353,15 +353,15 @@ static inline int i2c_adapter_id(struct i2c_adapter *adap)
|
|||
*/
|
||||
struct i2c_msg {
|
||||
__u16 addr; /* slave address */
|
||||
__u16 flags;
|
||||
__u16 flags;
|
||||
#define I2C_M_TEN 0x10 /* we have a ten bit chip address */
|
||||
#define I2C_M_RD 0x01
|
||||
#define I2C_M_NOSTART 0x4000
|
||||
#define I2C_M_REV_DIR_ADDR 0x2000
|
||||
#define I2C_M_IGNORE_NAK 0x1000
|
||||
#define I2C_M_NO_RD_ACK 0x0800
|
||||
__u16 len; /* msg length */
|
||||
__u8 *buf; /* pointer to msg data */
|
||||
__u16 len; /* msg length */
|
||||
__u8 *buf; /* pointer to msg data */
|
||||
};
|
||||
|
||||
/* To determine what functionality is present */
|
||||
|
@ -442,8 +442,8 @@ union i2c_smbus_data {
|
|||
/* -> bit-adapter specific ioctls */
|
||||
#define I2C_RETRIES 0x0701 /* number of times a device address */
|
||||
/* should be polled when not */
|
||||
/* acknowledging */
|
||||
#define I2C_TIMEOUT 0x0702 /* set timeout - call with int */
|
||||
/* acknowledging */
|
||||
#define I2C_TIMEOUT 0x0702 /* set timeout - call with int */
|
||||
|
||||
|
||||
/* this is for i2c-dev.c */
|
||||
|
|
Loading…
Reference in New Issue