diff options
author | Daniel Schultz <d.schultz@phytec.de> | 2017-06-09 16:07:35 +0200 |
---|---|---|
committer | Stefan Müller-Klieser <s.mueller-klieser@phytec.de> | 2017-06-21 15:22:07 +0200 |
commit | b5303dfdcee11d132448b4c716a57dc01c172c96 (patch) | |
tree | fabf3bfe0263aa0fd67e69bbb84448fe929540bc /classes/wic-am335x-helper.bbclass | |
parent | 3d03935b348957f753db71f3ae4a6714ca655321 (diff) | |
download | meta-phytec-b5303dfdcee11d132448b4c716a57dc01c172c96.tar.bz2 meta-phytec-b5303dfdcee11d132448b4c716a57dc01c172c96.zip |
classes: wic-helper: updates
Changes:
- description
- change python rename function to bash append
- Add EMMC creator:
This function creates an EMMC image and writes the MLO at 0x0, 0x20000,
0x40000 and 0x60000 to support RAW boot for AM335x SoCs.
Signed-off-by: Daniel Schultz <d.schultz@phytec.de>
Signed-off-by: Stefan Müller-Klieser <s.mueller-klieser@phytec.de>
Diffstat (limited to 'classes/wic-am335x-helper.bbclass')
-rw-r--r-- | classes/wic-am335x-helper.bbclass | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/classes/wic-am335x-helper.bbclass b/classes/wic-am335x-helper.bbclass new file mode 100644 index 0000000..1fd48a1 --- /dev/null +++ b/classes/wic-am335x-helper.bbclass @@ -0,0 +1,11 @@ +IMAGE_CMD_emmc_append () { + if [ -e ${EMMCIMG} ]; then + # copy the MLO to address 0x0 and keep the partition table + dd if=${DEPLOY_DIR_IMAGE}/${BAREBOX_IPL_BIN_SYMLINK} of=${EMMCIMG} bs=446 count=1 conv=notrunc + dd if=${DEPLOY_DIR_IMAGE}/${BAREBOX_IPL_BIN_SYMLINK} of=${EMMCIMG} skip=1 seek=1 conv=notrunc + # copy the MLO to address 0x20000, 0x40000, 0x60000 + dd if=${DEPLOY_DIR_IMAGE}/${BAREBOX_IPL_BIN_SYMLINK} of=${EMMCIMG} seek=768 bs=512 conv=notrunc + dd if=${DEPLOY_DIR_IMAGE}/${BAREBOX_IPL_BIN_SYMLINK} of=${EMMCIMG} seek=512 bs=512 conv=notrunc + dd if=${DEPLOY_DIR_IMAGE}/${BAREBOX_IPL_BIN_SYMLINK} of=${EMMCIMG} seek=256 bs=512 conv=notrunc + fi +} |