Skip to content

Commit e60f749

Browse files
committed
befs: remove trailing whitespaces
Removing all trailing whitespaces in befs. I was skeptic about tainting the history with this, but whitespace changes can be ignored by using 'git blame -w' and 'git log -w'. Signed-off-by: Luis de Bethencourt <[email protected]>
1 parent 50b00fc commit e60f749

File tree

7 files changed

+47
-48
lines changed

7 files changed

+47
-48
lines changed

fs/befs/befs_fs_types.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ enum inode_flags {
7979
BEFS_INODE_WAS_WRITTEN = 0x00020000,
8080
BEFS_NO_TRANSACTION = 0x00040000,
8181
};
82-
/*
82+
/*
8383
* On-Disk datastructures of BeFS
8484
*/
8585

@@ -139,7 +139,7 @@ typedef struct {
139139

140140
} PACKED befs_super_block;
141141

142-
/*
142+
/*
143143
* Note: the indirect and dbl_indir block_runs may
144144
* be longer than one block!
145145
*/

fs/befs/btree.c

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
*
1313
* Dominic Giampaolo, author of "Practical File System
1414
* Design with the Be File System", for such a helpful book.
15-
*
16-
* Marcus J. Ranum, author of the b+tree package in
15+
*
16+
* Marcus J. Ranum, author of the b+tree package in
1717
* comp.sources.misc volume 10. This code is not copied from that
1818
* work, but it is partially based on it.
1919
*
@@ -38,38 +38,38 @@
3838
*/
3939

4040
/* Befs B+tree structure:
41-
*
41+
*
4242
* The first thing in the tree is the tree superblock. It tells you
4343
* all kinds of useful things about the tree, like where the rootnode
4444
* is located, and the size of the nodes (always 1024 with current version
4545
* of BeOS).
4646
*
4747
* The rest of the tree consists of a series of nodes. Nodes contain a header
48-
* (struct befs_btree_nodehead), the packed key data, an array of shorts
48+
* (struct befs_btree_nodehead), the packed key data, an array of shorts
4949
* containing the ending offsets for each of the keys, and an array of
50-
* befs_off_t values. In interior nodes, the keys are the ending keys for
51-
* the childnode they point to, and the values are offsets into the
52-
* datastream containing the tree.
50+
* befs_off_t values. In interior nodes, the keys are the ending keys for
51+
* the childnode they point to, and the values are offsets into the
52+
* datastream containing the tree.
5353
*/
5454

5555
/* Note:
56-
*
57-
* The book states 2 confusing things about befs b+trees. First,
56+
*
57+
* The book states 2 confusing things about befs b+trees. First,
5858
* it states that the overflow field of node headers is used by internal nodes
5959
* to point to another node that "effectively continues this one". Here is what
6060
* I believe that means. Each key in internal nodes points to another node that
61-
* contains key values less than itself. Inspection reveals that the last key
62-
* in the internal node is not the last key in the index. Keys that are
63-
* greater than the last key in the internal node go into the overflow node.
61+
* contains key values less than itself. Inspection reveals that the last key
62+
* in the internal node is not the last key in the index. Keys that are
63+
* greater than the last key in the internal node go into the overflow node.
6464
* I imagine there is a performance reason for this.
6565
*
66-
* Second, it states that the header of a btree node is sufficient to
67-
* distinguish internal nodes from leaf nodes. Without saying exactly how.
66+
* Second, it states that the header of a btree node is sufficient to
67+
* distinguish internal nodes from leaf nodes. Without saying exactly how.
6868
* After figuring out the first, it becomes obvious that internal nodes have
6969
* overflow nodes and leafnodes do not.
7070
*/
7171

72-
/*
72+
/*
7373
* Currently, this code is only good for directory B+trees.
7474
* In order to be used for other BFS indexes, it needs to be extended to handle
7575
* duplicate keys and non-string keytypes (int32, int64, float, double).
@@ -237,8 +237,8 @@ befs_bt_read_node(struct super_block *sb, const befs_data_stream *ds,
237237
* with @key (usually the disk block number of an inode).
238238
*
239239
* On failure, returns BEFS_ERR or BEFS_BT_NOT_FOUND.
240-
*
241-
* Algorithm:
240+
*
241+
* Algorithm:
242242
* Read the superblock and rootnode of the b+tree.
243243
* Drill down through the interior nodes using befs_find_key().
244244
* Once at the correct leaf node, use befs_find_key() again to get the
@@ -402,12 +402,12 @@ befs_find_key(struct super_block *sb, struct befs_btree_node *node,
402402
*
403403
* Here's how it works: Key_no is the index of the key/value pair to
404404
* return in keybuf/value.
405-
* Bufsize is the size of keybuf (BEFS_NAME_LEN+1 is a good size). Keysize is
405+
* Bufsize is the size of keybuf (BEFS_NAME_LEN+1 is a good size). Keysize is
406406
* the number of characters in the key (just a convenience).
407407
*
408408
* Algorithm:
409409
* Get the first leafnode of the tree. See if the requested key is in that
410-
* node. If not, follow the node->right link to the next leafnode. Repeat
410+
* node. If not, follow the node->right link to the next leafnode. Repeat
411411
* until the (key_no)th key is found or the tree is out of keys.
412412
*/
413413
int
@@ -536,7 +536,7 @@ befs_btree_read(struct super_block *sb, const befs_data_stream *ds,
536536
* @node_off: Pointer to offset of current node within datastream. Modified
537537
* by the function.
538538
*
539-
* Helper function for btree traverse. Moves the current position to the
539+
* Helper function for btree traverse. Moves the current position to the
540540
* start of the first leaf node.
541541
*
542542
* Also checks for an empty tree. If there are no keys, returns BEFS_BT_EMPTY.
@@ -592,10 +592,10 @@ befs_btree_seekleaf(struct super_block *sb, const befs_data_stream *ds,
592592
}
593593

594594
/**
595-
* befs_leafnode - Determine if the btree node is a leaf node or an
595+
* befs_leafnode - Determine if the btree node is a leaf node or an
596596
* interior node
597597
* @node: Pointer to node structure to test
598-
*
598+
*
599599
* Return 1 if leaf, 0 if interior
600600
*/
601601
static int
@@ -656,7 +656,7 @@ befs_bt_valarray(struct befs_btree_node *node)
656656
* @node: Pointer to the node structure to find the keydata array within
657657
*
658658
* Returns a pointer to the start of the keydata array
659-
* of the node pointed to by the node header
659+
* of the node pointed to by the node header
660660
*/
661661
static char *
662662
befs_bt_keydata(struct befs_btree_node *node)
@@ -702,7 +702,7 @@ befs_bt_get_key(struct super_block *sb, struct befs_btree_node *node,
702702

703703
/**
704704
* befs_compare_strings - compare two strings
705-
* @key1: pointer to the first key to be compared
705+
* @key1: pointer to the first key to be compared
706706
* @keylen1: length in bytes of key1
707707
* @key2: pointer to the second key to be compared
708708
* @keylen2: length in bytes of key2

fs/befs/btree.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* btree.h
3-
*
3+
*
44
*/
55

66
int befs_btree_find(struct super_block *sb, const befs_data_stream *ds,

fs/befs/datastream.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ befs_read_datastream(struct super_block *sb, const befs_data_stream *ds,
8484
*
8585
* Takes a file position and gives back a brun who's starting block
8686
* is block number fblock of the file.
87-
*
87+
*
8888
* Returns BEFS_OK or BEFS_ERR.
89-
*
89+
*
9090
* Calls specialized functions for each of the three possible
9191
* datastream regions.
9292
*/
@@ -118,7 +118,7 @@ befs_fblock2brun(struct super_block *sb, const befs_data_stream *data,
118118

119119
/**
120120
* befs_read_lsmylink - read long symlink from datastream.
121-
* @sb: Filesystem superblock
121+
* @sb: Filesystem superblock
122122
* @ds: Datastream to read from
123123
* @buff: Buffer in which to place long symlink data
124124
* @len: Length of the long symlink in bytes

fs/befs/inode.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* inode.h
3-
*
3+
*
44
*/
55

66
int befs_check_inode(struct super_block *sb, befs_inode *raw_inode,

fs/befs/io.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,3 @@
44

55
struct buffer_head *befs_bread_iaddr(struct super_block *sb,
66
befs_inode_addr iaddr);
7-

fs/befs/linuxvfs.c

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ static const struct address_space_operations befs_symlink_aops = {
8484
.readpage = befs_symlink_readpage,
8585
};
8686

87-
/*
87+
/*
8888
* Called by generic_file_read() to read a page of data
89-
*
89+
*
9090
* In turn, simply calls a generic block read function and
9191
* passes it the address of befs_get_block, for mapping file
9292
* positions to disk blocks.
@@ -103,8 +103,8 @@ befs_bmap(struct address_space *mapping, sector_t block)
103103
return generic_block_bmap(mapping, block, befs_get_block);
104104
}
105105

106-
/*
107-
* Generic function to map a file position (block) to a
106+
/*
107+
* Generic function to map a file position (block) to a
108108
* disk offset (passed back in bh_result).
109109
*
110110
* Used by many higher level functions.
@@ -337,7 +337,7 @@ static struct inode *befs_iget(struct super_block *sb, unsigned long ino)
337337
/*
338338
* set uid and gid. But since current BeOS is single user OS, so
339339
* you can change by "uid" or "gid" options.
340-
*/
340+
*/
341341

342342
inode->i_uid = befs_sb->mount_opts.use_uid ?
343343
befs_sb->mount_opts.uid :
@@ -352,14 +352,14 @@ static struct inode *befs_iget(struct super_block *sb, unsigned long ino)
352352
* BEFS's time is 64 bits, but current VFS is 32 bits...
353353
* BEFS don't have access time. Nor inode change time. VFS
354354
* doesn't have creation time.
355-
* Also, the lower 16 bits of the last_modified_time and
355+
* Also, the lower 16 bits of the last_modified_time and
356356
* create_time are just a counter to help ensure uniqueness
357357
* for indexing purposes. (PFD, page 54)
358358
*/
359359

360360
inode->i_mtime.tv_sec =
361361
fs64_to_cpu(sb, raw_inode->last_modified_time) >> 16;
362-
inode->i_mtime.tv_nsec = 0; /* lower 16 bits are not a time */
362+
inode->i_mtime.tv_nsec = 0; /* lower 16 bits are not a time */
363363
inode->i_ctime = inode->i_mtime;
364364
inode->i_atime = inode->i_mtime;
365365

@@ -441,7 +441,7 @@ befs_init_inodecache(void)
441441
}
442442

443443
/* Called at fs teardown.
444-
*
444+
*
445445
* Taken from NFS implementation by Al Viro.
446446
*/
447447
static void
@@ -491,7 +491,7 @@ static int befs_symlink_readpage(struct file *unused, struct page *page)
491491

492492
/*
493493
* UTF-8 to NLS charset convert routine
494-
*
494+
*
495495
* Uses uni2char() / char2uni() rather than the nls tables directly
496496
*/
497497
static int
@@ -556,18 +556,18 @@ befs_utf2nls(struct super_block *sb, const char *in,
556556
* @in_len: Length of input string in bytes
557557
* @out: The output string in UTF-8 format
558558
* @out_len: Length of the output buffer
559-
*
559+
*
560560
* Converts input string @in, which is in the format of the loaded NLS map,
561561
* into a utf8 string.
562-
*
562+
*
563563
* The destination string @out is allocated by this function and the caller is
564564
* responsible for freeing it with kfree()
565-
*
565+
*
566566
* On return, *@out_len is the length of @out in bytes.
567567
*
568568
* On success, the return value is the number of utf8 characters written to
569569
* the output buffer @out.
570-
*
570+
*
571571
* On Failure, a negative number coresponding to the error code is returned.
572572
*/
573573

@@ -719,7 +719,7 @@ parse_options(char *options, struct befs_mount_options *opts)
719719
}
720720

721721
/* This function has the responsibiltiy of getting the
722-
* filesystem ready for unmounting.
722+
* filesystem ready for unmounting.
723723
* Basically, we free everything that we allocated in
724724
* befs_read_inode
725725
*/
@@ -780,7 +780,7 @@ befs_fill_super(struct super_block *sb, void *data, int silent)
780780
* Linux 2.4.10 and later refuse to read blocks smaller than
781781
* the logical block size for the device. But we also need to read at
782782
* least 1k to get the second 512 bytes of the volume.
783-
*/
783+
*/
784784
blocksize = sb_min_blocksize(sb, 1024);
785785
if (!blocksize) {
786786
if (!silent)
@@ -917,7 +917,7 @@ static struct file_system_type befs_fs_type = {
917917
.name = "befs",
918918
.mount = befs_mount,
919919
.kill_sb = kill_block_super,
920-
.fs_flags = FS_REQUIRES_DEV,
920+
.fs_flags = FS_REQUIRES_DEV,
921921
};
922922
MODULE_ALIAS_FS("befs");
923923

0 commit comments

Comments
 (0)