diff options
Diffstat (limited to 'drivers/char/lp.c')
-rw-r--r-- | drivers/char/lp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/char/lp.c b/drivers/char/lp.c index a741e418b456..dafd9ac6428f 100644 --- a/drivers/char/lp.c +++ b/drivers/char/lp.c | |||
@@ -294,7 +294,7 @@ static int lp_wait_ready(int minor, int nonblock) | |||
294 | static ssize_t lp_write(struct file * file, const char __user * buf, | 294 | static ssize_t lp_write(struct file * file, const char __user * buf, |
295 | size_t count, loff_t *ppos) | 295 | size_t count, loff_t *ppos) |
296 | { | 296 | { |
297 | unsigned int minor = iminor(file->f_path.dentry->d_inode); | 297 | unsigned int minor = iminor(file_inode(file)); |
298 | struct parport *port = lp_table[minor].dev->port; | 298 | struct parport *port = lp_table[minor].dev->port; |
299 | char *kbuf = lp_table[minor].lp_buffer; | 299 | char *kbuf = lp_table[minor].lp_buffer; |
300 | ssize_t retv = 0; | 300 | ssize_t retv = 0; |
@@ -413,7 +413,7 @@ static ssize_t lp_read(struct file * file, char __user * buf, | |||
413 | size_t count, loff_t *ppos) | 413 | size_t count, loff_t *ppos) |
414 | { | 414 | { |
415 | DEFINE_WAIT(wait); | 415 | DEFINE_WAIT(wait); |
416 | unsigned int minor=iminor(file->f_path.dentry->d_inode); | 416 | unsigned int minor=iminor(file_inode(file)); |
417 | struct parport *port = lp_table[minor].dev->port; | 417 | struct parport *port = lp_table[minor].dev->port; |
418 | ssize_t retval = 0; | 418 | ssize_t retval = 0; |
419 | char *kbuf = lp_table[minor].lp_buffer; | 419 | char *kbuf = lp_table[minor].lp_buffer; |
@@ -679,7 +679,7 @@ static long lp_ioctl(struct file *file, unsigned int cmd, | |||
679 | struct timeval par_timeout; | 679 | struct timeval par_timeout; |
680 | int ret; | 680 | int ret; |
681 | 681 | ||
682 | minor = iminor(file->f_path.dentry->d_inode); | 682 | minor = iminor(file_inode(file)); |
683 | mutex_lock(&lp_mutex); | 683 | mutex_lock(&lp_mutex); |
684 | switch (cmd) { | 684 | switch (cmd) { |
685 | case LPSETTIMEOUT: | 685 | case LPSETTIMEOUT: |
@@ -707,7 +707,7 @@ static long lp_compat_ioctl(struct file *file, unsigned int cmd, | |||
707 | struct timeval par_timeout; | 707 | struct timeval par_timeout; |
708 | int ret; | 708 | int ret; |
709 | 709 | ||
710 | minor = iminor(file->f_path.dentry->d_inode); | 710 | minor = iminor(file_inode(file)); |
711 | mutex_lock(&lp_mutex); | 711 | mutex_lock(&lp_mutex); |
712 | switch (cmd) { | 712 | switch (cmd) { |
713 | case LPSETTIMEOUT: | 713 | case LPSETTIMEOUT: |