linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: olof@lixom.net (Olof Johansson)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/4] mmc: omap: adapt the hsmmc driver to device tree
Date: Fri, 4 Nov 2011 13:04:15 -0700	[thread overview]
Message-ID: <20111104200415.GC3045@quad.lixom.net> (raw)
In-Reply-To: <1320407441-29697-3-git-send-email-rnayak@ti.com>

On Fri, Nov 04, 2011 at 05:20:39PM +0530, Rajendra Nayak wrote:
> Define dt bindings for the ti-omap-hsmmc, and adapt
> the driver to extract data (which was earlier passed as
> platform_data) from device tree node.
> 
> Signed-off-by: Rajendra Nayak <rnayak@ti.com>
> ---
>  .../devicetree/bindings/mmc/ti-omap-hsmmc.txt      |   50 +++++++++
>  drivers/mmc/host/omap_hsmmc.c                      |  117 ++++++++++++++++++++
>  2 files changed, 167 insertions(+), 0 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/mmc/ti-omap-hsmmc.txt
> 
> diff --git a/Documentation/devicetree/bindings/mmc/ti-omap-hsmmc.txt b/Documentation/devicetree/bindings/mmc/ti-omap-hsmmc.txt
> new file mode 100644
> index 0000000..370af1b
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/mmc/ti-omap-hsmmc.txt
> @@ -0,0 +1,50 @@
> +* TI Highspeed MMC host controller for OMAP
> +
> +The Highspeed MMC Host Controller on TI OMAP family
> +provides an interface for MMC, SD, and SDIO types of memory cards.
> +
> +Required properties:
> +- compatible: Should be "ti,omap-hsmmc<n>", "ti,omap2-hsmmc";
> +n is controller instance starting 0, for OMAP2/3 controllers

No, no, no. You should not have to specify the unit-address in the compatible
field. They are all programmed the same way, right?

Also, they should go from the specific to the generic, but the first property
is the same for 2/3 and 4. That's wrong.

> +- compatible: Should be "ti,omap-hsmmc<n>", "ti,omap4-hsmmc";
> +n is controller instance starting 0, for OMAP4 controllers
> +- ti,hwmods: Must be "mmc<n>", n is controller instance starting 1

I didn't think hwmod bindings were settled on yet?

> +- reg : should contain hsmmc registers location and length
> +
> +Optional properties:
> +ti,hsmmc-supports-dual-volt: boolean, supports dual voltage cards

ti,dual-voltage is a better name here (by definition, if it has the property it
supports it, the word "supports" is redundant).

> +ti,hsmmc-nr-slots: Number of mmc slots

You shouldn't have to specify this, it can be derived from the number of child
nodes.

> +<supply-name>-supply: phandle to the regulator device tree node
> +"supply-name" examples are "vmmc", "vmmc_aux" etc
> +ti,hsmmc-has-pbias: Has PBIAS cell support
> +ti,hsmmc-has-special-reset: Requires a special softreset sequence

you can drop hsmmc- from the properties here

> +
> +For every supported slot a slot node can be defined
> +with the following optional properties
> +
> +ti,hsmmc-slot-name: Name assocaited to the mmc slot
> +ti,hsmmc-gpio-cd: gpio for card detect
> +ti,hsmmc-gpio-wp: gpio for write protect

Please use the same standard as the other mmc controllers for CD/WP.

> +ti,hsmmc-ocr-mask: mmc/sd/sdio ocr mask

What is OCR mask?

> +ti,hsmmc-non-removable: non-removable slot (like eMMC)

Same here, non-removable should be standardized.


-Olof

  reply	other threads:[~2011-11-04 20:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-04 11:50 [PATCH 0/4] omap hsmmc device tree support Rajendra Nayak
2011-11-04 11:50 ` [PATCH 1/4] mmc: Add additional binding for mmc host controller Rajendra Nayak
2011-11-04 19:58   ` Olof Johansson
2011-11-04 11:50 ` [PATCH 2/4] mmc: omap: adapt the hsmmc driver to device tree Rajendra Nayak
2011-11-04 20:04   ` Olof Johansson [this message]
2011-11-04 21:25     ` Cousson, Benoit
2011-11-04 21:28       ` Olof Johansson
2011-11-07  6:14       ` Rajendra Nayak
2011-11-04 22:15     ` Segher Boessenkool
2011-11-07  6:18     ` Rajendra Nayak
2011-11-14 21:30   ` Tony Lindgren
2011-11-15  4:15     ` Rajendra Nayak
2011-11-19  0:21       ` Tony Lindgren
2011-11-04 11:50 ` [PATCH 3/4] omap4: mmc: Pass SoC and board data for omap4 mmc from dt Rajendra Nayak
2011-11-04 11:50 ` [PATCH 4/4] omap4: mmc: use auxdata to pass platform function ptrs Rajendra Nayak

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=20111104200415.GC3045@quad.lixom.net \
    --to=olof@lixom.net \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).