From mboxrd@z Thu Jan 1 00:00:00 1970 From: Igor Grinberg Date: Tue, 09 Sep 2014 18:25:59 +0300 Subject: [U-Boot] [PATCH v3] env_mmc: correct fini partition to match init partition In-Reply-To: <1409764963-9617-1-git-send-email-pab@pabigot.com> References: <1409761938-27902-1-git-send-email-pab@pabigot.com> <1409764963-9617-1-git-send-email-pab@pabigot.com> Message-ID: <540F1C07.6000408@compulab.co.il> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Peter, On 09/03/14 20:22, Peter A. Bigot wrote: > The code to set the MMC partition uses an weak function to obtain the > correct partition number. Use that instead of the compile-time default > when deciding whether it needs to switch back. > > Fixes: 6e7b7df4df43574 ("env_mmc: support env partition setup in runtime") It is sometimes also useful to Cc the original author of the patch. Cc: Dmitry Lifshitz > Signed-off-by: Peter A. Bigot > --- > V3: > * Add Fixes line as requested > > V2: > * Preserve desired behavior of avoiding diagnostic when no HW partition supported > * Supersedes https://patchwork.ozlabs.org/patch/385355/ > > common/env_mmc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/common/env_mmc.c b/common/env_mmc.c > index a7621a8..14648e3 100644 > --- a/common/env_mmc.c > +++ b/common/env_mmc.c > @@ -113,7 +113,7 @@ static void fini_mmc_for_env(struct mmc *mmc) > #ifdef CONFIG_SPL_BUILD > dev = 0; > #endif > - if (CONFIG_SYS_MMC_ENV_PART != mmc->part_num) > + if (mmc_get_env_part(mmc) != mmc->part_num) > mmc_switch_part(dev, mmc->part_num); > #endif > } > -- Regards, Igor.