imagebuilder: x86 fails to build inside the imagebuilder
[openwrt.git] / target / linux / generic / patches-3.12 / 502-yaffs-3.10-disable-proc-entry.patch
1 --- a/fs/yaffs2/yaffs_vfs.c
2 +++ b/fs/yaffs2/yaffs_vfs.c
3 @@ -3025,6 +3025,7 @@ static DECLARE_FSTYPE(yaffs2_fs_type, "y
4  #endif
5  
6  
7 +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 9, 0))
8  static struct proc_dir_entry *my_proc_entry;
9  
10  static char *yaffs_dump_dev_part0(char *buf, struct yaffs_dev *dev)
11 @@ -3398,6 +3399,7 @@ static int yaffs_proc_write(struct file
12                 return yaffs_proc_debug_write(file, buf, count, data);
13         return yaffs_proc_write_trace_options(file, buf, count, data);
14  }
15 +#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(3, 9, 0)) */
16  
17  /* Stuff to handle installation of file systems */
18  struct file_system_to_install {
19 @@ -3421,6 +3423,7 @@ static int __init init_yaffs_fs(void)
20  
21         mutex_init(&yaffs_context_lock);
22  
23 +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 9, 0))
24         /* Install the proc_fs entries */
25         my_proc_entry = create_proc_entry("yaffs",
26                                           S_IRUGO | S_IFREG, YPROC_ROOT);
27 @@ -3432,6 +3435,7 @@ static int __init init_yaffs_fs(void)
28         } else {
29                 return -ENOMEM;
30          }
31 +#endif
32  
33         /* Now add the file system entries */
34  
35 @@ -3468,7 +3472,9 @@ static void __exit exit_yaffs_fs(void)
36         yaffs_trace(YAFFS_TRACE_ALWAYS,
37                 "yaffs built " __DATE__ " " __TIME__ " removing.");
38  
39 +#if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 9, 0))
40         remove_proc_entry("yaffs", YPROC_ROOT);
41 +#endif
42  
43         fsinst = fs_to_install;
44