Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
7eb9b2f5
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
7eb9b2f5
编写于
1月 17, 2006
作者:
L
Linus Torvalds
浏览文件
操作
浏览文件
下载
差异文件
Merge
git://oss.sgi.com:8090/oss/git/xfs-2.6
上级
728c7763
d88992f6
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
26 addition
and
3 deletion
+26
-3
fs/xfs/linux-2.6/xfs_aops.c
fs/xfs/linux-2.6/xfs_aops.c
+26
-3
未找到文件。
fs/xfs/linux-2.6/xfs_aops.c
浏览文件 @
7eb9b2f5
...
@@ -336,24 +336,47 @@ static inline int bio_add_buffer(struct bio *bio, struct buffer_head *bh)
...
@@ -336,24 +336,47 @@ static inline int bio_add_buffer(struct bio *bio, struct buffer_head *bh)
}
}
/*
/*
* Submit all of the bios for all of the ioends we have saved up,
* Submit all of the bios for all of the ioends we have saved up, covering the
* covering the initial writepage page and also any probed pages.
* initial writepage page and also any probed pages.
*
* Because we may have multiple ioends spanning a page, we need to start
* writeback on all the buffers before we submit them for I/O. If we mark the
* buffers as we got, then we can end up with a page that only has buffers
* marked async write and I/O complete on can occur before we mark the other
* buffers async write.
*
* The end result of this is that we trip a bug in end_page_writeback() because
* we call it twice for the one page as the code in end_buffer_async_write()
* assumes that all buffers on the page are started at the same time.
*
* The fix is two passes across the ioend list - one to start writeback on the
* bufferheads, and then the second one submit them for I/O.
*/
*/
STATIC
void
STATIC
void
xfs_submit_ioend
(
xfs_submit_ioend
(
xfs_ioend_t
*
ioend
)
xfs_ioend_t
*
ioend
)
{
{
xfs_ioend_t
*
head
=
ioend
;
xfs_ioend_t
*
next
;
xfs_ioend_t
*
next
;
struct
buffer_head
*
bh
;
struct
buffer_head
*
bh
;
struct
bio
*
bio
;
struct
bio
*
bio
;
sector_t
lastblock
=
0
;
sector_t
lastblock
=
0
;
/* Pass 1 - start writeback */
do
{
next
=
ioend
->
io_list
;
for
(
bh
=
ioend
->
io_buffer_head
;
bh
;
bh
=
bh
->
b_private
)
{
xfs_start_buffer_writeback
(
bh
);
}
}
while
((
ioend
=
next
)
!=
NULL
);
/* Pass 2 - submit I/O */
ioend
=
head
;
do
{
do
{
next
=
ioend
->
io_list
;
next
=
ioend
->
io_list
;
bio
=
NULL
;
bio
=
NULL
;
for
(
bh
=
ioend
->
io_buffer_head
;
bh
;
bh
=
bh
->
b_private
)
{
for
(
bh
=
ioend
->
io_buffer_head
;
bh
;
bh
=
bh
->
b_private
)
{
xfs_start_buffer_writeback
(
bh
);
if
(
!
bio
)
{
if
(
!
bio
)
{
retry:
retry:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录