summaryrefslogtreecommitdiff
path: root/moduleconfig.h
diff options
context:
space:
mode:
authormarty <marty>2005-09-18 05:31:26 +0000
committermarty <marty>2005-09-18 05:31:26 +0000
commit3fb421aeda96d281918eeae5f4ac46eb685cc4d0 (patch)
treee92a5416cffc45724f988ff74ebdf0d37f6a4ddd /moduleconfig.h
parent102ee9ef7f61177ab100570809d9dbde888e3904 (diff)
Modified Makefile to allow 'out of kernel tree' module building for 2.6.x
kernels. (See Documentation/kbuild for details on how to do this). Modified yportenv.h to include moduleconfig.h Added new file moduleconfig.h. This is the compromise that makes it possible to build yaffs in any of three ways: 1) in-kernel, in the kernel source tree. You put yaffs into the kernel source tree using patch-ker.sh 2) as-module, in the kernel source tree. 3) as-module, out of the kernel source tree. Because modules built outside of the kernel source tree can't use the kconfig tool to add their CONFIG_ variable to <linux/config.h>, moduleconfig.h is a compromise that gathers all of the CONFIG_ variables in one place. The CONFIG_ variables in moduleconfig.h are protected by KBUILD_MODNAME, a variable that is only set when a module is built outside of the kernel source tree. The CONFIG_ variables are all on by default -- this is probably not what you want. Comment out the ones that you don't want enabled. NOTE: Not all of the CONFIG_ variables used in yaffs2 are in moduleconfig.h. Those that are not relevant to Linux are missing.
Diffstat (limited to 'moduleconfig.h')
-rw-r--r--moduleconfig.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/moduleconfig.h b/moduleconfig.h
new file mode 100644
index 0000000..a8684c3
--- /dev/null
+++ b/moduleconfig.h
@@ -0,0 +1,14 @@
+#ifndef __YAFFS_CONFIG_H__
+#define __YAFFS_CONFIG_H__
+
+#ifdef KBUILD_MODNAME
+#define CONFIG_YAFFS_FS
+#define CONFIG_YAFFS_YAFFS1
+#define CONFIG_YAFFS_YAFFS2
+#define CONFIG_YAFFS_DOES_ECC
+#define CONFIG_YAFFS_ECC_WRONG_ORDER
+#define CONFIG_YAFFS_DISABLE_CHUNK_ERASED_CHECK
+#define CONFIG_YAFFS_SHORT_NAMES_IN_RAM
+#endif /* KBUILD_MODNAME */
+
+#endif /* __YAFFS_CONFIG_H__ */