diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-12-10 16:54:28 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2014-01-25 03:13:02 -0500 |
commit | f7f4f4dd6948e3bca0e04e5217c825052ad88f5a (patch) | |
tree | e7e047f1ec986eb4f0795d98cda5801aa265221e | |
parent | 2309fb8ef40e82c4175100c37eb3d9db9e572ca5 (diff) |
cramfs: take headers to fs/cramfs
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | arch/blackfin/kernel/setup.c | 2 | ||||
-rw-r--r-- | arch/cris/arch-v32/drivers/axisflashmap.c | 2 | ||||
-rw-r--r-- | fs/cramfs/inode.c | 24 | ||||
-rw-r--r-- | fs/cramfs/internal.h (renamed from include/linux/cramfs_fs.h) | 6 | ||||
-rw-r--r-- | fs/cramfs/uncompress.c | 2 | ||||
-rw-r--r-- | include/linux/cramfs_fs_sb.h | 20 | ||||
-rw-r--r-- | init/do_mounts_rd.c | 2 |
7 files changed, 23 insertions, 35 deletions
diff --git a/arch/blackfin/kernel/setup.c b/arch/blackfin/kernel/setup.c index 396193042127..4f424ae3b36d 100644 --- a/arch/blackfin/kernel/setup.c +++ b/arch/blackfin/kernel/setup.c | |||
@@ -17,7 +17,7 @@ | |||
17 | #ifdef CONFIG_MTD_UCLINUX | 17 | #ifdef CONFIG_MTD_UCLINUX |
18 | #include <linux/mtd/map.h> | 18 | #include <linux/mtd/map.h> |
19 | #include <linux/ext2_fs.h> | 19 | #include <linux/ext2_fs.h> |
20 | #include <linux/cramfs_fs.h> | 20 | #include <uapi/linux/cramfs_fs.h> |
21 | #include <linux/romfs_fs.h> | 21 | #include <linux/romfs_fs.h> |
22 | #endif | 22 | #endif |
23 | 23 | ||
diff --git a/arch/cris/arch-v32/drivers/axisflashmap.c b/arch/cris/arch-v32/drivers/axisflashmap.c index 1b6ad6247204..28dd77144e8f 100644 --- a/arch/cris/arch-v32/drivers/axisflashmap.c +++ b/arch/cris/arch-v32/drivers/axisflashmap.c | |||
@@ -24,8 +24,6 @@ | |||
24 | #include <linux/mtd/mtdram.h> | 24 | #include <linux/mtd/mtdram.h> |
25 | #include <linux/mtd/partitions.h> | 25 | #include <linux/mtd/partitions.h> |
26 | 26 | ||
27 | #include <linux/cramfs_fs.h> | ||
28 | |||
29 | #include <asm/axisflashmap.h> | 27 | #include <asm/axisflashmap.h> |
30 | #include <asm/mmu.h> | 28 | #include <asm/mmu.h> |
31 | 29 | ||
diff --git a/fs/cramfs/inode.c b/fs/cramfs/inode.c index 508a7524fe38..06610cf94d57 100644 --- a/fs/cramfs/inode.c +++ b/fs/cramfs/inode.c | |||
@@ -17,14 +17,30 @@ | |||
17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
18 | #include <linux/string.h> | 18 | #include <linux/string.h> |
19 | #include <linux/blkdev.h> | 19 | #include <linux/blkdev.h> |
20 | #include <linux/cramfs_fs.h> | ||
21 | #include <linux/slab.h> | 20 | #include <linux/slab.h> |
22 | #include <linux/cramfs_fs_sb.h> | ||
23 | #include <linux/vfs.h> | 21 | #include <linux/vfs.h> |
24 | #include <linux/mutex.h> | 22 | #include <linux/mutex.h> |
25 | 23 | #include <uapi/linux/cramfs_fs.h> | |
26 | #include <asm/uaccess.h> | 24 | #include <asm/uaccess.h> |
27 | 25 | ||
26 | #include "internal.h" | ||
27 | |||
28 | /* | ||
29 | * cramfs super-block data in memory | ||
30 | */ | ||
31 | struct cramfs_sb_info { | ||
32 | unsigned long magic; | ||
33 | unsigned long size; | ||
34 | unsigned long blocks; | ||
35 | unsigned long files; | ||
36 | unsigned long flags; | ||
37 | }; | ||
38 | |||
39 | static inline struct cramfs_sb_info *CRAMFS_SB(struct super_block *sb) | ||
40 | { | ||
41 | return sb->s_fs_info; | ||
42 | } | ||
43 | |||
28 | static const struct super_operations cramfs_ops; | 44 | static const struct super_operations cramfs_ops; |
29 | static const struct inode_operations cramfs_dir_inode_operations; | 45 | static const struct inode_operations cramfs_dir_inode_operations; |
30 | static const struct file_operations cramfs_directory_operations; | 46 | static const struct file_operations cramfs_directory_operations; |
@@ -221,7 +237,7 @@ static void *cramfs_read(struct super_block *sb, unsigned int offset, unsigned i | |||
221 | 237 | ||
222 | static void cramfs_kill_sb(struct super_block *sb) | 238 | static void cramfs_kill_sb(struct super_block *sb) |
223 | { | 239 | { |
224 | struct cramfs_sb_info *sbi = sb->s_fs_info; | 240 | struct cramfs_sb_info *sbi = CRAMFS_SB(sb); |
225 | kill_block_super(sb); | 241 | kill_block_super(sb); |
226 | kfree(sbi); | 242 | kfree(sbi); |
227 | } | 243 | } |
diff --git a/include/linux/cramfs_fs.h b/fs/cramfs/internal.h index 133789609f23..349d71272157 100644 --- a/include/linux/cramfs_fs.h +++ b/fs/cramfs/internal.h | |||
@@ -1,10 +1,4 @@ | |||
1 | #ifndef __CRAMFS_H | ||
2 | #define __CRAMFS_H | ||
3 | |||
4 | #include <uapi/linux/cramfs_fs.h> | ||
5 | |||
6 | /* Uncompression interfaces to the underlying zlib */ | 1 | /* Uncompression interfaces to the underlying zlib */ |
7 | int cramfs_uncompress_block(void *dst, int dstlen, void *src, int srclen); | 2 | int cramfs_uncompress_block(void *dst, int dstlen, void *src, int srclen); |
8 | int cramfs_uncompress_init(void); | 3 | int cramfs_uncompress_init(void); |
9 | void cramfs_uncompress_exit(void); | 4 | void cramfs_uncompress_exit(void); |
10 | #endif | ||
diff --git a/fs/cramfs/uncompress.c b/fs/cramfs/uncompress.c index 023329800d2e..1760c1b84d97 100644 --- a/fs/cramfs/uncompress.c +++ b/fs/cramfs/uncompress.c | |||
@@ -19,7 +19,7 @@ | |||
19 | #include <linux/errno.h> | 19 | #include <linux/errno.h> |
20 | #include <linux/vmalloc.h> | 20 | #include <linux/vmalloc.h> |
21 | #include <linux/zlib.h> | 21 | #include <linux/zlib.h> |
22 | #include <linux/cramfs_fs.h> | 22 | #include "internal.h" |
23 | 23 | ||
24 | static z_stream stream; | 24 | static z_stream stream; |
25 | static int initialized; | 25 | static int initialized; |
diff --git a/include/linux/cramfs_fs_sb.h b/include/linux/cramfs_fs_sb.h deleted file mode 100644 index 8390693568fd..000000000000 --- a/include/linux/cramfs_fs_sb.h +++ /dev/null | |||
@@ -1,20 +0,0 @@ | |||
1 | #ifndef _CRAMFS_FS_SB | ||
2 | #define _CRAMFS_FS_SB | ||
3 | |||
4 | /* | ||
5 | * cramfs super-block data in memory | ||
6 | */ | ||
7 | struct cramfs_sb_info { | ||
8 | unsigned long magic; | ||
9 | unsigned long size; | ||
10 | unsigned long blocks; | ||
11 | unsigned long files; | ||
12 | unsigned long flags; | ||
13 | }; | ||
14 | |||
15 | static inline struct cramfs_sb_info *CRAMFS_SB(struct super_block *sb) | ||
16 | { | ||
17 | return sb->s_fs_info; | ||
18 | } | ||
19 | |||
20 | #endif | ||
diff --git a/init/do_mounts_rd.c b/init/do_mounts_rd.c index 7c098ac9068a..a8227022e3a0 100644 --- a/init/do_mounts_rd.c +++ b/init/do_mounts_rd.c | |||
@@ -13,7 +13,7 @@ | |||
13 | #include <linux/minix_fs.h> | 13 | #include <linux/minix_fs.h> |
14 | #include <linux/ext2_fs.h> | 14 | #include <linux/ext2_fs.h> |
15 | #include <linux/romfs_fs.h> | 15 | #include <linux/romfs_fs.h> |
16 | #include <linux/cramfs_fs.h> | 16 | #include <uapi/linux/cramfs_fs.h> |
17 | #include <linux/initrd.h> | 17 | #include <linux/initrd.h> |
18 | #include <linux/string.h> | 18 | #include <linux/string.h> |
19 | #include <linux/slab.h> | 19 | #include <linux/slab.h> |