Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
e637835e
cloud-kernel
项目概览
openanolis
/
cloud-kernel
大约 2 年 前同步成功
通知
173
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
e637835e
编写于
11月 20, 2016
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fsnotify(): constify 'data'
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
3cd5eca8
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
5 addition
and
5 deletion
+5
-5
fs/notify/fsnotify.c
fs/notify/fsnotify.c
+3
-3
include/linux/fsnotify_backend.h
include/linux/fsnotify_backend.h
+2
-2
未找到文件。
fs/notify/fsnotify.c
浏览文件 @
e637835e
...
@@ -125,7 +125,7 @@ EXPORT_SYMBOL_GPL(__fsnotify_parent);
...
@@ -125,7 +125,7 @@ EXPORT_SYMBOL_GPL(__fsnotify_parent);
static
int
send_to_group
(
struct
inode
*
to_tell
,
static
int
send_to_group
(
struct
inode
*
to_tell
,
struct
fsnotify_mark
*
inode_mark
,
struct
fsnotify_mark
*
inode_mark
,
struct
fsnotify_mark
*
vfsmount_mark
,
struct
fsnotify_mark
*
vfsmount_mark
,
__u32
mask
,
void
*
data
,
__u32
mask
,
const
void
*
data
,
int
data_is
,
u32
cookie
,
int
data_is
,
u32
cookie
,
const
unsigned
char
*
file_name
)
const
unsigned
char
*
file_name
)
{
{
...
@@ -187,7 +187,7 @@ static int send_to_group(struct inode *to_tell,
...
@@ -187,7 +187,7 @@ static int send_to_group(struct inode *to_tell,
* out to all of the registered fsnotify_group. Those groups can then use the
* out to all of the registered fsnotify_group. Those groups can then use the
* notification event in whatever means they feel necessary.
* notification event in whatever means they feel necessary.
*/
*/
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
void
*
data
,
int
data_is
,
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
const
void
*
data
,
int
data_is
,
const
unsigned
char
*
file_name
,
u32
cookie
)
const
unsigned
char
*
file_name
,
u32
cookie
)
{
{
struct
hlist_node
*
inode_node
=
NULL
,
*
vfsmount_node
=
NULL
;
struct
hlist_node
*
inode_node
=
NULL
,
*
vfsmount_node
=
NULL
;
...
@@ -199,7 +199,7 @@ int fsnotify(struct inode *to_tell, __u32 mask, void *data, int data_is,
...
@@ -199,7 +199,7 @@ int fsnotify(struct inode *to_tell, __u32 mask, void *data, int data_is,
__u32
test_mask
=
(
mask
&
~
FS_EVENT_ON_CHILD
);
__u32
test_mask
=
(
mask
&
~
FS_EVENT_ON_CHILD
);
if
(
data_is
==
FSNOTIFY_EVENT_PATH
)
if
(
data_is
==
FSNOTIFY_EVENT_PATH
)
mnt
=
real_mount
(((
struct
path
*
)
data
)
->
mnt
);
mnt
=
real_mount
(((
const
struct
path
*
)
data
)
->
mnt
);
else
else
mnt
=
NULL
;
mnt
=
NULL
;
...
...
include/linux/fsnotify_backend.h
浏览文件 @
e637835e
...
@@ -245,7 +245,7 @@ struct fsnotify_mark {
...
@@ -245,7 +245,7 @@ struct fsnotify_mark {
/* called from the vfs helpers */
/* called from the vfs helpers */
/* main fsnotify call to send events */
/* main fsnotify call to send events */
extern
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
void
*
data
,
int
data_is
,
extern
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
const
void
*
data
,
int
data_is
,
const
unsigned
char
*
name
,
u32
cookie
);
const
unsigned
char
*
name
,
u32
cookie
);
extern
int
__fsnotify_parent
(
struct
path
*
path
,
struct
dentry
*
dentry
,
__u32
mask
);
extern
int
__fsnotify_parent
(
struct
path
*
path
,
struct
dentry
*
dentry
,
__u32
mask
);
extern
void
__fsnotify_inode_delete
(
struct
inode
*
inode
);
extern
void
__fsnotify_inode_delete
(
struct
inode
*
inode
);
...
@@ -357,7 +357,7 @@ extern void fsnotify_init_event(struct fsnotify_event *event,
...
@@ -357,7 +357,7 @@ extern void fsnotify_init_event(struct fsnotify_event *event,
#else
#else
static
inline
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
void
*
data
,
int
data_is
,
static
inline
int
fsnotify
(
struct
inode
*
to_tell
,
__u32
mask
,
const
void
*
data
,
int
data_is
,
const
unsigned
char
*
name
,
u32
cookie
)
const
unsigned
char
*
name
,
u32
cookie
)
{
{
return
0
;
return
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录