Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
35cf7ba0
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
160
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看板
提交
35cf7ba0
编写于
3月 22, 2010
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Bury __put_super_and_need_restart()
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
79893c17
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
6 addition
and
31 deletion
+6
-31
fs/drop_caches.c
fs/drop_caches.c
+1
-0
fs/internal.h
fs/internal.h
+2
-0
fs/quota/quota.c
fs/quota/quota.c
+1
-0
fs/super.c
fs/super.c
+2
-28
include/linux/fs.h
include/linux/fs.h
+0
-3
未找到文件。
fs/drop_caches.c
浏览文件 @
35cf7ba0
...
...
@@ -8,6 +8,7 @@
#include <linux/writeback.h>
#include <linux/sysctl.h>
#include <linux/gfp.h>
#include "internal.h"
/* A global variable is a bit ugly, but it keeps the code simple */
int
sysctl_drop_caches
;
...
...
fs/internal.h
浏览文件 @
35cf7ba0
...
...
@@ -87,6 +87,8 @@ extern struct file *get_empty_filp(void);
* super.c
*/
extern
int
do_remount_sb
(
struct
super_block
*
,
int
,
void
*
,
int
);
extern
void
__put_super
(
struct
super_block
*
sb
);
extern
void
put_super
(
struct
super_block
*
sb
);
/*
* open.c
...
...
fs/quota/quota.c
浏览文件 @
35cf7ba0
...
...
@@ -18,6 +18,7 @@
#include <linux/quotaops.h>
#include <linux/types.h>
#include <linux/writeback.h>
#include "../internal.h"
static
int
check_quotactl_permission
(
struct
super_block
*
sb
,
int
type
,
int
cmd
,
qid_t
id
)
...
...
fs/super.c
浏览文件 @
35cf7ba0
...
...
@@ -127,40 +127,14 @@ static inline void destroy_super(struct super_block *s)
/* Superblock refcounting */
/*
* Drop a superblock's refcount. Returns non-zero if the superblock was
* destroyed. The caller must hold sb_lock.
* Drop a superblock's refcount. The caller must hold sb_lock.
*/
int
__put_super
(
struct
super_block
*
sb
)
void
__put_super
(
struct
super_block
*
sb
)
{
int
ret
=
0
;
if
(
!--
sb
->
s_count
)
{
list_del_init
(
&
sb
->
s_list
);
destroy_super
(
sb
);
ret
=
1
;
}
return
ret
;
}
/*
* Drop a superblock's refcount.
* Returns non-zero if the superblock is about to be destroyed and
* at least is already removed from super_blocks list, so if we are
* making a loop through super blocks then we need to restart.
* The caller must hold sb_lock.
*/
int
__put_super_and_need_restart
(
struct
super_block
*
sb
)
{
/* check for race with generic_shutdown_super() */
if
(
list_empty
(
&
sb
->
s_instances
))
{
/* super block is removed, need to restart... */
__put_super
(
sb
);
return
1
;
}
/* can't be the last, since s_list is still in use */
sb
->
s_count
--
;
BUG_ON
(
sb
->
s_count
==
0
);
return
0
;
}
/**
...
...
include/linux/fs.h
浏览文件 @
35cf7ba0
...
...
@@ -1778,9 +1778,6 @@ extern int get_sb_pseudo(struct file_system_type *, char *,
const
struct
super_operations
*
ops
,
unsigned
long
,
struct
vfsmount
*
mnt
);
extern
void
simple_set_mnt
(
struct
vfsmount
*
mnt
,
struct
super_block
*
sb
);
int
__put_super_and_need_restart
(
struct
super_block
*
sb
);
int
__put_super
(
struct
super_block
*
sb
);
void
put_super
(
struct
super_block
*
sb
);
/* Alas, no aliases. Too much hassle with bringing module.h everywhere */
#define fops_get(fops) \
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录