<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>i.MX Processors中的主题 How to load an initramfs image using u-boot (i.MX28) ?</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/How-to-load-an-initramfs-image-using-u-boot-i-MX28/m-p/159620#M3016</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello !&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I have tried to load my kernel and a custom initramfs without success. For this purpose, I formatted a SD card like below:&lt;BR /&gt;&lt;BR /&gt;* Partition 1 (FAT16): u-boot parameters&lt;BR /&gt;* Partition 2 (Sigmatel): u-boot image, prepared to be loaded by i.MX28 ROM&lt;BR /&gt;* Partition 3 (FAT16): kernel and initramfs files&lt;BR /&gt;* Partition 4 (ext3): rootfs&lt;BR /&gt;&lt;BR /&gt;Using fatload, I loaded kernel to position 0x42000000 and initramfs to position 0x42300000 (kernel fits in 3MB). I used the kernel parameters related to ramfs:&lt;BR /&gt;&lt;BR /&gt;root=/dev/ram0 rootfstype=ramfs initrd=0x42300000&lt;BR /&gt;&lt;BR /&gt;However, after mounting the rootfs, kernel can not execute init. I have specified init as well, using initrd=/bin/ash or init=/bin/ash, just to test, no donuts for me in both cases.&lt;BR /&gt;&lt;BR /&gt;Tired of this approach, I thought about the strategy of inserting initramfs inside kernel. I configured the kernel and provided such cpio image. The kernel size becomes bigger, as expected. However, when loading this kernel using fatload, I receive a bad CRC message and kernel can not be loaded.&lt;BR /&gt;&lt;BR /&gt;I saw that ltib can generate two ramfs images: a standard cpio image or a u-boot (?) cpio image. I have used the first one since the second has a kind o header.&lt;BR /&gt;&lt;BR /&gt;Anyone out there have booted the system using u-boot, kernel and and initramfs to help me ? The idea is to have a safe boot environment based on ramfs, only mounting the rootfs after checks and validations or fetching a new rootfs using ftp/tftp. Moreover, this way, it is possible to update the kernel, safe boot (ramfs) or rootfs file system in the field easily.&lt;BR /&gt;&lt;BR /&gt;Thanks in advance !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 30 Jun 2011 02:20:39 GMT</pubDate>
    <dc:creator>MarceloBarros</dc:creator>
    <dc:date>2011-06-30T02:20:39Z</dc:date>
    <item>
      <title>How to load an initramfs image using u-boot (i.MX28) ?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-load-an-initramfs-image-using-u-boot-i-MX28/m-p/159620#M3016</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello !&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I have tried to load my kernel and a custom initramfs without success. For this purpose, I formatted a SD card like below:&lt;BR /&gt;&lt;BR /&gt;* Partition 1 (FAT16): u-boot parameters&lt;BR /&gt;* Partition 2 (Sigmatel): u-boot image, prepared to be loaded by i.MX28 ROM&lt;BR /&gt;* Partition 3 (FAT16): kernel and initramfs files&lt;BR /&gt;* Partition 4 (ext3): rootfs&lt;BR /&gt;&lt;BR /&gt;Using fatload, I loaded kernel to position 0x42000000 and initramfs to position 0x42300000 (kernel fits in 3MB). I used the kernel parameters related to ramfs:&lt;BR /&gt;&lt;BR /&gt;root=/dev/ram0 rootfstype=ramfs initrd=0x42300000&lt;BR /&gt;&lt;BR /&gt;However, after mounting the rootfs, kernel can not execute init. I have specified init as well, using initrd=/bin/ash or init=/bin/ash, just to test, no donuts for me in both cases.&lt;BR /&gt;&lt;BR /&gt;Tired of this approach, I thought about the strategy of inserting initramfs inside kernel. I configured the kernel and provided such cpio image. The kernel size becomes bigger, as expected. However, when loading this kernel using fatload, I receive a bad CRC message and kernel can not be loaded.&lt;BR /&gt;&lt;BR /&gt;I saw that ltib can generate two ramfs images: a standard cpio image or a u-boot (?) cpio image. I have used the first one since the second has a kind o header.&lt;BR /&gt;&lt;BR /&gt;Anyone out there have booted the system using u-boot, kernel and and initramfs to help me ? The idea is to have a safe boot environment based on ramfs, only mounting the rootfs after checks and validations or fetching a new rootfs using ftp/tftp. Moreover, this way, it is possible to update the kernel, safe boot (ramfs) or rootfs file system in the field easily.&lt;BR /&gt;&lt;BR /&gt;Thanks in advance !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jun 2011 02:20:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-load-an-initramfs-image-using-u-boot-i-MX28/m-p/159620#M3016</guid>
      <dc:creator>MarceloBarros</dc:creator>
      <dc:date>2011-06-30T02:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to load an initramfs image using u-boot (i.MX28) ?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-load-an-initramfs-image-using-u-boot-i-MX28/m-p/159621#M3017</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you ever get this working?&amp;nbsp; I want to do the exact same thing on an imx28 and am having similar issues.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Bill&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2012 22:10:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-load-an-initramfs-image-using-u-boot-i-MX28/m-p/159621#M3017</guid>
      <dc:creator>blsousan</dc:creator>
      <dc:date>2012-09-13T22:10:47Z</dc:date>
    </item>
  </channel>
</rss>

