mirror of
https://github.com/apache/nuttx.git
synced 2026-06-04 14:53:47 +08:00
inode/i_private: remove all unnecessary cast for i_private
Signed-off-by: chao an <anchao@xiaomi.com>
This commit is contained in:
@@ -779,7 +779,7 @@ static int tsc2007_open(FAR struct file *filep)
|
||||
inode = filep->f_inode;
|
||||
|
||||
DEBUGASSERT(inode->i_private);
|
||||
priv = (FAR struct tsc2007_dev_s *)inode->i_private;
|
||||
priv = inode->i_private;
|
||||
|
||||
/* Get exclusive access to the driver data structure */
|
||||
|
||||
@@ -831,7 +831,7 @@ static int tsc2007_close(FAR struct file *filep)
|
||||
inode = filep->f_inode;
|
||||
|
||||
DEBUGASSERT(inode->i_private);
|
||||
priv = (FAR struct tsc2007_dev_s *)inode->i_private;
|
||||
priv = inode->i_private;
|
||||
|
||||
/* Get exclusive access to the driver data structure */
|
||||
|
||||
@@ -873,7 +873,7 @@ static ssize_t tsc2007_read(FAR struct file *filep, FAR char *buffer,
|
||||
inode = filep->f_inode;
|
||||
|
||||
DEBUGASSERT(inode->i_private);
|
||||
priv = (FAR struct tsc2007_dev_s *)inode->i_private;
|
||||
priv = inode->i_private;
|
||||
|
||||
/* Verify that the caller has provided a buffer large enough to receive
|
||||
* the touch data.
|
||||
@@ -1003,7 +1003,7 @@ static int tsc2007_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
||||
inode = filep->f_inode;
|
||||
|
||||
DEBUGASSERT(inode->i_private);
|
||||
priv = (FAR struct tsc2007_dev_s *)inode->i_private;
|
||||
priv = inode->i_private;
|
||||
|
||||
/* Get exclusive access to the driver data structure */
|
||||
|
||||
@@ -1076,7 +1076,7 @@ static int tsc2007_poll(FAR struct file *filep, FAR struct pollfd *fds,
|
||||
inode = filep->f_inode;
|
||||
|
||||
DEBUGASSERT(inode->i_private);
|
||||
priv = (FAR struct tsc2007_dev_s *)inode->i_private;
|
||||
priv = inode->i_private;
|
||||
|
||||
/* Are we setting up the poll? Or tearing it down? */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user