From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Tue, 04 Jun 2013 12:28:41 -0600 Subject: [U-Boot] [PATCH] common: env_mmc: Make mmc->part_num in sync after a partition switch In-Reply-To: <1370370223-7087-1-git-send-email-fabio.estevam@freescale.com> References: <1370370223-7087-1-git-send-email-fabio.estevam@freescale.com> Message-ID: <51AE31D9.3040502@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 06/04/2013 12:23 PM, Fabio Estevam wrote: > When running the "save" command several times on a mx6qsabresd we see: > > U-Boot > save > Saving Environment to MMC... > Writing to MMC(1)... done > U-Boot > save > Saving Environment to MMC... > MMC partition switch failed ... > Fix this by making mmc->part_num to be in sync with CONFIG_SYS_MMC_ENV_PART > after the partition has been changed in mmc_switch_part(). I deliberately didn't do this, because fini_mmc_for_env() passes the value of mmc->part_num to call mmc_switch_part() in order to put things back the way they were. This fix would break that. Can you investigate why you're seeing the "MMC partition switch failed" message?