summaryrefslogtreecommitdiffstats
path: root/scripts/lib/wic/kickstart
diff options
context:
space:
mode:
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>2015-02-08 23:52:00 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-02-14 08:40:58 +0000
commit0b156dac83258a2789f21038216e43aacc91555a (patch)
tree3d814ee83abb20173b099e2f8dd9c83365d45d94 /scripts/lib/wic/kickstart
parentf923f0fde8af63c6ba7c232d1f25dd970d9e22e1 (diff)
downloadpoky-0b156dac83258a2789f21038216e43aacc91555a.tar.gz
wic: allow creation of partitions not in table
For some architectures it is necessary to reserve space on disk without it being present in the partition table. For example, u-boot on i.mx is placed at an offset of 1kB on the sdcard. While it would be possible to create a partition at that offset and place u-boot there, it would then be necessary to update the default u-boot environment to use partition 2 on the mmc instead of partition 1. (From OE-Core rev: 233b631ece5ee14d057932c146327065064b5196) Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/wic/kickstart')
-rw-r--r--scripts/lib/wic/kickstart/custom_commands/partition.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/lib/wic/kickstart/custom_commands/partition.py b/scripts/lib/wic/kickstart/custom_commands/partition.py
index 7a307065f2..9be6b0457b 100644
--- a/scripts/lib/wic/kickstart/custom_commands/partition.py
+++ b/scripts/lib/wic/kickstart/custom_commands/partition.py
@@ -49,6 +49,7 @@ class Wic_PartData(Mic_PartData):
49 self.source = kwargs.get("source", None) 49 self.source = kwargs.get("source", None)
50 self.sourceparams = kwargs.get("sourceparams", None) 50 self.sourceparams = kwargs.get("sourceparams", None)
51 self.rootfs = kwargs.get("rootfs-dir", None) 51 self.rootfs = kwargs.get("rootfs-dir", None)
52 self.no_table = kwargs.get("no-table", False)
52 self.source_file = "" 53 self.source_file = ""
53 self.size = 0 54 self.size = 0
54 55
@@ -61,6 +62,8 @@ class Wic_PartData(Mic_PartData):
61 retval += " --sourceparams=%s" % self.sourceparams 62 retval += " --sourceparams=%s" % self.sourceparams
62 if self.rootfs: 63 if self.rootfs:
63 retval += " --rootfs-dir=%s" % self.rootfs 64 retval += " --rootfs-dir=%s" % self.rootfs
65 if self.no_table:
66 retval += " --no-table"
64 67
65 return retval 68 return retval
66 69
@@ -521,4 +524,7 @@ class Wic_Partition(Mic_Partition):
521 # use specified rootfs path to fill the partition 524 # use specified rootfs path to fill the partition
522 op.add_option("--rootfs-dir", type="string", action="store", 525 op.add_option("--rootfs-dir", type="string", action="store",
523 dest="rootfs", default=None) 526 dest="rootfs", default=None)
527 # wether to add the partition in the partition table
528 op.add_option("--no-table", dest="no_table", action="store_true",
529 default=False)
524 return op 530 return op