diff options
author | Koen Kooi <koen@dominion.thruhere.net> | 2011-10-15 13:48:24 +0200 |
---|---|---|
committer | Koen Kooi <koen@dominion.thruhere.net> | 2011-10-15 13:48:24 +0200 |
commit | 99ce37e4a9c1cbfe534528584c67577d07c825ae (patch) | |
tree | fd4d936e9c2f1e9a9ffafec418e3a1f3850b15c0 /classes | |
parent | 554db22c5bfdefaa54f3923a7ffbe72092bd0d91 (diff) | |
download | meta-ti-99ce37e4a9c1cbfe534528584c67577d07c825ae.tar.gz |
sdcard_image bbclass: default to 4GiB, but use 2GiB for beaglebone
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Diffstat (limited to 'classes')
-rw-r--r-- | classes/sdcard_image.bbclass | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/classes/sdcard_image.bbclass b/classes/sdcard_image.bbclass index be7ab3b9..41891fe5 100644 --- a/classes/sdcard_image.bbclass +++ b/classes/sdcard_image.bbclass | |||
@@ -12,6 +12,10 @@ LOOPDEV ?= "/dev/loop1" | |||
12 | LOOPDEV_BOOT ?= "/dev/loop2" | 12 | LOOPDEV_BOOT ?= "/dev/loop2" |
13 | LOOPDEV_FS ?= "/dev/loop3" | 13 | LOOPDEV_FS ?= "/dev/loop3" |
14 | 14 | ||
15 | # Default to 4GiB images, but use 2GiB images for beaglebone | ||
16 | SDIMG_SIZE ?= "444" | ||
17 | SDIMG_SIZE_beaglebone = "222" | ||
18 | |||
15 | IMAGE_CMD_sdimg () { | 19 | IMAGE_CMD_sdimg () { |
16 | SDIMG=${WORKDIR}/sd.img | 20 | SDIMG=${WORKDIR}/sd.img |
17 | 21 | ||
@@ -29,7 +33,7 @@ IMAGE_CMD_sdimg () { | |||
29 | 33 | ||
30 | # If an SD image is already present, reuse and reformat it | 34 | # If an SD image is already present, reuse and reformat it |
31 | if [ ! -e ${SDIMG} ] ; then | 35 | if [ ! -e ${SDIMG} ] ; then |
32 | dd if=/dev/zero of=${SDIMG} bs=$(echo '255 * 63 * 512' | bc) count=222 | 36 | dd if=/dev/zero of=${SDIMG} bs=$(echo '255 * 63 * 512' | bc) count=${SDIMG_SIZE} |
33 | fi | 37 | fi |
34 | 38 | ||
35 | ${LOSETUP} ${LOOPDEV} ${SDIMG} | 39 | ${LOSETUP} ${LOOPDEV} ${SDIMG} |