<?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のトピックRe: Assign fix boot device node at boot time</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Assign-fix-boot-device-node-at-boot-time/m-p/275164#M30484</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok. Here is the solution which I have implemented.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Uboot script is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;ls mmc 1 # eMMC is at device 0 and SD Card is at device&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;if test $? -eq 0; then # If sd card is inserted ls will list the partition contents otherwise it will report error.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo " === SD Card is inserted === " # When SD Card is inserted I know my eMMC will be at node /dev/mmcblk1p1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setenv bootargs root=/dev/mmcblk1p1 init=/sbin/mmcblk1 rootwait rw ip=off fixrtc console=ttymxc3,115200 vmalloc=192M imx2_wdt.nowayout=0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;else&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo " === SD Card is not inserted === " # When SD Card is not inserted I know my eMMC will be at node /dev/mmcblk0p1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setenv bootargs root=/dev/mmcblk0p1 init=/sbin/mmcblk0 rootwait rw ip=off fixrtc console=ttymxc3,115200 vmalloc=192M imx2_wdt.nowayout=0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;fi&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is working good for me. My question is, Is this solution good for a product grade embedded device or not ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Mar 2014 10:08:48 GMT</pubDate>
    <dc:creator>Farrukh</dc:creator>
    <dc:date>2014-03-05T10:08:48Z</dc:date>
    <item>
      <title>Assign fix boot device node at boot time</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Assign-fix-boot-device-node-at-boot-time/m-p/275163#M30483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Greetings All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a custom hardware based on SaberLite. I have following hardware on the board&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SD Card on SD3 &amp;lt;-- Device 0 in U-Boot&lt;/P&gt;&lt;P&gt;eMMC on SD4&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;-- Device 1 in U-Boot&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now ofcourse I always want to boot from eMMC which is on SD4. My kernel + root filesystem reside on eMMC. I can fix Device 1 in U-Boot and I can load my kernel always from eMMC but the problem comes when accessing root filesystem. My boot arguments are &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;root=/dev/mmcblk0p1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With this root device where I do not have any SD Card inserted (at boot time), I can get the good device pointing to rootfs. But when booting with SD Card inserted, /dev/mmcblk0p1 points to the SD Card first partition and /dev/mmcblk1p1 points to eMMC first partition, so that is not a good rootfs for the system hence the system is unable to boot when booted with SD Card inserted. My device users can not change the boot parameters, neither I can make sure my users does not boot the system with SD Card inserted and also that is not a good solution. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to fix the device node for the eMMC at the kernel boot time. Anyone can suggest how can I do it or is there any other solution to this problem&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Farrukh Arshad.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2014 06:57:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Assign-fix-boot-device-node-at-boot-time/m-p/275163#M30483</guid>
      <dc:creator>Farrukh</dc:creator>
      <dc:date>2014-03-05T06:57:27Z</dc:date>
    </item>
    <item>
      <title>Re: Assign fix boot device node at boot time</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Assign-fix-boot-device-node-at-boot-time/m-p/275164#M30484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ok. Here is the solution which I have implemented.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Uboot script is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;ls mmc 1 # eMMC is at device 0 and SD Card is at device&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;if test $? -eq 0; then # If sd card is inserted ls will list the partition contents otherwise it will report error.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo " === SD Card is inserted === " # When SD Card is inserted I know my eMMC will be at node /dev/mmcblk1p1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setenv bootargs root=/dev/mmcblk1p1 init=/sbin/mmcblk1 rootwait rw ip=off fixrtc console=ttymxc3,115200 vmalloc=192M imx2_wdt.nowayout=0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;else&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo " === SD Card is not inserted === " # When SD Card is not inserted I know my eMMC will be at node /dev/mmcblk0p1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; setenv bootargs root=/dev/mmcblk0p1 init=/sbin/mmcblk0 rootwait rw ip=off fixrtc console=ttymxc3,115200 vmalloc=192M imx2_wdt.nowayout=0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;fi&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is working good for me. My question is, Is this solution good for a product grade embedded device or not ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Mar 2014 10:08:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Assign-fix-boot-device-node-at-boot-time/m-p/275164#M30484</guid>
      <dc:creator>Farrukh</dc:creator>
      <dc:date>2014-03-05T10:08:48Z</dc:date>
    </item>
  </channel>
</rss>

