From: Stefano Babic <sbabic@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 4/6] mmc: fsl_esdhc: Add support to force VSELECT set
Date: Tue, 17 Jun 2014 17:11:07 +0200 [thread overview]
Message-ID: <53A05A8B.8060306@denx.de> (raw)
In-Reply-To: <1402879613-21362-4-git-send-email-otavio@ossystems.com.br>
Hi Otavio,
On 16/06/2014 02:46, Otavio Salvador wrote:
> There are board were we cannot do voltage negotiation but want to set
> the VSELECT bit forcely to ensure it to work at 1.8V.
>
> This commit adds CONFIG_SYS_FSL_ESDHC_FORCE_VSELECT flag for this use.
>
> Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
> ---
>
> drivers/mmc/fsl_esdhc.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/mmc/fsl_esdhc.c b/drivers/mmc/fsl_esdhc.c
> index c75b38f..b3870e2 100644
> --- a/drivers/mmc/fsl_esdhc.c
> +++ b/drivers/mmc/fsl_esdhc.c
> @@ -517,6 +517,10 @@ static int esdhc_init(struct mmc *mmc)
> /* Set timout to the maximum value */
> esdhc_clrsetbits32(®s->sysctl, SYSCTL_TIMEOUT_MASK, 14 << 16);
>
> +#ifdef CONFIG_SYS_FSL_ESDHC_FORCE_VSELECT
> + esdhc_setbits32(®s->vendorspec, ESDHC_VENDORSPEC_VSELECT);
> +#endif
Instead of adding a new compiler switch that should be documented (I
have already read Marek's comments), what do you think to extend struct
fsl_esdhc_cfg, putting for exmaple an "options" field with this kind of
specialization ?
I see also a CONFIG_SYS_FSL_ESDHC_USE_PIO that slipped into mainline
(you are both right : Otavio is not the first to add such kind of
configuration switches that are still undocumented, but according to
rules should be documented as Marek said).
I would suggest to get rid as much as possible with these CONFIG_
switches. If we have some specialization for this driver before calling
esdhc_init (better: fsl_esdhc_initialize), they are self explaining and
we do not need further documentation. What do you think ?
Best regards,
Stefano
--
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================
next prev parent reply other threads:[~2014-06-17 15:11 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-16 0:46 [U-Boot] [PATCH 1/6] usb: ehci: mx6: Add support for i.MX6SL Otavio Salvador
2014-06-16 0:46 ` [U-Boot] [PATCH 2/6] imx: mx6sl: Extend USDHC SD2 pins to support 8-wire use Otavio Salvador
2014-06-16 0:46 ` [U-Boot] [PATCH 3/6] mmc: fsl_esdhc: Add CMD11 support to switch to 1.8V Otavio Salvador
2014-06-19 15:23 ` Andy Fleming
2014-06-16 0:46 ` [U-Boot] [PATCH 4/6] mmc: fsl_esdhc: Add support to force VSELECT set Otavio Salvador
2014-06-16 0:51 ` Marek Vasut
2014-06-16 1:22 ` Otavio Salvador
2014-06-16 1:27 ` Marek Vasut
2014-06-16 1:39 ` Otavio Salvador
2014-06-16 2:03 ` Marek Vasut
2014-06-16 2:24 ` Otavio Salvador
2014-06-16 7:03 ` Igor Grinberg
2014-06-16 11:48 ` Otavio Salvador
2014-06-17 6:00 ` Marek Vasut
2014-06-17 6:06 ` Michael Trimarchi
2014-06-17 15:49 ` Marek Vasut
2014-06-17 16:00 ` Michael Trimarchi
2014-06-17 6:42 ` Igor Grinberg
2014-06-17 15:11 ` Stefano Babic [this message]
2014-06-17 15:12 ` Otavio Salvador
2014-06-17 15:14 ` Michael Trimarchi
2014-06-17 15:19 ` Stefano Babic
2014-06-16 0:46 ` [U-Boot] [PATCH 5/6] Print ramdisk load address if it is in use Otavio Salvador
2014-06-16 4:38 ` Wolfgang Denk
2014-06-16 11:52 ` Otavio Salvador
2014-06-16 0:46 ` [U-Boot] [PATCH 6/6] warp: Add initial WaRP Board support Otavio Salvador
2014-06-16 0:54 ` Marek Vasut
2014-08-18 17:56 ` Fabio Estevam
2014-08-18 17:57 ` Fabio Estevam
2014-08-18 18:08 ` Otavio Salvador
2014-06-16 0:49 ` [U-Boot] [PATCH 1/6] usb: ehci: mx6: Add support for i.MX6SL Marek Vasut
2014-06-16 1:11 ` Otavio Salvador
2014-06-16 1:28 ` Marek Vasut
2014-06-16 7:05 ` Igor Grinberg
2014-06-16 11:51 ` Otavio Salvador
2014-06-17 14:56 ` Stefano Babic
2014-06-17 14:58 ` Otavio Salvador
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53A05A8B.8060306@denx.de \
--to=sbabic@denx.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.