diff mbox

[U-Boot,v2,03/18] mmc: make eMMC general purpose partition numbering match spec

Message ID 1417712535-14006-4-git-send-email-Diego.SantaCruz@spinetix.com
State Changes Requested
Delegated to: Pantelis Antoniou
Headers show

Commit Message

Diego Santa Cruz Dec. 4, 2014, 5:02 p.m. UTC
The eMMC spec numbers general purpose partitions starting at 1, but
the mmcinfo output follows the internal numbering which starts at 0.
Make the mmcinfo command output number partitions as in the eMMC
spec to avoid confusion.
---
 common/cmd_mmc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff mbox

Patch

diff --git a/common/cmd_mmc.c b/common/cmd_mmc.c
index 56c8680..414fac6 100644
--- a/common/cmd_mmc.c
+++ b/common/cmd_mmc.c
@@ -108,7 +108,7 @@  static void print_mmcinfo(struct mmc *mmc)
 			bool is_enh = has_enh &&
 				(mmc->part_attr & EXT_CSD_ENH_GP(i));
 			if (mmc->capacity_gp[i]) {
-				printf("GP%i Capacity: ", i);
+				printf("GP%i Capacity: ", i+1);
 				print_size(mmc->capacity_gp[i],
 					   is_enh ? " ENH\n" : "\n");
 			}