summaryrefslogtreecommitdiff
path: root/package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch
diff options
context:
space:
mode:
Diffstat (limited to 'package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch')
-rw-r--r--package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch b/package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch
new file mode 100644
index 0000000000..f854662a07
--- /dev/null
+++ b/package/kernel/lantiq/ltq-ptm/patches/101-fix-more-compilation-warning-debugfs.patch
@@ -0,0 +1,38 @@
+--- a/ifxmips_ptm_adsl.c
++++ b/ifxmips_ptm_adsl.c
+@@ -180,7 +180,7 @@ static int proc_read_version(char *, char **, off_t, int, int *, void *);
+ static int proc_read_wanmib(char *, char **, off_t, int, int *, void *);
+ static int proc_write_wanmib(struct file *, const char *, unsigned long, void *);
+ #endif
+-#if defined(ENABLE_FW_PROC) && ENABLE_FW_PROC
++#if defined(ENABLE_FW_PROC) && ENABLE_FW_PROC && defined(ENABLE_DBG_PROC) && ENABLE_DBG_PROC
+ static int proc_read_genconf(char *, char **, off_t, int, int *, void *);
+ #endif
+ #if defined(ENABLE_DBG_PROC) && ENABLE_DBG_PROC
+@@ -191,8 +191,8 @@ static int proc_write_wanmib(struct file *, const char *, unsigned long, void *)
+ /*
+ * Proc Help Functions
+ */
+-static INLINE int stricmp(const char *, const char *);
+ #if defined(ENABLE_DBG_PROC) && ENABLE_DBG_PROC
++ static INLINE int stricmp(const char *, const char *);
+ static INLINE int strincmp(const char *, const char *, int);
+ #endif
+ static INLINE int ifx_ptm_version(char *);
+@@ -1159,8 +1159,6 @@ static int proc_write_dbg(struct file *file, const char *buf, unsigned long coun
+ return count;
+ }
+
+-#endif // defined(ENABLE_DBG_PROC) && ENABLE_DBG_PROC
+-
+ static INLINE int stricmp(const char *p1, const char *p2)
+ {
+ int c1, c2;
+@@ -1178,7 +1176,6 @@ static INLINE int stricmp(const char *p1, const char *p2)
+ return *p1 - *p2;
+ }
+
+-#if defined(ENABLE_DBG_PROC) && ENABLE_DBG_PROC
+ static INLINE int strincmp(const char *p1, const char *p2, int n)
+ {
+ int c1 = 0, c2;