i2c-dev: Remove unnecessary casts
The private_data member of struct file is a void *, there is no need to cast it. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
This commit is contained in:
committed by
Jean Delvare
parent
7aeb96642f
commit
0be16c3061
@@ -138,7 +138,7 @@ static ssize_t i2cdev_read (struct file *file, char __user *buf, size_t count,
|
|||||||
char *tmp;
|
char *tmp;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
struct i2c_client *client = (struct i2c_client *)file->private_data;
|
struct i2c_client *client = file->private_data;
|
||||||
|
|
||||||
if (count > 8192)
|
if (count > 8192)
|
||||||
count = 8192;
|
count = 8192;
|
||||||
@@ -162,7 +162,7 @@ static ssize_t i2cdev_write (struct file *file, const char __user *buf, size_t c
|
|||||||
{
|
{
|
||||||
int ret;
|
int ret;
|
||||||
char *tmp;
|
char *tmp;
|
||||||
struct i2c_client *client = (struct i2c_client *)file->private_data;
|
struct i2c_client *client = file->private_data;
|
||||||
|
|
||||||
if (count > 8192)
|
if (count > 8192)
|
||||||
count = 8192;
|
count = 8192;
|
||||||
@@ -369,7 +369,7 @@ static noinline int i2cdev_ioctl_smbus(struct i2c_client *client,
|
|||||||
|
|
||||||
static long i2cdev_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
static long i2cdev_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
||||||
{
|
{
|
||||||
struct i2c_client *client = (struct i2c_client *)file->private_data;
|
struct i2c_client *client = file->private_data;
|
||||||
unsigned long funcs;
|
unsigned long funcs;
|
||||||
|
|
||||||
dev_dbg(&client->adapter->dev, "ioctl, cmd=0x%02x, arg=0x%02lx\n",
|
dev_dbg(&client->adapter->dev, "ioctl, cmd=0x%02x, arg=0x%02lx\n",
|
||||||
|
Reference in New Issue
Block a user