]> Git Repo - u-boot.git/commit - drivers/mmc/mmc.c
mmc:fix Call mmc_init() when executing mmc_get_dev()
authorŁukasz Majewski <[email protected]>
Thu, 19 Apr 2012 02:39:18 +0000 (02:39 +0000)
committerAndy Fleming <[email protected]>
Fri, 13 Jul 2012 22:04:50 +0000 (17:04 -0500)
commit40242bc394030871e6de13883fe1ace5c0b8e15b
tree15b363efb1a2c162af82fb0eb8c105ec6a0a0891
parentad5fd92289a0721eb8a4f6c648e67f45915812cd
mmc:fix Call mmc_init() when executing mmc_get_dev()

This code adds call to mmc_init(), for partition related commands (e.g.
fatls, fatinfo etc.).

It is safe to call mmc_init() multiple times since mmc->has_init flag
prevents from multiple initialization.

The FAT related code calls get_dev high level method and then uses
elements from mmc->block_dev, which is uninitialized until the mmc_init
(and thereof mmc_startup) is called.

This problem appears on boards, which don't use mmc as the default
place for envs

Signed-off-by: Lukasz Majewski <[email protected]>
Signed-off-by: Kyungmin Park <[email protected]>
Cc: Andy Fleming <[email protected]>
Signed-off-by: Andy Fleming <[email protected]>
drivers/mmc/mmc.c
This page took 0.029734 seconds and 4 git commands to generate.