19 Jul, 2014
1 commit
-
Add missing prototypes for global functions and
make local functions static.cc: panto@antoniou-consulting.com
Signed-off-by: Jeroen Hofstee
02 Jun, 2014
1 commit
23 May, 2014
2 commits
-
This patch adds functions for read, write and authentication
key programming for the Replay Protected Memory Block partition
in the eMMC.Acked-by: Pantelis Antoniou
Signed-off-by: Pierre Aubert -
MMC switch command for unsupported feature (e.g. bus width) sets a switch
error bit in card status. This bit should be checked, and, if it's set,
no access with new controller settings should be performed.Acked-by: Pantelis Antoniou
Signed-off-by: Andrew Gabbasov
16 May, 2014
2 commits
-
Signed-off-by: Jaehoon Chung
Tested-by: Lukasz Majewski
Acked-by: Lukasz Majewski
Signed-off-by: Minkyu Kang -
Signed-off-by: Jaehoon Chung
Reviewed-by: Lukasz Majeski
Tested-by: Lukasz Majewski
Acked-by: Lukasz Majewski
Signed-off-by: Minkyu Kang
05 May, 2014
1 commit
-
Structure definition used type block_dev_desc_t, defined in part.h, which
wasn't included in mmc.h. It worked only in circumstances when common.h,
or another header using part.h was incuded in implementation files.Change-Id: I5b203928b689887e3e78beb00a378955e0553eb7
Signed-off-by: Mateusz Zalega
Acked-by: Pantelis Antoniou
Cc: Minkyu Kang
08 Apr, 2014
1 commit
-
Conflicts:
arch/arm/cpu/arm926ejs/mxs/Makefile
include/configs/trats.h
include/configs/trats2.h
include/mmc.h
02 Apr, 2014
1 commit
-
Some eMMC chips may need the RST_n_FUNCTION bit set to a non-zero value
in order for warm reset of the system to work. Details on this being
required will be part of the eMMC datasheet. Also add using this
command to the dra7xx README.* Whitespace fix by panto
Signed-off-by: Tom Rini
Acked-by: Pantelis Antoniou
29 Mar, 2014
1 commit
-
In the recent mmc cleanup, the mmc_host_is_spi macro was broken and
bfin_sdh.c had mmc->bus_width turned into mmc_bus_width(mmc), both of
which were incorrect.Signed-off-by: Tom Rini
24 Mar, 2014
3 commits
-
The way that struct mmc was implemented was a bit of a mess;
configuration and internal state all jumbled up in a single structure.On top of that the way initialization is done with mmc_register leads
to a lot of duplicated code in drivers.Typically the initialization got something like this in every driver.
struct mmc *mmc = malloc(sizeof(struct mmc));
memset(mmc, 0, sizeof(struct mmc);
/* fill in fields of mmc struct */
/* store private data pointer */
mmc_register(mmc);By using the new mmc_create call one just passes an mmc config struct
and an optional private data pointer like this:struct mmc = mmc_create(&cfg, priv);
All in tree drivers have been updated to the new form, and expect
mmc_register to go away before long.Changes since v1:
* Use calloc instead of manually calling memset.
* Mark mmc_register as deprecated.Signed-off-by: Pantelis Antoniou
-
Using an array is pointless; even more pointless (and scary) is using
sprintf to fill it without a format string.Signed-off-by: Pantelis Antoniou
-
Remove the in-structure ops and put them in mmc_ops with
a constant pointer to it.This makes the mmc structure smaller as well as conserving
code space (in theory).All in-tree drivers are converted as well; this is done in a
single patch in order to not break git bisect.Changes since V1:
Fix compilation b0rked issue on omap platforms where OMAP_GPIO was
not set.Signed-off-by: Pantelis Antoniou
05 Mar, 2014
2 commits
-
Fixes the following sparse warning:
wandboard.c:137:5: warning: symbol 'board_mmc_init' was not declared. Should it be static?
Cc: Pantelis Antoniou
Signed-off-by: Fabio Estevam
08 Feb, 2014
3 commits
-
The open and close mmc sub-commands implement a hard-coded set of values
specific to the SMDK5250 platform. Remove these commands as what they
did can be done instead with a series of mmc dev / bootpart / bootbus
commands instead now.Cc: Amar
Cc: Minkyu Kang
Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Add a bootbus sub-command to the mmc command to allow for setting
the boot_bus_width, reset_boot_bus_width and boot_mode fields of
BOOT_BUS_WIDTH (EXT_CSD[177]).Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Add a partconf sub-command to the mmc command to allow for setting
the boot_ack, boot_partition and partition_access fields of
PARTITION_CONFIG (formerly BOOT_CONFIG, EXT_CSD[179]). Part of this
requires changing the check for 'part' from an strncmp to a strcmp, like
the rest of the sub-commands.Cc: Andy Fleming
Cc: Pantelis Antoniou
Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou
09 Jan, 2014
2 commits
-
The eMMC and the SD-Card specifications describe the optional SET_DSR command.
During measurements at our lab we found that some cards implementing this feature
having really strong driver strengts per default. This can lead to voltage peaks
above the specification of the host on signal edges for data sent from a card to
the host.Since availability of a given card type may be shorter than the time a certain
hardware will be produced it is useful to have support for this command (Alternative
would be changing termination resistors and adapting the driver strength of the
host to the used card.)Following proposal for an implementation:
- new field that reflects CSD field DSR_IMP in struct mmc
- new field for design specific DSR value in struct mmc
- board code can set DSR value in mmc struct just after registering an controller
- mmc_startup sends the the stored DSR value before selecting a card, if DSR_IMP is setAdditionally the mmc command is extended to make is possible to play around with different
DSR values.The concept was tested on a i.MX53 based platform using a Micron eMMC card where the default
DSR is 0x0400 (12mA) but in our design 0x0100 (0x0100) were enough. To use this feature for
instance on a mx53loco one have to add a call to mmc_set_dsr() in board_mmc_init() after
calling fsl_esdhc_initialize() for the eMMC.Signed-off-by: Markus Niebel
Acked-by: Pantelis Antoniou -
The spl_mmc_load() was removed while converting to
CONFIG_SPL_FRAMEWORK usage the definition was removed
but the declaration was missed. This patch removes this
declaration.Signed-off-by: Lad, Prabhakar
Acked-by: Pantelis Antoniou
31 Oct, 2013
1 commit
-
EXT_CSD_ERASE_GROUP_DEF is lost every time after a reset or
power off. Set it if device has enhanced partitions.Signed-off-by: Oliver Metz
Acked-by: Pantelis Antoniou
18 Sep, 2013
1 commit
-
When CONFIG_MMC_SPI is not enabled, the MMC_MODE_SPI capability can
never be set. However there is code in mmc.c which uses the
mmc_host_is_spi macro to check that capability & act accordingly. If we
expand that macro to 0 when CONFIG_MMC_SPI is not set (since it will
always be 0 at runtime anyway) then the compiler can optimize away the
SPI-specific code paths in mmc.c.Signed-off-by: Paul Burton
24 Jul, 2013
1 commit
-
Signed-off-by: Wolfgang Denk
[trini: Fixup common/cmd_io.c]
Signed-off-by: Tom Rini
22 Jun, 2013
1 commit
19 Jun, 2013
1 commit
-
Conflicts:
spl/Makefile
14 Jun, 2013
1 commit
-
Enhance the MMC core to calculate the size of each MMC partition, and
update mmc->capacity whenever a partition is selected. This causes:mmc dev 0 1 ; mmcinfo
... to report the size of the currently selected partition, rather than
always reporting the size of the user partition.Signed-off-by: Stephen Warren
Signed-off-by: Andy Fleming
13 Jun, 2013
1 commit
-
This patch adds APIs to access(open / close) and to resize boot partiton of EMMC.
Signed-off-by: Amar
Signed-off-by: Minkyu Kang
07 May, 2013
1 commit
-
Most of time that MMC driver spends on initializing a device is polling
OCR (operation conditions register). To decouple this polling loop,
device init is split into two parts: The first part fires the OCR query
command, and the second part polls the result. So the caller is now no
longer bound to the OCR-polling delay; he may fire the query, go
somewhere and then come back later for the result.To use this, call mmc_set_preinit() on any device which needs this.
This can save significant amounts of time on boot (e.g. 200ms) by
hiding the MMC init time behind other init.Signed-off-by: Che-Liang Chiou
Signed-off-by: Simon Glass
Acked-by: Jaehoon Chung
Signed-off-by: Andy Fleming
02 May, 2013
1 commit
-
The number 512 appears quite a bit in the mmc code. Add a constant for this
so that it can be used here and in other parts of the code (e.g. SPL code
which loads from mmc).Signed-off-by: Simon Glass
Reviewed-by: Vadim Bendebury
17 Apr, 2013
2 commits
-
Support to check whether the SD3.0 or not.
Signed-off-by: Jaehoon Chung
Signed-off-by: Kyungmin Park
Tested-by: Rommel Custodio -
eMMC vesrion is supported up to v4.5.
But bootloader isn't saw the exact eMMC version.
After applied this patch,
if use the mmcinfo command, then can see the exactly mmc version.Signed-off-by: Jaehoon Chung
Signed-off-by: Kyungmin Park
Acked-by: Rommel Custodio
09 Mar, 2013
1 commit
-
Add generic mmc write protection functionality.
Signed-off-by: Nikita Kiryanov
Signed-off-by: Igor Grinberg
06 Sep, 2012
1 commit
-
Some eMMC devices contain boot partitions, but do not set the PART_SUPPORT
bit in EXT_CSD_PARTITIONING_SUPPORT. Allow partition selection on such
devices, by enabling partition switching when EXT_CSD_BOOT_MULT is set.Note that the Linux kernel enables access to boot partitions solely based
on the value of EXT_CSD_BOOT_MULT; EXT_CSD_PARTITIONING_SUPPORT only
influences access to "general" partitions.eMMC devices affected by this issue exist on various NVIDIA Tegra
platforms (and presumably many others too), such as Harmony (plug-in eMMC),
Seaboard, Springbank, and Whistler (plug-in eMMC).Signed-off-by: Stephen Warren
Signed-off-by: Andy Fleming
02 Sep, 2012
1 commit
-
Signed-off-by: Kaspter Ju
01 Sep, 2012
1 commit
-
DA850/OMAP-L138 does not support strict MMC/SD boot mode. SPL will
be in SPI flash and U-Boot image will be in MMC/SD card. SPL will
do the low level initialization and then loads the u-boot image
from MMC/SD card.Define CONFIG_SPL_MMC_LOAD macro in the DA850/OMAP-L138
configuration file to enable this feature.Tested-by: Christian Riesch
Signed-off-by: Lad, Prabhakar
Signed-off-by: Rajashekhara, Sudhakar
Signed-off-by: Hadli, Manjunath
09 May, 2012
2 commits
-
The outdated struct mmc_csd was only used by old atmel_mci driver which was
removed in c9abb4260c30fbfd51bb2cd551e7426e2ae15b66.Signed-off-by: Andreas Bießmann
cc: Andy Fleming -
This patch sets the MMC width according to the MMC host capabilities.
It turned out, that there are some targets (e.g. GONI), which are able
to read data from SPI only at 4 bit mode.
This patch restricts the width number according to the MMC host.Signed-off-by: Lukasz Majewski
Signed-off-by: Kyungmin Park
Cc: Andy Fleming
13 Mar, 2012
1 commit
-
gen_atmel_mci works on AVR32 as well, so no need to use the legacy
mmc driver. This also has the nice side effect of being able to use
SDHC cards an those boards.Signed-off-by: Sven Schnelle
Signed-off-by: Andreas Bießmann
16 Feb, 2012
1 commit
-
Align the card status polling with the Linux kernel and retry the
command at least five times. Also some cards apparently mishandle the
status bits, so make sure to check the card state too.Signed-off-by: Jan Kloetzke
Cc: Andy Fleming
09 Jan, 2012
1 commit
-
Check for card detect each time an MMC/SD device is initialized. If card
detection is not implemented, this code behaves as before and continues
assuming a card is present. If no card is detected, has_init is reset
for the MMC/SD device (to force initialization next time) and an error
is returned.Signed-off-by: Thierry Reding
Tested-by: Jason Liu