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
cc643cf2
Commit
cc643cf2
authored
Nov 13, 2003
by
Anton Altaparmakov
Browse files
Options
Browse Files
Download
Plain Diff
Merge cantab.net:/home/aia21/bklinux-2.5
into cantab.net:/home/aia21/ntfs-2.6
parents
4776d260
737db367
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
20 deletions
+29
-20
Documentation/filesystems/ntfs.txt
Documentation/filesystems/ntfs.txt
+4
-0
fs/ntfs/ChangeLog
fs/ntfs/ChangeLog
+8
-0
fs/ntfs/Makefile
fs/ntfs/Makefile
+1
-1
fs/ntfs/attrib.c
fs/ntfs/attrib.c
+15
-18
fs/ntfs/attrib.h
fs/ntfs/attrib.h
+1
-1
No files found.
Documentation/filesystems/ntfs.txt
View file @
cc643cf2
...
...
@@ -272,6 +272,10 @@ ChangeLog
Note, a technical ChangeLog aimed at kernel hackers is in fs/ntfs/ChangeLog.
2.1.5:
- Minor bug fix in attribute list attribute handling that fixes the
I/O errors on "ls" of certain fragmented files found by at least two
people running Windows XP.
2.1.4:
- Minor update allowing compilation with all gcc versions (well, the
ones the kernel can be compiled with anyway).
...
...
fs/ntfs/ChangeLog
View file @
cc643cf2
...
...
@@ -20,6 +20,14 @@ ToDo:
sufficient for synchronisation here. We then just need to make sure
ntfs_readpage/writepage/truncate interoperate properly with us.
2.1.5 - Fix minor bug in attribute list attribute handling.
- Fix bug in attribute list handling. Actually it is not as much a bug
as too much protection in that we were not allowing attribute lists
which waste space on disk while Windows XP clearly allows it and in
fact creates such attribute lists so our driver was failing.
- Update NTFS documentation ready for 2.6 kernel release.
2.1.4 - Reduce compiler requirements.
- Remove all uses of unnamed structs and unions in the driver to make
...
...
fs/ntfs/Makefile
View file @
cc643cf2
...
...
@@ -5,7 +5,7 @@ obj-$(CONFIG_NTFS_FS) += ntfs.o
ntfs-objs
:=
aops.o attrib.o compress.o debug.o dir.o file.o inode.o mft.o
\
mst.o namei.o super.o sysctl.o time.o unistr.o upcase.o
EXTRA_CFLAGS
=
-DNTFS_VERSION
=
\"
2.1.
4
\"
EXTRA_CFLAGS
=
-DNTFS_VERSION
=
\"
2.1.
5
\"
ifeq
($(CONFIG_NTFS_DEBUG),y)
EXTRA_CFLAGS
+=
-DDEBUG
...
...
fs/ntfs/attrib.c
View file @
cc643cf2
...
...
@@ -1215,7 +1215,7 @@ BOOL find_attr(const ATTR_TYPES type, const uchar_t *name, const u32 name_len,
* load_attribute_list - load an attribute list into memory
* @vol: ntfs volume from which to read
* @run_list: run list of the attribute list
* @al
:
destination buffer
* @al
_start:
destination buffer
* @size: size of the destination buffer in bytes
* @initialized_size: initialized size of the attribute list
*
...
...
@@ -1227,10 +1227,11 @@ BOOL find_attr(const ATTR_TYPES type, const uchar_t *name, const u32 name_len,
*
* Return 0 on success or -errno on error.
*/
int
load_attribute_list
(
ntfs_volume
*
vol
,
run_list
*
run_list
,
u8
*
al
,
int
load_attribute_list
(
ntfs_volume
*
vol
,
run_list
*
run_list
,
u8
*
al
_start
,
const
s64
size
,
const
s64
initialized_size
)
{
LCN
lcn
;
u8
*
al
=
al_start
;
u8
*
al_end
=
al
+
initialized_size
;
run_list_element
*
rl
;
struct
buffer_head
*
bh
;
...
...
@@ -1284,32 +1285,28 @@ int load_attribute_list(ntfs_volume *vol, run_list *run_list, u8 *al,
}
if
(
initialized_size
<
size
)
{
initialize:
memset
(
al
+
initialized_size
,
0
,
size
-
initialized_size
);
memset
(
al
_start
+
initialized_size
,
0
,
size
-
initialized_size
);
}
done:
up_read
(
&
run_list
->
lock
);
return
err
;
do_final:
if
(
al
<
al_end
)
{
/* Partial block. */
memcpy
(
al
,
bh
->
b_data
,
al_end
-
al
);
brelse
(
bh
);
/*
* Skip sanity checking if initialized_size < size as it is
* too much trouble.
* Partial block.
*
* Note: The attribute list can be smaller than its allocation
* by multiple clusters. This has been encountered by at least
* two people running Windows XP, thus we cannot do any
* truncation sanity checking here. (AIA)
*/
memcpy
(
al
,
bh
->
b_data
,
al_end
-
al
);
brelse
(
bh
);
if
(
initialized_size
<
size
)
goto
initialize
;
/* If the final lcn is partial all is fine. */
if
(((
s64
)(
block
-
(
lcn
<<
vol
->
cluster_size_bits
>>
block_size_bits
))
<<
block_size_bits
>>
vol
->
cluster_size_bits
)
==
rl
->
length
-
1
)
{
if
(
!
rl
[
1
].
length
||
(
rl
[
1
].
lcn
==
LCN_RL_NOT_MAPPED
&&
!
rl
[
2
].
length
))
goto
done
;
}
}
else
brelse
(
bh
);
goto
done
;
}
brelse
(
bh
);
/* Real overflow! */
ntfs_error
(
sb
,
"Attribute list buffer overflow. Read attribute list "
"is truncated."
);
...
...
fs/ntfs/attrib.h
View file @
cc643cf2
...
...
@@ -87,7 +87,7 @@ BOOL lookup_attr(const ATTR_TYPES type, const uchar_t *name, const u32 name_len,
const
IGNORE_CASE_BOOL
ic
,
const
VCN
lowest_vcn
,
const
u8
*
val
,
const
u32
val_len
,
attr_search_context
*
ctx
);
extern
int
load_attribute_list
(
ntfs_volume
*
vol
,
run_list
*
rl
,
u8
*
al
,
extern
int
load_attribute_list
(
ntfs_volume
*
vol
,
run_list
*
rl
,
u8
*
al
_start
,
const
s64
size
,
const
s64
initialized_size
);
static
inline
s64
attribute_value_length
(
const
ATTR_RECORD
*
a
)
...
...
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