[meta-xilinx] [PATCH 04/19] Add xilinx-fitimage recipe
Alistair Francis
alistair23 at gmail.com
Wed May 4 14:19:29 PDT 2016
On Fri, Apr 29, 2016 at 6:19 PM, Jason Wu <jason.wu.misc at gmail.com> wrote:
>
>
> On 30/04/2016 7:22 AM, Alistair Francis wrote:
>>
>> On Thu, Apr 28, 2016 at 4:57 PM, Jason Wu <jason.wu.misc at gmail.com> wrote:
>>>
>>>
>>>
>>> On 29/04/2016 3:32 AM, Alistair Francis wrote:
>>>>
>>>>
>>>> On Wed, Apr 27, 2016 at 12:45 AM, Jason Wu <jason.wu.misc at gmail.com>
>>>> wrote:
>>>>>
>>>>>
>>>>> this recipe creates a fitimage (fit.itb) that contents:
>>>>> - 1 kernel
>>>>> - 1 rootfs
>>>>> - 1 dtb
>>>>> - 2 configs
>>>>> config at 1: kernel + rootfs + dtb
>>>>> config at 2: kernel + dtb
>>>>>
>>>>> The ITS is generated by mkits.sh where it supports:
>>>>> - multi-configuration (upto 10 with -c option). First -c used defines
>>>>> the default conf used.
>>>>> - multi-image support - multiple kernel/fdt/ramdsik image (upto 50
>>>>> images)
>>>>> - per image configuration: Tools now reuse the option for each images
>>>>> - hash algorithm and generated required subnodes
>>>>> - compression
>>>>> - signature and generated required subnodes (not tested)
>>>>>
>>>>> mkits.sh allows user to generate a simple its that only has one
>>>>> configuration
>>>>> that only boot with 1 kernel + 1 fdt to 4 different boot configuration
>>>>> with different image combination. For an example:
>>>>> creating a its with 2 kernel, 1 dtb, 2 rootfs images and has the
>>>>> following
>>>>> configurations:
>>>>> 1: kernel0 + dtb0 + rootfs0 (default boot configuration)
>>>>> 2. kernel0 + dtb0 + rootfs1
>>>>> 3. kernel1 + dtb0 + rootfs0
>>>>> 4. kernel1 + dtb0 + rootfs1
>>>>> 5. kernel0 + dtb1
>>>>> where kernel1 and rootfs0 is gzip compressed.
>>>>>
>>>>> The command to generate the its is shown as follows:
>>>>> $ ./mkits.sh -A arm -v 4.4 -k kernel0 -C none -c 1 -c 2 -c5 \
>>>>> -k kernel1 -C gzip -c 3 -c 4 -h crc32 \
>>>>> -d dtb0 -c 1 -c 2 -c 3 -c 4 -h sha1 -h crc32\
>>>>> -d dtb1 -c 5 -h sha1 \
>>>>> -r rootfs0 -C gzip -c 1 -c 2 \
>>>>> -r rootfs1 -C none -c3 -c4
>>>>>
>>>>> First -c option used defines the default boot configuration.
>>>>>
>>>>> The key benefit is to have more flexible ITS generation. A typical
>>>>> example,
>>>>> is to create a fitImage with 1 kernel with multiple dtb to provide
>>>>> different
>>>>> features. E.g. system boot with ramdisk or sdroot or nfsroot and etc.
>>>>>
>>>>> Signed-off-by: Jason Wu <jason.wu.misc at gmail.com>
>>>>
>>>>
>>>>
>>>> Hey Jason,
>>>>
>>>> I couldn't figure out how to select which configuration option to use.
>>>
>>>
>>> by default the first -c option used defines the default option to use.
>>>
>>> e.g. ./mkits.sh -A arm -v 4.4 -k kernel0 -C none -c 1 -c 2 -c 5 , uses
>>> configuration option 1 as default option. If you want option 5 as
>>> default,
>>> ./mkits.sh -A arm -v 4.4 -k kernel0 -C none -c 5 -c 1 -c 2 will set the
>>> default configuration option to conf at 5.
>>>
>>> hope this answer you questions.
>>
>>
>> Hey Jason,
>>
>> Ok, so there is no dynamic way to change the configuration then? The
>> user will need to manually edit the command line arguments
>
> You can always change the boot config option at run time. After you load the
> fitimage to ${load_addr}.
> uboot> bootm ${load_addr}#conf at 5
> with this command, you will able to boot with conf at 5.
Aw ok, That makes sense.
Thanks for explaining that Jason.
Alistair
More information about the meta-xilinx
mailing list