diff options
author | Alessio Igor Bogani <alessio.bogani@elettra.eu> | 2016-12-07 15:00:57 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-12-13 22:55:19 +0000 |
commit | 8c1c43b7901a9fcd8b279eb4250b08157ad345b7 (patch) | |
tree | fef0c7588edd9c43ac44fb7847f514a224d5c812 /scripts/lib | |
parent | 839d9aaafdb93db159251774a0fefe8d756fd8ce (diff) | |
download | poky-8c1c43b7901a9fcd8b279eb4250b08157ad345b7.tar.gz |
wic: Create a logical partition only when it is really mandatory
Don't worth bother with logical partition on MBR partition type (aka
msdos) if disk image generated by wic should have 4 partitions.
(From OE-Core rev: 36a558fbdc96094626e7de1a3510691e30885368)
Signed-off-by: Alessio Igor Bogani <alessio.bogani@elettra.eu>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib')
-rw-r--r-- | scripts/lib/wic/utils/partitionedfs.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/scripts/lib/wic/utils/partitionedfs.py b/scripts/lib/wic/utils/partitionedfs.py index 9e76487844..9ea4a30cbb 100644 --- a/scripts/lib/wic/utils/partitionedfs.py +++ b/scripts/lib/wic/utils/partitionedfs.py | |||
@@ -201,9 +201,10 @@ class Image(): | |||
201 | part['num'] = 0 | 201 | part['num'] = 0 |
202 | 202 | ||
203 | if disk['ptable_format'] == "msdos": | 203 | if disk['ptable_format'] == "msdos": |
204 | if disk['realpart'] > 3: | 204 | if len(self.partitions) > 4: |
205 | part['type'] = 'logical' | 205 | if disk['realpart'] > 3: |
206 | part['num'] = disk['realpart'] + 1 | 206 | part['type'] = 'logical' |
207 | part['num'] = disk['realpart'] + 1 | ||
207 | 208 | ||
208 | disk['partitions'].append(num) | 209 | disk['partitions'].append(num) |
209 | msger.debug("Assigned %s to %s%d, sectors range %d-%d size %d " | 210 | msger.debug("Assigned %s to %s%d, sectors range %d-%d size %d " |