Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
1913fccc
Commit
1913fccc
authored
Sep 14, 2002
by
Anton Altaparmakov
Browse files
Options
Browse Files
Download
Plain Diff
Merge cantab.net:/usr/src/bklinux-2.5 into cantab.net:/usr/src/ntfs-2.5
parents
acf7aa2c
d97516bf
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
7 deletions
+17
-7
fs/ntfs/aops.c
fs/ntfs/aops.c
+17
-7
No files found.
fs/ntfs/aops.c
View file @
1913fccc
...
@@ -1018,7 +1018,6 @@ static int ntfs_prepare_nonresident_write(struct page *page,
...
@@ -1018,7 +1018,6 @@ static int ntfs_prepare_nonresident_write(struct page *page,
ntfs_volume
*
vol
;
ntfs_volume
*
vol
;
run_list_element
*
rl
;
run_list_element
*
rl
;
struct
buffer_head
*
bh
,
*
head
,
*
wait
[
2
],
**
wait_bh
=
wait
;
struct
buffer_head
*
bh
,
*
head
,
*
wait
[
2
],
**
wait_bh
=
wait
;
char
*
kaddr
=
page_address
(
page
);
unsigned
int
vcn_ofs
,
block_start
,
block_end
,
blocksize
;
unsigned
int
vcn_ofs
,
block_start
,
block_end
,
blocksize
;
int
err
;
int
err
;
BOOL
is_retry
;
BOOL
is_retry
;
...
@@ -1267,13 +1266,20 @@ static int ntfs_prepare_nonresident_write(struct page *page,
...
@@ -1267,13 +1266,20 @@ static int ntfs_prepare_nonresident_write(struct page *page,
* region. NOTE: This is how we decide if to
* region. NOTE: This is how we decide if to
* zero or not!
* zero or not!
*/
*/
if
(
block_end
>
to
||
block_start
<
from
)
{
void
*
kaddr
;
kaddr
=
kmap_atomic
(
page
,
KM_USER0
);
if
(
block_end
>
to
)
if
(
block_end
>
to
)
memset
(
kaddr
+
to
,
0
,
block_end
-
to
);
memset
(
kaddr
+
to
,
0
,
block_end
-
to
);
if
(
block_start
<
from
)
if
(
block_start
<
from
)
memset
(
kaddr
+
block_start
,
0
,
memset
(
kaddr
+
block_start
,
0
,
from
-
block_start
);
from
-
if
(
block_end
>
to
||
block_start
<
from
)
block_start
);
flush_dcache_page
(
page
);
flush_dcache_page
(
page
);
kunmap_atomic
(
kaddr
,
KM_USER0
);
}
continue
;
continue
;
}
}
}
}
...
@@ -1330,10 +1336,14 @@ static int ntfs_prepare_nonresident_write(struct page *page,
...
@@ -1330,10 +1336,14 @@ static int ntfs_prepare_nonresident_write(struct page *page,
if
(
block_start
>=
to
)
if
(
block_start
>=
to
)
break
;
break
;
if
(
buffer_new
(
bh
))
{
if
(
buffer_new
(
bh
))
{
void
*
kaddr
;
clear_buffer_new
(
bh
);
clear_buffer_new
(
bh
);
if
(
buffer_uptodate
(
bh
))
if
(
buffer_uptodate
(
bh
))
buffer_error
();
buffer_error
();
kaddr
=
kmap_atomic
(
page
,
KM_USER0
);
memset
(
kaddr
+
block_start
,
0
,
bh
->
b_size
);
memset
(
kaddr
+
block_start
,
0
,
bh
->
b_size
);
kunmap_atomic
(
kaddr
,
KM_USER0
);
set_buffer_uptodate
(
bh
);
set_buffer_uptodate
(
bh
);
mark_buffer_dirty
(
bh
);
mark_buffer_dirty
(
bh
);
is_retry
=
TRUE
;
is_retry
=
TRUE
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment