diff options
author | plougher <plougher> | 2009-01-31 07:31:07 +0000 |
---|---|---|
committer | Mohamad Ayyash <mkayyash@google.com> | 2015-02-23 12:34:11 -0800 |
commit | d7941bf6ba6663349f8feb099503133df001daa2 (patch) | |
tree | 2d2a81d92cb621e95df853757eb217be3605cda8 /kernel | |
parent | 14a04238770d70c32baeaa37b5a500699a98299e (diff) | |
download | squashfs-tools-d7941bf6ba6663349f8feb099503133df001daa2.tar.gz |
More comments.
Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/fs/squashfs/export.c | 5 | ||||
-rw-r--r-- | kernel/fs/squashfs/fragment.c | 9 | ||||
-rw-r--r-- | kernel/fs/squashfs/id.c | 8 |
3 files changed, 19 insertions, 3 deletions
diff --git a/kernel/fs/squashfs/export.c b/kernel/fs/squashfs/export.c index 67505a8..27aadbe 100644 --- a/kernel/fs/squashfs/export.c +++ b/kernel/fs/squashfs/export.c @@ -117,6 +117,9 @@ static struct dentry *squashfs_get_parent(struct dentry *child) } +/* + * Read uncompressed inode lookup table indexes off disk into memory + */ __le64 *squashfs_read_inode_lookup_table(struct super_block *sb, long long lookup_table_start, unsigned int inodes) { @@ -126,7 +129,7 @@ __le64 *squashfs_read_inode_lookup_table(struct super_block *sb, TRACE("In read_inode_lookup_table, length %d\n", length); - /* Allocate inode lookup table */ + /* Allocate inode lookup table indexes */ inode_lookup_table = kmalloc(length, GFP_KERNEL); if (inode_lookup_table == NULL) { ERROR("Failed to allocate inode lookup table\n"); diff --git a/kernel/fs/squashfs/fragment.c b/kernel/fs/squashfs/fragment.c index 6ac96cb..a6520ff 100644 --- a/kernel/fs/squashfs/fragment.c +++ b/kernel/fs/squashfs/fragment.c @@ -43,6 +43,10 @@ #include "squashfs_fs_i.h" #include "squashfs.h" +/* + * Look-up fragment using the fragment index table. Return the on disk + * location of the fragment and its compressed size + */ int squashfs_frag_location(struct super_block *sb, unsigned int fragment, long long *fragment_block) { @@ -65,6 +69,9 @@ int squashfs_frag_location(struct super_block *sb, unsigned int fragment, } +/* + * Read the uncompressed fragment lookup table indexes off disk into memory + */ __le64 *squashfs_read_fragment_index_table(struct super_block *sb, long long fragment_table_start, unsigned int fragments) { @@ -72,7 +79,7 @@ __le64 *squashfs_read_fragment_index_table(struct super_block *sb, __le64 *fragment_index; int err; - /* Allocate fragment index table */ + /* Allocate fragment lookup table indexes */ fragment_index = kmalloc(length, GFP_KERNEL); if (fragment_index == NULL) { ERROR("Failed to allocate fragment index table\n"); diff --git a/kernel/fs/squashfs/id.c b/kernel/fs/squashfs/id.c index 46f0621..e69fa1b 100644 --- a/kernel/fs/squashfs/id.c +++ b/kernel/fs/squashfs/id.c @@ -41,6 +41,9 @@ #include "squashfs_fs_i.h" #include "squashfs.h" +/* + * Map uid/gid index into real 32-bit uid/gid using the id look up table + */ int squashfs_get_id(struct super_block *sb, unsigned int index, unsigned int *id) { @@ -61,6 +64,9 @@ int squashfs_get_id(struct super_block *sb, unsigned int index, } +/* + * Read uncompressed id lookup table indexes from disk into memory + */ __le64 *squashfs_read_id_index_table(struct super_block *sb, long long id_table_start, unsigned short no_ids) { @@ -70,7 +76,7 @@ __le64 *squashfs_read_id_index_table(struct super_block *sb, TRACE("In read_id_index_table, length %d\n", length); - /* Allocate id index table */ + /* Allocate id lookup table indexes */ id_table = kmalloc(length, GFP_KERNEL); if (id_table == NULL) { ERROR("Failed to allocate id index table\n"); |