summaryrefslogtreecommitdiff
path: root/cgpt/cgpt_boot.c
diff options
context:
space:
mode:
Diffstat (limited to 'cgpt/cgpt_boot.c')
-rw-r--r--cgpt/cgpt_boot.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/cgpt/cgpt_boot.c b/cgpt/cgpt_boot.c
index 386c4f4d..993e8654 100644
--- a/cgpt/cgpt_boot.c
+++ b/cgpt/cgpt_boot.c
@@ -78,6 +78,15 @@ int CgptBoot(CgptBootParams *params) {
return CGPT_FAILED;
}
+ if (drive.is_mtd) {
+ /* This command manipulates the legacy MBR sector present at the beginning
+ * of the GPT structures, and so doesn't apply to MTD drives.
+ */
+ Error("'boot' command unsupported in MTD mode\n");
+ retval = CGPT_FAILED;
+ goto done;
+ }
+
if (CGPT_OK != ReadPMBR(&drive)) {
Error("Unable to read PMBR\n");
goto done;