x86: preserve partition table on sysupgrade
authorJo-Philipp Wich <jow@openwrt.org>
Tue, 9 Feb 2016 12:33:17 +0000 (12:33 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Tue, 9 Feb 2016 12:33:17 +0000 (12:33 +0000)
commit532f27987d113c45046fd3ee44e6cb22271e8107
tree086ba162d0005151dbf3c4ce56d5ac1fa546035f
parent787726d51ce30defc6afcd804234cf5dc3d991e4
x86: preserve partition table on sysupgrade

With this patch sysupgrade will write directly to the partitions
instead of to the main disk.  The UUID is copied from the image
to the MBR as well.  This prevents the mbr from being completely
overwritten and losing the partition table.  The -p option has
been added to maintain the original behavior and overwite the
entire disk with the new image.  Tests have been added to ensure
that the image partitions match up with the active partitions.

Signed-off-by: Rob Mosher <nyt-openwrt@countercultured.net>
SVN-Revision: 48682
package/base-files/files/lib/upgrade/common.sh
package/base-files/files/sbin/sysupgrade
target/linux/x86/Makefile
target/linux/x86/base-files/lib/upgrade/platform.sh