summaryrefslogtreecommitdiff
path: root/v4l_experimental/dpl3518.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2006-06-24 08:32:26 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-06-24 08:32:26 -0300
commit04e2c76f8d845ee90c1e85ee6a170618b22ff933 (patch)
treedc39e43391782e48e9cc697ccf040cd7e9574509 /v4l_experimental/dpl3518.c
parentde2d21cb87c4d4e3124c02d856e632f355f1a002 (diff)
downloadmediapointer-dvb-s2-04e2c76f8d845ee90c1e85ee6a170618b22ff933.tar.gz
mediapointer-dvb-s2-04e2c76f8d845ee90c1e85ee6a170618b22ff933.tar.bz2
Whitespace cleanups
From: Mauro Carvalho Chehab <mchehab@infradead.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'v4l_experimental/dpl3518.c')
-rw-r--r--v4l_experimental/dpl3518.c52
1 files changed, 26 insertions, 26 deletions
diff --git a/v4l_experimental/dpl3518.c b/v4l_experimental/dpl3518.c
index a7df1f078..43533767e 100644
--- a/v4l_experimental/dpl3518.c
+++ b/v4l_experimental/dpl3518.c
@@ -96,27 +96,27 @@ MODULE_LICENSE("GPL");
static int dpl3518_reset(struct i2c_client *client)
{
- static char reset_off[3] = { 0x00, 0x80, 0x00 };
- static char reset_on[3] = { 0x00, 0x00, 0x00 };
+ static char reset_off[3] = { 0x00, 0x80, 0x00 };
+ static char reset_on[3] = { 0x00, 0x00, 0x00 };
- i2c_master_send(client,reset_off,3); /* ignore errors here */
- if (3 != i2c_master_send(client,reset_on, 3)) {
+ i2c_master_send(client,reset_off,3); /* ignore errors here */
+ if (3 != i2c_master_send(client,reset_on, 3)) {
printk(KERN_ERR "dpl3518: chip reset failed, penguin on i2c bus?\n");
return -1;
}
- return 0;
+ return 0;
}
static int dpl3518_write(struct i2c_client *client, int dev, int addr, int val)
{
int err;
- unsigned char buffer[5];
+ unsigned char buffer[5];
- buffer[0] = dev;
- buffer[1] = addr >> 8;
- buffer[2] = addr & 0xff;
- buffer[3] = val >> 8;
- buffer[4] = val & 0xff;
+ buffer[0] = dev;
+ buffer[1] = addr >> 8;
+ buffer[2] = addr & 0xff;
+ buffer[3] = val >> 8;
+ buffer[4] = val & 0xff;
for (err = 0; err < 3;) {
if (5 == i2c_master_send(client, buffer, 5))
@@ -248,9 +248,9 @@ static int dpl3518_attach(struct i2c_adapter *adap, int addr,
client = kmalloc(sizeof *client,GFP_KERNEL);
if (!client)
return -ENOMEM;
- memcpy(client,&client_template,sizeof(struct i2c_client));
- client->adapter = adap;
- client->addr = addr;
+ memcpy(client,&client_template,sizeof(struct i2c_client));
+ client->adapter = adap;
+ client->addr = addr;
dpl = kmalloc(sizeof *dpl, GFP_KERNEL);
if (NULL == dpl)
@@ -306,8 +306,8 @@ static int dpl3518_dev_ioctl(struct inode *inode, struct file *file,
dpl3518_reset(client);
break;
case DPL_IOC_VERSION:
- if (put_user(DPL_VERSION_CODE, (int *) arg))
- ret = -EFAULT;
+ if (put_user(DPL_VERSION_CODE, (int *) arg))
+ ret = -EFAULT;
break;
case DPL_IOC_INIT:
dpl3518_ioc_init(client);
@@ -325,8 +325,8 @@ static int dpl3518_dev_ioctl(struct inode *inode, struct file *file,
dpl3518_setmode(client, (int) arg);
break;
case DPL_IOC_GET_MODE:
- if (put_user(dpl_device->mode, (int *) arg))
- ret = -EFAULT;
+ if (put_user(dpl_device->mode, (int *) arg))
+ ret = -EFAULT;
break;
case DPL_IOC_NOISE_MODE:
dpl3518_setnoisemode(client, (int) arg);
@@ -368,18 +368,18 @@ static struct i2c_driver driver = {
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,54)
.owner = THIS_MODULE,
#endif
- .name = "i2c dpl3518 driver",
- .id = I2C_DRIVERID_DPL3518,
- .flags = I2C_DF_NOTIFY,
- .attach_adapter = dpl3518_probe,
- .detach_client = dpl3518_detach,
+ .name = "i2c dpl3518 driver",
+ .id = I2C_DRIVERID_DPL3518,
+ .flags = I2C_DF_NOTIFY,
+ .attach_adapter = dpl3518_probe,
+ .detach_client = dpl3518_detach,
};
static struct i2c_client client_template =
{
- I2C_DEVNAME("dpl3518"),
- .id = -1,
- .driver = &driver
+ I2C_DEVNAME("dpl3518"),
+ .id = -1,
+ .driver = &driver
};
static struct file_operations dpl3518_fops =