All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Cc: linux-mmc@vger.kernel.org, Chris Ball <cjb@laptop.org>,
	devicetree@vger.kernel.org, kernel@pengutronix.de
Subject: Re: [RFC 0/2] Set mmc(blk)X with DT alias
Date: Thu, 25 Jul 2013 10:28:38 -0700	[thread overview]
Message-ID: <51F16046.3020809@wwwdotorg.org> (raw)
In-Reply-To: <1374656973-16250-1-git-send-email-s.trumtrar@pengutronix.de>

On 07/24/2013 02:09 AM, Steffen Trumtrar wrote:
> Hi!
> 
> Embedded devices often use multiple SD/MMC devices as boot/rootfs disks.
> Some of them are removable, some not. If the removable cards are not
> present, but are probed before the non-removable ones, the indexing
> scheme changes. This makes it harder to hard-code the rootfs in the
> cmdline.
>
> First solution I came up with was the alias-node in DT.
> I guess my implementation is pretty hacky and ugly, but you can get lost
> pretty fast in the whole mmc stack.
> For example, the second patch should use "card->host->index" instead of parsing
> the alias again, I guess. I'm not sure why it currently doesn't though.

This has been discussed a few times before and rejected IIRC. One issue
is that block device ID is actually decoupled from host controller ID
anyway, e.g. if a removable device is mounted, removed, and then
re-plugged the new device can get a different ID, so this approach
doesn't really work in all cases anyway.

> So, if there is a better place or solution to specify a reliable ordering
> of mmc devices, please let me hear it.

root=UUID=xxx or root=PARTUUID=xxx are the best solution. With recent
U-Boot, you can enable and use the "part" command to find the partition
UUID automatically, and hence not need to hard-code anything. Something
similar could presumably be implemented for other bootloaders.

  parent reply	other threads:[~2013-07-25 17:28 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-24  9:09 [RFC 0/2] Set mmc(blk)X with DT alias Steffen Trumtrar
2013-07-24  9:09 ` [RFC 1/2] mmc: block: allow setting name_idx via devicetree Steffen Trumtrar
2013-07-24  9:09 ` [RFC 2/2] mmc: host: allow setting index " Steffen Trumtrar
2013-07-25 17:28 ` Stephen Warren [this message]
2013-07-26  8:09   ` [RFC 0/2] Set mmc(blk)X with DT alias Steffen Trumtrar

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=51F16046.3020809@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=cjb@laptop.org \
    --cc=devicetree@vger.kernel.org \
    --cc=kernel@pengutronix.de \
    --cc=linux-mmc@vger.kernel.org \
    --cc=s.trumtrar@pengutronix.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.