Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
kernel_linux
提交
2a8a3597
K
kernel_linux
项目概览
OpenHarmony
/
kernel_linux
上一次同步 4 年多
通知
15
Star
8
Fork
2
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
kernel_linux
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
2a8a3597
编写于
10月 20, 2014
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
lustre: use file_inode()
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
09561a53
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
29 addition
and
31 deletion
+29
-31
drivers/staging/lustre/lustre/libcfs/tracefile.c
drivers/staging/lustre/lustre/libcfs/tracefile.c
+2
-2
drivers/staging/lustre/lustre/llite/dir.c
drivers/staging/lustre/lustre/llite/dir.c
+2
-2
drivers/staging/lustre/lustre/llite/file.c
drivers/staging/lustre/lustre/llite/file.c
+13
-14
drivers/staging/lustre/lustre/llite/llite_internal.h
drivers/staging/lustre/lustre/llite/llite_internal.h
+1
-1
drivers/staging/lustre/lustre/llite/llite_mmap.c
drivers/staging/lustre/lustre/llite/llite_mmap.c
+6
-6
drivers/staging/lustre/lustre/llite/lloop.c
drivers/staging/lustre/lustre/llite/lloop.c
+3
-4
drivers/staging/lustre/lustre/llite/vvp_io.c
drivers/staging/lustre/lustre/llite/vvp_io.c
+2
-2
未找到文件。
drivers/staging/lustre/lustre/libcfs/tracefile.c
浏览文件 @
2a8a3597
...
@@ -1025,8 +1025,8 @@ static int tracefiled(void *arg)
...
@@ -1025,8 +1025,8 @@ static int tracefiled(void *arg)
if
(
f_pos
>=
(
off_t
)
cfs_tracefile_size
)
if
(
f_pos
>=
(
off_t
)
cfs_tracefile_size
)
f_pos
=
0
;
f_pos
=
0
;
else
if
(
f_pos
>
i_size_read
(
fil
p
->
f_dentry
->
d_inode
))
else
if
(
f_pos
>
i_size_read
(
fil
e_inode
(
filp
)
))
f_pos
=
i_size_read
(
fil
p
->
f_dentry
->
d_inode
);
f_pos
=
i_size_read
(
fil
e_inode
(
filp
)
);
buf
=
kmap
(
tage
->
page
);
buf
=
kmap
(
tage
->
page
);
rc
=
vfs_write
(
filp
,
(
__force
const
char
__user
*
)
buf
,
rc
=
vfs_write
(
filp
,
(
__force
const
char
__user
*
)
buf
,
...
...
drivers/staging/lustre/lustre/llite/dir.c
浏览文件 @
2a8a3597
...
@@ -593,7 +593,7 @@ int ll_dir_read(struct inode *inode, struct dir_context *ctx)
...
@@ -593,7 +593,7 @@ int ll_dir_read(struct inode *inode, struct dir_context *ctx)
static
int
ll_readdir
(
struct
file
*
filp
,
struct
dir_context
*
ctx
)
static
int
ll_readdir
(
struct
file
*
filp
,
struct
dir_context
*
ctx
)
{
{
struct
inode
*
inode
=
fil
p
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
fil
e_inode
(
filp
)
;
struct
ll_file_data
*
lfd
=
LUSTRE_FPRIVATE
(
filp
);
struct
ll_file_data
*
lfd
=
LUSTRE_FPRIVATE
(
filp
);
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
int
hash64
=
sbi
->
ll_flags
&
LL_SBI_64BIT_HASH
;
int
hash64
=
sbi
->
ll_flags
&
LL_SBI_64BIT_HASH
;
...
@@ -1242,7 +1242,7 @@ ll_getname(const char __user *filename)
...
@@ -1242,7 +1242,7 @@ ll_getname(const char __user *filename)
static
long
ll_dir_ioctl
(
struct
file
*
file
,
unsigned
int
cmd
,
unsigned
long
arg
)
static
long
ll_dir_ioctl
(
struct
file
*
file
,
unsigned
int
cmd
,
unsigned
long
arg
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
struct
obd_ioctl_data
*
data
;
struct
obd_ioctl_data
*
data
;
int
rc
=
0
;
int
rc
=
0
;
...
...
drivers/staging/lustre/lustre/llite/file.c
浏览文件 @
2a8a3597
...
@@ -489,7 +489,7 @@ static int ll_och_fill(struct obd_export *md_exp, struct lookup_intent *it,
...
@@ -489,7 +489,7 @@ static int ll_och_fill(struct obd_export *md_exp, struct lookup_intent *it,
static
int
ll_local_open
(
struct
file
*
file
,
struct
lookup_intent
*
it
,
static
int
ll_local_open
(
struct
file
*
file
,
struct
lookup_intent
*
it
,
struct
ll_file_data
*
fd
,
struct
obd_client_handle
*
och
)
struct
ll_file_data
*
fd
,
struct
obd_client_handle
*
och
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
LASSERT
(
!
LUSTRE_FPRIVATE
(
file
));
LASSERT
(
!
LUSTRE_FPRIVATE
(
file
));
...
@@ -1053,7 +1053,7 @@ int ll_glimpse_ioctl(struct ll_sb_info *sbi, struct lov_stripe_md *lsm,
...
@@ -1053,7 +1053,7 @@ int ll_glimpse_ioctl(struct ll_sb_info *sbi, struct lov_stripe_md *lsm,
static
bool
file_is_noatime
(
const
struct
file
*
file
)
static
bool
file_is_noatime
(
const
struct
file
*
file
)
{
{
const
struct
vfsmount
*
mnt
=
file
->
f_path
.
mnt
;
const
struct
vfsmount
*
mnt
=
file
->
f_path
.
mnt
;
const
struct
inode
*
inode
=
file
->
f_path
.
dentry
->
d_inode
;
const
struct
inode
*
inode
=
file
_inode
(
file
)
;
/* Adapted from file_accessed() and touch_atime().*/
/* Adapted from file_accessed() and touch_atime().*/
if
(
file
->
f_flags
&
O_NOATIME
)
if
(
file
->
f_flags
&
O_NOATIME
)
...
@@ -1079,7 +1079,7 @@ static bool file_is_noatime(const struct file *file)
...
@@ -1079,7 +1079,7 @@ static bool file_is_noatime(const struct file *file)
void
ll_io_init
(
struct
cl_io
*
io
,
const
struct
file
*
file
,
int
write
)
void
ll_io_init
(
struct
cl_io
*
io
,
const
struct
file
*
file
,
int
write
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
io
->
u
.
ci_rw
.
crw_nonblock
=
file
->
f_flags
&
O_NONBLOCK
;
io
->
u
.
ci_rw
.
crw_nonblock
=
file
->
f_flags
&
O_NONBLOCK
;
if
(
write
)
{
if
(
write
)
{
...
@@ -1105,7 +1105,7 @@ ll_file_io_generic(const struct lu_env *env, struct vvp_io_args *args,
...
@@ -1105,7 +1105,7 @@ ll_file_io_generic(const struct lu_env *env, struct vvp_io_args *args,
struct
file
*
file
,
enum
cl_io_type
iot
,
struct
file
*
file
,
enum
cl_io_type
iot
,
loff_t
*
ppos
,
size_t
count
)
loff_t
*
ppos
,
size_t
count
)
{
{
struct
ll_inode_info
*
lli
=
ll_i2info
(
file
->
f_dentry
->
d_inode
);
struct
ll_inode_info
*
lli
=
ll_i2info
(
file
_inode
(
file
)
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
cl_io
*
io
;
struct
cl_io
*
io
;
ssize_t
result
;
ssize_t
result
;
...
@@ -1175,11 +1175,11 @@ ll_file_io_generic(const struct lu_env *env, struct vvp_io_args *args,
...
@@ -1175,11 +1175,11 @@ ll_file_io_generic(const struct lu_env *env, struct vvp_io_args *args,
if
(
iot
==
CIT_READ
)
{
if
(
iot
==
CIT_READ
)
{
if
(
result
>=
0
)
if
(
result
>=
0
)
ll_stats_ops_tally
(
ll_i2sbi
(
file
->
f_dentry
->
d_inode
),
ll_stats_ops_tally
(
ll_i2sbi
(
file
_inode
(
file
)
),
LPROC_LL_READ_BYTES
,
result
);
LPROC_LL_READ_BYTES
,
result
);
}
else
if
(
iot
==
CIT_WRITE
)
{
}
else
if
(
iot
==
CIT_WRITE
)
{
if
(
result
>=
0
)
{
if
(
result
>=
0
)
{
ll_stats_ops_tally
(
ll_i2sbi
(
file
->
f_dentry
->
d_inode
),
ll_stats_ops_tally
(
ll_i2sbi
(
file
_inode
(
file
)
),
LPROC_LL_WRITE_BYTES
,
result
);
LPROC_LL_WRITE_BYTES
,
result
);
fd
->
fd_write_failed
=
false
;
fd
->
fd_write_failed
=
false
;
}
else
if
(
result
!=
-
ERESTARTSYS
)
{
}
else
if
(
result
!=
-
ERESTARTSYS
)
{
...
@@ -1950,8 +1950,8 @@ static int ll_swap_layouts(struct file *file1, struct file *file2,
...
@@ -1950,8 +1950,8 @@ static int ll_swap_layouts(struct file *file1, struct file *file2,
if
(
!
llss
)
if
(
!
llss
)
return
-
ENOMEM
;
return
-
ENOMEM
;
llss
->
inode1
=
file
1
->
f_dentry
->
d_inode
;
llss
->
inode1
=
file
_inode
(
file1
)
;
llss
->
inode2
=
file
2
->
f_dentry
->
d_inode
;
llss
->
inode2
=
file
_inode
(
file2
)
;
if
(
!
S_ISREG
(
llss
->
inode2
->
i_mode
))
{
if
(
!
S_ISREG
(
llss
->
inode2
->
i_mode
))
{
rc
=
-
EINVAL
;
rc
=
-
EINVAL
;
...
@@ -2195,7 +2195,7 @@ static int ll_hsm_import(struct inode *inode, struct file *file,
...
@@ -2195,7 +2195,7 @@ static int ll_hsm_import(struct inode *inode, struct file *file,
static
long
static
long
ll_file_ioctl
(
struct
file
*
file
,
unsigned
int
cmd
,
unsigned
long
arg
)
ll_file_ioctl
(
struct
file
*
file
,
unsigned
int
cmd
,
unsigned
long
arg
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
int
flags
,
rc
;
int
flags
,
rc
;
...
@@ -2514,7 +2514,7 @@ ll_file_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
...
@@ -2514,7 +2514,7 @@ ll_file_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
static
loff_t
ll_file_seek
(
struct
file
*
file
,
loff_t
offset
,
int
origin
)
static
loff_t
ll_file_seek
(
struct
file
*
file
,
loff_t
offset
,
int
origin
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
loff_t
retval
,
eof
=
0
;
loff_t
retval
,
eof
=
0
;
retval
=
offset
+
((
origin
==
SEEK_END
)
?
i_size_read
(
inode
)
:
retval
=
offset
+
((
origin
==
SEEK_END
)
?
i_size_read
(
inode
)
:
...
@@ -2538,7 +2538,7 @@ static loff_t ll_file_seek(struct file *file, loff_t offset, int origin)
...
@@ -2538,7 +2538,7 @@ static loff_t ll_file_seek(struct file *file, loff_t offset, int origin)
static
int
ll_flush
(
struct
file
*
file
,
fl_owner_t
id
)
static
int
ll_flush
(
struct
file
*
file
,
fl_owner_t
id
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
int
rc
,
err
;
int
rc
,
err
;
...
@@ -2621,8 +2621,7 @@ int cl_sync_file_range(struct inode *inode, loff_t start, loff_t end,
...
@@ -2621,8 +2621,7 @@ int cl_sync_file_range(struct inode *inode, loff_t start, loff_t end,
int
ll_fsync
(
struct
file
*
file
,
loff_t
start
,
loff_t
end
,
int
datasync
)
int
ll_fsync
(
struct
file
*
file
,
loff_t
start
,
loff_t
end
,
int
datasync
)
{
{
struct
dentry
*
dentry
=
file
->
f_dentry
;
struct
inode
*
inode
=
file_inode
(
file
);
struct
inode
*
inode
=
dentry
->
d_inode
;
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ptlrpc_request
*
req
;
struct
ptlrpc_request
*
req
;
struct
obd_capa
*
oc
;
struct
obd_capa
*
oc
;
...
@@ -2675,7 +2674,7 @@ int ll_fsync(struct file *file, loff_t start, loff_t end, int datasync)
...
@@ -2675,7 +2674,7 @@ int ll_fsync(struct file *file, loff_t start, loff_t end, int datasync)
static
int
static
int
ll_file_flock
(
struct
file
*
file
,
int
cmd
,
struct
file_lock
*
file_lock
)
ll_file_flock
(
struct
file
*
file
,
int
cmd
,
struct
file_lock
*
file_lock
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
struct
ll_sb_info
*
sbi
=
ll_i2sbi
(
inode
);
struct
ldlm_enqueue_info
einfo
=
{
struct
ldlm_enqueue_info
einfo
=
{
.
ei_type
=
LDLM_FLOCK
,
.
ei_type
=
LDLM_FLOCK
,
...
...
drivers/staging/lustre/lustre/llite/llite_internal.h
浏览文件 @
2a8a3597
...
@@ -1413,7 +1413,7 @@ extern ssize_t ll_direct_rw_pages(const struct lu_env *env, struct cl_io *io,
...
@@ -1413,7 +1413,7 @@ extern ssize_t ll_direct_rw_pages(const struct lu_env *env, struct cl_io *io,
static
inline
int
ll_file_nolock
(
const
struct
file
*
file
)
static
inline
int
ll_file_nolock
(
const
struct
file
*
file
)
{
{
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
ll_file_data
*
fd
=
LUSTRE_FPRIVATE
(
file
);
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
LASSERT
(
fd
!=
NULL
);
LASSERT
(
fd
!=
NULL
);
return
((
fd
->
fd_flags
&
LL_FILE_IGNORE_LOCK
)
||
return
((
fd
->
fd_flags
&
LL_FILE_IGNORE_LOCK
)
||
...
...
drivers/staging/lustre/lustre/llite/llite_mmap.c
浏览文件 @
2a8a3597
...
@@ -100,7 +100,7 @@ ll_fault_io_init(struct vm_area_struct *vma, struct lu_env **env_ret,
...
@@ -100,7 +100,7 @@ ll_fault_io_init(struct vm_area_struct *vma, struct lu_env **env_ret,
unsigned
long
*
ra_flags
)
unsigned
long
*
ra_flags
)
{
{
struct
file
*
file
=
vma
->
vm_file
;
struct
file
*
file
=
vma
->
vm_file
;
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
struct
cl_io
*
io
;
struct
cl_io
*
io
;
struct
cl_fault_io
*
fio
;
struct
cl_fault_io
*
fio
;
struct
lu_env
*
env
;
struct
lu_env
*
env
;
...
@@ -213,7 +213,7 @@ static int ll_page_mkwrite0(struct vm_area_struct *vma, struct page *vmpage,
...
@@ -213,7 +213,7 @@ static int ll_page_mkwrite0(struct vm_area_struct *vma, struct page *vmpage,
cfs_restore_sigs
(
set
);
cfs_restore_sigs
(
set
);
if
(
result
==
0
)
{
if
(
result
==
0
)
{
struct
inode
*
inode
=
vma
->
vm_file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file_inode
(
vma
->
vm_file
)
;
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
struct
ll_inode_info
*
lli
=
ll_i2info
(
inode
);
lock_page
(
vmpage
);
lock_page
(
vmpage
);
...
@@ -396,7 +396,7 @@ static int ll_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf)
...
@@ -396,7 +396,7 @@ static int ll_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf)
CWARN
(
"app(%s): the page %lu of file %lu is under heavy"
CWARN
(
"app(%s): the page %lu of file %lu is under heavy"
" contention.
\n
"
,
" contention.
\n
"
,
current
->
comm
,
vmf
->
pgoff
,
current
->
comm
,
vmf
->
pgoff
,
vma
->
vm_file
->
f_dentry
->
d_inode
->
i_ino
);
file_inode
(
vma
->
vm_file
)
->
i_ino
);
printed
=
true
;
printed
=
true
;
}
}
}
while
(
retry
);
}
while
(
retry
);
...
@@ -430,7 +430,7 @@ static int ll_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf)
...
@@ -430,7 +430,7 @@ static int ll_page_mkwrite(struct vm_area_struct *vma, struct vm_fault *vmf)
*/
*/
static
void
ll_vm_open
(
struct
vm_area_struct
*
vma
)
static
void
ll_vm_open
(
struct
vm_area_struct
*
vma
)
{
{
struct
inode
*
inode
=
vma
->
vm_file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file_inode
(
vma
->
vm_file
)
;
struct
ccc_object
*
vob
=
cl_inode2ccc
(
inode
);
struct
ccc_object
*
vob
=
cl_inode2ccc
(
inode
);
LASSERT
(
vma
->
vm_file
);
LASSERT
(
vma
->
vm_file
);
...
@@ -443,7 +443,7 @@ static void ll_vm_open(struct vm_area_struct *vma)
...
@@ -443,7 +443,7 @@ static void ll_vm_open(struct vm_area_struct *vma)
*/
*/
static
void
ll_vm_close
(
struct
vm_area_struct
*
vma
)
static
void
ll_vm_close
(
struct
vm_area_struct
*
vma
)
{
{
struct
inode
*
inode
=
vma
->
vm_file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file_inode
(
vma
->
vm_file
)
;
struct
ccc_object
*
vob
=
cl_inode2ccc
(
inode
);
struct
ccc_object
*
vob
=
cl_inode2ccc
(
inode
);
LASSERT
(
vma
->
vm_file
);
LASSERT
(
vma
->
vm_file
);
...
@@ -476,7 +476,7 @@ static const struct vm_operations_struct ll_file_vm_ops = {
...
@@ -476,7 +476,7 @@ static const struct vm_operations_struct ll_file_vm_ops = {
int
ll_file_mmap
(
struct
file
*
file
,
struct
vm_area_struct
*
vma
)
int
ll_file_mmap
(
struct
file
*
file
,
struct
vm_area_struct
*
vma
)
{
{
struct
inode
*
inode
=
file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file
_inode
(
file
)
;
int
rc
;
int
rc
;
if
(
ll_file_nolock
(
file
))
if
(
ll_file_nolock
(
file
))
...
...
drivers/staging/lustre/lustre/llite/lloop.c
浏览文件 @
2a8a3597
...
@@ -187,7 +187,7 @@ static int do_bio_lustrebacked(struct lloop_device *lo, struct bio *head)
...
@@ -187,7 +187,7 @@ static int do_bio_lustrebacked(struct lloop_device *lo, struct bio *head)
{
{
const
struct
lu_env
*
env
=
lo
->
lo_env
;
const
struct
lu_env
*
env
=
lo
->
lo_env
;
struct
cl_io
*
io
=
&
lo
->
lo_io
;
struct
cl_io
*
io
=
&
lo
->
lo_io
;
struct
inode
*
inode
=
lo
->
lo_backing_file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file_inode
(
lo
->
lo_backing_file
)
;
struct
cl_object
*
obj
=
ll_i2info
(
inode
)
->
lli_clob
;
struct
cl_object
*
obj
=
ll_i2info
(
inode
)
->
lli_clob
;
pgoff_t
offset
;
pgoff_t
offset
;
int
ret
;
int
ret
;
...
@@ -626,7 +626,7 @@ static int lo_ioctl(struct block_device *bdev, fmode_t mode,
...
@@ -626,7 +626,7 @@ static int lo_ioctl(struct block_device *bdev, fmode_t mode,
break
;
break
;
}
}
if
(
inode
==
NULL
)
if
(
inode
==
NULL
)
inode
=
lo
->
lo_backing_file
->
f_dentry
->
d_inode
;
inode
=
file_inode
(
lo
->
lo_backing_file
)
;
if
(
lo
->
lo_state
==
LLOOP_BOUND
)
if
(
lo
->
lo_state
==
LLOOP_BOUND
)
fid
=
ll_i2info
(
inode
)
->
lli_fid
;
fid
=
ll_i2info
(
inode
)
->
lli_fid
;
else
else
...
@@ -692,8 +692,7 @@ static enum llioc_iter lloop_ioctl(struct inode *unused, struct file *file,
...
@@ -692,8 +692,7 @@ static enum llioc_iter lloop_ioctl(struct inode *unused, struct file *file,
lo_free
=
lo
;
lo_free
=
lo
;
continue
;
continue
;
}
}
if
(
lo
->
lo_backing_file
->
f_dentry
->
d_inode
==
if
(
file_inode
(
lo
->
lo_backing_file
)
==
file_inode
(
file
))
file
->
f_dentry
->
d_inode
)
break
;
break
;
}
}
if
(
lo
||
!
lo_free
)
{
if
(
lo
||
!
lo_free
)
{
...
...
drivers/staging/lustre/lustre/llite/vvp_io.c
浏览文件 @
2a8a3597
...
@@ -108,7 +108,7 @@ static int vvp_io_fault_iter_init(const struct lu_env *env,
...
@@ -108,7 +108,7 @@ static int vvp_io_fault_iter_init(const struct lu_env *env,
struct
inode
*
inode
=
ccc_object_inode
(
ios
->
cis_obj
);
struct
inode
*
inode
=
ccc_object_inode
(
ios
->
cis_obj
);
LASSERT
(
inode
==
LASSERT
(
inode
==
cl2ccc_io
(
env
,
ios
)
->
cui_fd
->
fd_file
->
f_dentry
->
d_inode
);
file_inode
(
cl2ccc_io
(
env
,
ios
)
->
cui_fd
->
fd_file
)
);
vio
->
u
.
fault
.
ft_mtime
=
LTIME_S
(
inode
->
i_mtime
);
vio
->
u
.
fault
.
ft_mtime
=
LTIME_S
(
inode
->
i_mtime
);
return
0
;
return
0
;
}
}
...
@@ -239,7 +239,7 @@ static int vvp_mmap_locks(const struct lu_env *env,
...
@@ -239,7 +239,7 @@ static int vvp_mmap_locks(const struct lu_env *env,
down_read
(
&
mm
->
mmap_sem
);
down_read
(
&
mm
->
mmap_sem
);
while
((
vma
=
our_vma
(
mm
,
addr
,
count
))
!=
NULL
)
{
while
((
vma
=
our_vma
(
mm
,
addr
,
count
))
!=
NULL
)
{
struct
inode
*
inode
=
vma
->
vm_file
->
f_dentry
->
d_inode
;
struct
inode
*
inode
=
file_inode
(
vma
->
vm_file
)
;
int
flags
=
CEF_MUST
;
int
flags
=
CEF_MUST
;
if
(
ll_file_nolock
(
vma
->
vm_file
))
{
if
(
ll_file_nolock
(
vma
->
vm_file
))
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录