[U-Boot] uboot env in mmc partition
Naitik Amin
Naitik.Amin at ametek.com
Wed Sep 3 18:03:12 CEST 2014
Hi Sachin,
My paritions are not laid out in the same order of 1-4 in memory. The
address that computed came from below
[root at IM mmcblk0p4]# ls
alignment_offset holders ro stat
dev inflight size subsystem
discard_alignment partition start uevent
[root at IM mmcblk0p4]# cat start
1099776
1099776 * 512 = 0x21900000
From: Sachin Verma <simplysachin at gmail.com>
To: Naitik Amin <Naitik.Amin at ametek.com>,
Cc: "Peter A. Bigot" <pab at pabigot.com>, u-boot at lists.denx.de, Hannes
Petermaier <Hannes.Petermaier at br-automation.com>
Date: 09/03/2014 11:54 AM
Subject: Re: [U-Boot] uboot env in mmc partition
Hi Naitik,
On Wed, Sep 3, 2014 at 8:08 PM, Naitik Amin <Naitik.Amin at ametek.com>
wrote:
Below is the layout of my partitions.
[root at IM /root]# cat /proc/partitions
major minor #blocks name
179 0 3887104 mmcblk0
179 1 20480 mmcblk0p1
179 2 512000 mmcblk0p2
179 3 1024 mmcblk0p3
179 4 64 mmcblk0p4
Further explanation
Partition 1: Partition type: 0xB Fat32 (Holds zImage, dtb, rbf, uboot
startup script)
Partition 2: Partititon type: 0x83 ext3 (Holds rootfs)
Partition 3: Partition type: A2 (raw) MBR looks for preloader at the
beginning of the A2 partition. (Holds Preloader, followed by uboot)
Partition 4: Partition type: A3 (raw) To hold the uboot-env (Newly
created)
According to your partition layout, your environment offset must be :
(3887104 + 20480 + 512000 + 1024) = 4420608 blocks into the user partition
of eMMC.
So, the offset should be 4420608 * 512 = 2263351296 = 0x86E80000
The offset (0x21900000) you are using seems to be in your very first
partition i.e. mmcblk0 and hence it is corrupting your dtb and other
files.
Best Regards,
Sachin Verma.
More information about the U-Boot
mailing list