diff mbox

yaffs2 file system

Message ID 534CF34C.4050808@carallon.com
State Accepted
Headers show

Commit Message

Will Wagner April 15, 2014, 8:52 a.m. UTC
On 15/04/2014 09:32, Rohit Kumar wrote:
> Hello,
>
> i want to create yaffs2 file system with buildroot.
> i see that buildroot doesnt have this option. so i have created standard
> uncompressed image.
> is there a way to convert it to yaffs2 FS?
> any help is appreciated.

Hi Rohit,

I have a couple of patches (attached) that add yaffs2 support for 
buildroot, that I have never got round to pushing upstream. They are 
based on buildroot_2013.05.

Regards
Will

Comments

Thomas Petazzoni April 20, 2014, 4:15 p.m. UTC | #1
Dear Will Wagner,

On Tue, 15 Apr 2014 09:52:28 +0100, Will Wagner wrote:

> I have a couple of patches (attached) that add yaffs2 support for 
> buildroot, that I have never got round to pushing upstream. They are 
> based on buildroot_2013.05.

I've taken your two patches, made a little bit of clean up, and I
applied them.

Thanks!

Thomas
Rohit Kumar April 25, 2014, 12:35 a.m. UTC | #2
Hello Thomas,



On Mon, Apr 21, 2014 at 1:15 AM, Thomas Petazzoni <
thomas.petazzoni@free-electrons.com> wrote:

> Dear Will Wagner,
>
> On Tue, 15 Apr 2014 09:52:28 +0100, Will Wagner wrote:
>
> > I have a couple of patches (attached) that add yaffs2 support for
> > buildroot, that I have never got round to pushing upstream. They are
> > based on buildroot_2013.05.
>
> I've taken your two patches, made a little bit of clean up, and I
> applied them.
>
>
so how do we use it?


> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
>


With Regards,

Rohit Kumar
+82 1073149173
Thomas Petazzoni April 25, 2014, 7 a.m. UTC | #3
Dear Rohit Kumar,

On Fri, 25 Apr 2014 09:35:21 +0900, Rohit Kumar wrote:

> > I've taken your two patches, made a little bit of clean up, and I
> > applied them.
> >
> so how do we use it?

Well, pull the latest Buildroot, and in the "Filesystem images" menu,
you'll have a yaffs2 option. Simply enable it, and Buildroot will
generate a yaffs2 image of the root filesystem.

Best regards,

Thomas
diff mbox

Patch

diff --git a/fs/Config.in b/fs/Config.in
index da4c5ff..89b1298 100644
--- a/fs/Config.in
+++ b/fs/Config.in
@@ -11,5 +11,6 @@  source "fs/romfs/Config.in"
 source "fs/squashfs/Config.in"
 source "fs/tar/Config.in"
 source "fs/ubifs/Config.in"
+source "fs/yaffs/Config.in"
 
 endmenu
diff --git a/fs/yaffs/Config.in b/fs/yaffs/Config.in
new file mode 100644
index 0000000..e9d4f93
--- /dev/null
+++ b/fs/yaffs/Config.in
@@ -0,0 +1,12 @@ 
+config BR2_TARGET_ROOTFS_YAFFS
+	bool "yaffs root filesystem"
+	help
+	  Build a yaffs root filesystem
+
+config BR2_TARGET_ROOTFS_YAFFS_PATH
+	string "path within target to create fs from"
+	depends on BR2_TARGET_ROOTFS_YAFFS
+	default ""
+	help
+	  If you want to create the yaffs image from only
+	  part of the target directory, specify the path here
\ No newline at end of file
diff --git a/fs/yaffs/yaffs.mk b/fs/yaffs/yaffs.mk
new file mode 100644
index 0000000..7aad26f
--- /dev/null
+++ b/fs/yaffs/yaffs.mk
@@ -0,0 +1,19 @@ 
+#############################################################
+#
+# Build the yaffs root filesystem image
+#
+#############################################################
+
+ifneq ($(BR2_TARGET_ROOTFS_YAFFS_PATH),"")
+ROOTFS_YAFFS_TARGET=$(TARGET_DIR)/$(BR2_TARGET_ROOTFS_YAFFS_PATH)
+else
+ROOTFS_YAFFS_TARGET=$(TARGET_DIR)
+endif
+
+define ROOTFS_YAFFS_CMD
+ $(HOST_DIR)/usr/bin/mkyaffs2 --all-root $(ROOTFS_YAFFS_TARGET) $@
+endef
+
+ROOTFS_YAFFS_DEPENDENCIES = host-yaffs2utils
+
+$(eval $(call ROOTFS_TARGET,yaffs))