zoukankan      html  css  js  c++  java
  • 制作yaffs2文件系统

    由于内核里没有yaffs2文件系统生成功能,所以需要添加补丁。
     
    1. fsMakefile.path in fs_yaffs2.tgz is the patch for kernel/fs/Makefile
     
    在 kernel/fs/Makefile中添加如下内容
    [root@localhost fs_yaffs2]# cat fsMakefile.path
    --- fs/Makefile.orig    2010-01-22 11:43:38.000000000 +0800
    +++ fs/Makefile 2010-01-22 11:44:22.000000000 +0800
    @@ -120,3 +120,5 @@
     obj-$(CONFIG_DEBUG_FS)         += debugfs/
     obj-$(CONFIG_OCFS2_FS)         += ocfs2/
     obj-$(CONFIG_GFS2_FS)           += gfs2/
    +# Patched by YAFFS
    +obj-$(CONFIG_YAFFS_FS)               += yaffs2/
    [root@localhost fs_yaffs2]#
     
    2. Kconfig.patch in fs_yaffs2.tgz is the patch for kernel/fs/Kconfig
    在 kernel/fs/Kconfig中,添加如下内容
    [root@localhost fs_yaffs2]# cat Kconfig.patch
    --- Kconfig.pre.yaffs   2010-01-21 12:41:45.000000000 +0800
    +++ Kconfig     2010-01-21 12:41:37.000000000 +0800
    @@ -1182,6 +1182,10 @@
              To compile the EFS file system support as a module, choose M here: the
              module will be called efs.
     
    +
    +# Patched by YAFFS
    +source "fs/yaffs2/Kconfig"
    +
     config JFFS2_FS
            tristate "Journalling Flash File System v2 (JFFS2) support"
            select CRC32
    [root@localhost fs_yaffs2]#
     
    最后后拷贝 yaffs2/ 到 /kerenl/fs/ 中。
     
    3. stlinux23-host-yaffs-utils-1.0.0-3.i386.rpm is to install  /opt/STM/STLinux-
    2.3/host/bin/mkyaffs2image to create yaffs2 fs image.
     
    制作文件系统工具
    [root@localhost fs_yaffs2]# rpm -ivh stlinux23-host-yaffs-utils-1.0.0-3.i386.rpm --nodeps --force
    这样就可以用mkyaffs2image 来制作yaffs2文件系统了~

    4. use apply_yaffs2nand-app.sh
     
    [root@localhost hanbang--mini+fs+for+ramdisk&jffs2&yaffs2]# cat apply_yaffs2nand-app.sh
    echo "rm ./yaffs2fs-app.yaffs2"
    rm /opt/STM/STLinux-2.3/devkit/sh4/yaffs2fs-app.yaffs2
    /opt/STM/STLinux-2.3/host/bin/mkyaffs2image 1 /opt/STM/STLinux-2.3/devkit/sh4/target
    /opt/STM/STLinux-2.3/devkit/sh4/yaffs2fs-app.yaffs2
    echo "done !!!"
    [root@localhost hanbang--mini+fs+for+ramdisk&jffs2&yaffs2]#
     
    5. 制作文件系统:source ./apply_yaffs2nand-app.sh

  • 相关阅读:
    Ubuntu里Eclipse关联Jdk
    解决Ubuntu自带编译器不好使问题
    Ubuntu英文变为中文
    两个VirtualBox版本装的语言不一样?
    Hadoop-2.0 目录简介
    Eclipse项目里面看源码和文档
    Eclipse搭建Struts2环境
    2017,崭新的一年!
    cl-closure-template 中文乱码的解决方法
    common-list基础知识--多值的返回与接收
  • 原文地址:https://www.cnblogs.com/hehehaha/p/6332973.html
Copyright © 2011-2022 走看看