1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
--- root.c.old 2011-12-12 20:07:18.000000000 +0800
+++ root.c 2011-12-12 20:10:38.000000000 +0800
@@ -597,7 +597,10 @@
#ifdef OLD_KERNEL
static DECLARE_FSTYPE_DEV(cdfs_fs_type, FSNAME, cdfs_mount);
#else
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,18)
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)
+static int cdfs_get_sb(struct file_system_type *fs_type, int flags, const char *dev_name, void *data, struct vfsmount *mnt) {
+ return mount_bdev(fs_type, flags, dev_name, data, cdfs_fill_super);
+#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,18)
static int cdfs_get_sb(struct file_system_type *fs_type, int flags, const char *dev_name, void *data, struct vfsmount *mnt) {
return get_sb_bdev(fs_type, flags, dev_name, data, cdfs_fill_super, mnt);
#else
@@ -609,7 +612,11 @@
static struct file_system_type cdfs_fs_type = {
.owner = THIS_MODULE,
.name = "cdfs",
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)
+ .mount = cdfs_get_sb,
+#else
.get_sb = cdfs_get_sb,
+#endif
.kill_sb = kill_block_super,
.fs_flags = FS_REQUIRES_DEV
};
|