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
c9d1f9b9
Commit
c9d1f9b9
authored
Apr 01, 2003
by
Rusty Russell
Committed by
Linus Torvalds
Apr 01, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] remove unreachable code (and comments) in fs/befs/linuxvfs.c
From: Will Dyson <will_dyson@pobox.com>
parent
94ea2783
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
12 deletions
+16
-12
fs/befs/btree.c
fs/befs/btree.c
+7
-7
fs/befs/linuxvfs.c
fs/befs/linuxvfs.c
+9
-5
No files found.
fs/befs/btree.c
View file @
c9d1f9b9
...
...
@@ -324,7 +324,7 @@ befs_btree_find(struct super_block *sb, befs_data_stream * ds,
*
* finds exact match if one exists, and returns BEFS_BT_MATCH
* If no exact match, finds first key in node that is greater
* (alp
abetic
ly) than the search key and returns BEFS_BT_PARMATCH
* (alp
habetical
ly) than the search key and returns BEFS_BT_PARMATCH
* (for partial match, I guess). Can you think of something better to
* call it?
*
...
...
@@ -402,9 +402,9 @@ befs_find_key(struct super_block *sb, befs_btree_node * node,
* @value: Value stored with the returned key
*
* Heres how it works: Key_no is the index of the key/value pair to
* retun in keybuf/value.
* retu
r
n in keybuf/value.
* Bufsize is the size of keybuf (BEFS_NAME_LEN+1 is a good size). Keysize is
* the number of charecters in the key (just a convience).
* the number of charecters in the key (just a conv
en
ience).
*
* Algorithm:
* Get the first leafnode of the tree. See if the requested key is in that
...
...
@@ -530,7 +530,7 @@ befs_btree_read(struct super_block *sb, befs_data_stream * ds,
* befs_btree_seekleaf - Find the first leafnode in the btree
* @sb: Filesystem superblock
* @ds: Datastream containing btree
* @bt_super: Pointer to the uperblock of the btree
* @bt_super: Pointer to the
s
uperblock of the btree
* @this_node: Buffer to return the leafnode in
* @node_off: Pointer to offset of current node within datastream. Modified
* by the function.
...
...
@@ -615,10 +615,10 @@ befs_leafnode(befs_btree_node * node)
* of the B+tree node *@node
*
* "The length of all the keys in the node is added to the size of the
* header and then rounded up to a multiple of four to get the begining
* header and then rounded up to a multiple of four to get the begin
n
ing
* of the key length index" (p.88, practical filesystem design).
*
* Exept that rounding up to 8 works, and rounding up to 4 doesn't.
* Ex
c
ept that rounding up to 8 works, and rounding up to 4 doesn't.
*/
static
u16
*
befs_bt_keylen_index
(
befs_btree_node
*
node
)
...
...
@@ -704,7 +704,7 @@ befs_bt_get_key(struct super_block *sb, befs_btree_node * node,
* @key1: pointer to the first key to be compared
* @keylen1: length in bytes of key1
* @key2: pointer to the second key to be compared
* @kelen2: leng
ht
in bytes of key2
* @kelen2: leng
th
in bytes of key2
*
* Returns 0 if @key1 and @key2 are equal.
* Returns >0 if @key1 is greater.
...
...
fs/befs/linuxvfs.c
View file @
c9d1f9b9
...
...
@@ -345,7 +345,7 @@ befs_read_inode(struct inode *inode)
/*
* set uid and gid. But since current BeOS is single user OS, so
* you can change by "uid" or "gid" options.
*/
*/
inode
->
i_uid
=
befs_sb
->
mount_opts
.
use_uid
?
befs_sb
->
mount_opts
.
uid
:
(
uid_t
)
fs32_to_cpu
(
sb
,
raw_inode
->
uid
);
...
...
@@ -358,11 +358,14 @@ befs_read_inode(struct inode *inode)
* BEFS's time is 64 bits, but current VFS is 32 bits...
* BEFS don't have access time. Nor inode change time. VFS
* doesn't have creation time.
* Also, the lower 16 bits of the last_modified_time and
* create_time are just a counter to help ensure uniqueness
* for indexing purposes. (PFD, page 54)
*/
inode
->
i_mtime
.
tv_sec
=
fs64_to_cpu
(
sb
,
raw_inode
->
last_modified_time
)
>>
16
;
inode
->
i_mtime
.
tv_nsec
=
0
;
/*
use the lower bits ?
*/
inode
->
i_mtime
.
tv_nsec
=
0
;
/*
lower 16 bits are not a time
*/
inode
->
i_ctime
=
inode
->
i_mtime
;
inode
->
i_atime
=
inode
->
i_mtime
;
inode
->
i_blksize
=
befs_sb
->
block_size
;
...
...
@@ -527,6 +530,7 @@ befs_readlink(struct dentry *dentry, char *buffer, int buflen)
/*
* UTF-8 to NLS charset convert routine
*
*
* Changed 8/10/01 by Will Dyson. Now use uni2char() / char2uni() rather than
* the nls tables directly
...
...
@@ -572,11 +576,11 @@ befs_utf2nls(struct super_block *sb, const char *in,
}
}
result
[
o
]
=
'\0'
;
*
out_len
=
o
;
befs_debug
(
sb
,
"<--- utf2nls()"
);
return
o
;
*
out_len
=
o
;
conv_err:
befs_error
(
sb
,
"Name using charecter set %s contains a charecter that "
...
...
@@ -602,8 +606,8 @@ befs_utf2nls(struct super_block *sb, const char *in,
*
* On return, *@destlen is the length of @dest in bytes.
*
* On success, the return value is the number of utf8 char
e
cters written to
* the ouput buffer @dest.
* On success, the return value is the number of utf8 char
a
cters written to
* the ou
t
put buffer @dest.
*
* On Failure, a negative number coresponding to the error code is returned.
*/
...
...
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