diff options
author | Thomas Bächler <thomas@archlinux.org> | 2008-04-10 18:29:56 +0200 |
---|---|---|
committer | Thomas Bächler <thomas@archlinux.org> | 2008-04-10 18:29:56 +0200 |
commit | 6a7ff686c0793a1378ff381e5a4b713b6d3a10c6 (patch) | |
tree | 0419e297c546974f87021183bc9b0109a630116b /patches | |
parent | 8dff281fd663668e6d2895275c89d393ccd49321 (diff) |
Update to 2.6.25-0.2-ARCH
Diffstat (limited to 'patches')
-rw-r--r-- | patches/squashfs-2.6.25.patch | 103 |
1 files changed, 103 insertions, 0 deletions
diff --git a/patches/squashfs-2.6.25.patch b/patches/squashfs-2.6.25.patch new file mode 100644 index 0000000..225b3cd --- /dev/null +++ b/patches/squashfs-2.6.25.patch @@ -0,0 +1,103 @@ +diff -r -u squashfs-dist/kernel/fs/squashfs/inode.c squashfs-ck/kernel/fs/squashfs/inode.c +--- squashfs-dist/kernel/fs/squashfs/inode.c 2007-11-08 14:21:23.000000000 -0500 ++++ squashfs-ck/kernel/fs/squashfs/inode.c 2008-02-27 13:09:42.000000000 -0500 +@@ -28,6 +28,7 @@ + #include <linux/squashfs_fs_sb.h> + #include <linux/squashfs_fs_i.h> + #include <linux/buffer_head.h> ++#include <linux/exportfs.h> + #include <linux/vfs.h> + #include <linux/vmalloc.h> + #include <linux/smp_lock.h> +@@ -36,7 +37,6 @@ + + static int squashfs_cached_blks; + +-static void vfs_read_inode(struct inode *i); + static struct dentry *squashfs_get_parent(struct dentry *child); + static int squashfs_read_inode(struct inode *i, squashfs_inode_t inode); + static int squashfs_statfs(struct dentry *, struct kstatfs *); +@@ -82,7 +82,6 @@ + .destroy_inode = squashfs_destroy_inode, + .statfs = squashfs_statfs, + .put_super = squashfs_put_super, +- .read_inode = vfs_read_inode + }; + + static struct export_operations squashfs_export_ops = { +@@ -600,53 +599,12 @@ + else + i->i_gid = msblk->guid[inodeb->guid]; + } +- +- +-static squashfs_inode_t squashfs_inode_lookup(struct super_block *s, int ino) +-{ +- struct squashfs_sb_info *msblk = s->s_fs_info; +- long long start = msblk->inode_lookup_table[SQUASHFS_LOOKUP_BLOCK(ino - 1)]; +- int offset = SQUASHFS_LOOKUP_BLOCK_OFFSET(ino - 1); +- squashfs_inode_t inode; +- +- TRACE("Entered squashfs_inode_lookup, inode_number = %d\n", ino); +- +- if (msblk->swap) { +- squashfs_inode_t sinode; +- +- if (!squashfs_get_cached_block(s, &sinode, start, offset, +- sizeof(sinode), &start, &offset)) +- goto out; +- SQUASHFS_SWAP_INODE_T((&inode), &sinode); +- } else if (!squashfs_get_cached_block(s, &inode, start, offset, +- sizeof(inode), &start, &offset)) +- goto out; +- +- TRACE("squashfs_inode_lookup, inode = 0x%llx\n", inode); +- +- return inode; +- +-out: +- return SQUASHFS_INVALID_BLK; +-} + + +-static void vfs_read_inode(struct inode *i) +-{ +- struct squashfs_sb_info *msblk = i->i_sb->s_fs_info; +- squashfs_inode_t inode = squashfs_inode_lookup(i->i_sb, i->i_ino); +- +- TRACE("Entered vfs_read_inode\n"); +- +- if(inode != SQUASHFS_INVALID_BLK) +- (msblk->read_inode)(i, inode); +-} +- +- + static struct dentry *squashfs_get_parent(struct dentry *child) + { + struct inode *i = child->d_inode; +- struct inode *parent = iget(i->i_sb, SQUASHFS_I(i)->u.s2.parent_inode); ++ struct inode *parent = iget_locked(i->i_sb, SQUASHFS_I(i)->u.s2.parent_inode); + struct dentry *rv; + + TRACE("Entered squashfs_get_parent\n"); +@@ -657,6 +615,10 @@ + } + + rv = d_alloc_anon(parent); ++ if(parent->i_state & I_NEW) { ++ unlock_new_inode(parent); ++ } ++ + if(rv == NULL) + rv = ERR_PTR(-ENOMEM); + +@@ -673,6 +635,9 @@ + + TRACE("Entered squashfs_iget\n"); + ++ if(!i) ++ return ERR_PTR(-ENOMEM); ++ + if(i && (i->i_state & I_NEW)) { + (msblk->read_inode)(i, inode); + unlock_new_inode(i); |