@@ -41,8 +41,7 @@ static inline int unsigned_offsets(struct file *file)
41
41
return file -> f_mode & FMODE_UNSIGNED_OFFSET ;
42
42
}
43
43
44
- static loff_t lseek_execute (struct file * file , struct inode * inode ,
45
- loff_t offset , loff_t maxsize )
44
+ static loff_t lseek_execute (struct file * file , loff_t offset , loff_t maxsize )
46
45
{
47
46
if (offset < 0 && !unsigned_offsets (file ))
48
47
return - EINVAL ;
76
75
generic_file_llseek_size (struct file * file , loff_t offset , int whence ,
77
76
loff_t maxsize , loff_t eof )
78
77
{
79
- struct inode * inode = file -> f_mapping -> host ;
80
-
81
78
switch (whence ) {
82
79
case SEEK_END :
83
80
offset += eof ;
@@ -97,8 +94,7 @@ generic_file_llseek_size(struct file *file, loff_t offset, int whence,
97
94
* like SEEK_SET.
98
95
*/
99
96
spin_lock (& file -> f_lock );
100
- offset = lseek_execute (file , inode , file -> f_pos + offset ,
101
- maxsize );
97
+ offset = lseek_execute (file , file -> f_pos + offset , maxsize );
102
98
spin_unlock (& file -> f_lock );
103
99
return offset ;
104
100
case SEEK_DATA :
@@ -120,7 +116,7 @@ generic_file_llseek_size(struct file *file, loff_t offset, int whence,
120
116
break ;
121
117
}
122
118
123
- return lseek_execute (file , inode , offset , maxsize );
119
+ return lseek_execute (file , offset , maxsize );
124
120
}
125
121
EXPORT_SYMBOL (generic_file_llseek_size );
126
122
0 commit comments