All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Andrei Warkentin <andreiw@motorola.com>
Cc: linux-mmc@vger.kernel.org
Subject: Re: [PATCHv4] MMC: MMC boot partitions support.
Date: Thu, 31 Mar 2011 13:17:21 +0200	[thread overview]
Message-ID: <201103311317.22110.arnd@arndb.de> (raw)
In-Reply-To: <AANLkTimD=vwG-Jh0a4E2tYYYwA9sG5sVWS8BFrDBeThb@mail.gmail.com>

On Wednesday 30 March 2011, Andrei Warkentin wrote:
> On Wed, Mar 30, 2011 at 7:03 AM, Arnd Bergmann <arnd@arndb.de> wrote:
> Since eMMC 4.41, you can create "general purpose" partitions (up to
> 4), which will be carved out of the user partition, and can be used in
> any way possible, thus potentially holding file system partitions.

My feeling is that these should be separate from the boot partition.
It could probably be done using a new fs/partitions/mmc.c file
that directly interacts with the mmc layer instead of looking
at the MS-DOS master boot record. That way, you could define the
same partitions (mmcblk0p1, ...) using a different method.

It also requires a user interface that a new mmc-fdisk tool
can talk to, in order to modify the partition table, not sure
if it's possible to use the BLKPG ioctl for this.
 
> There is also the "Replay Protected Memory Block" device partition,
> which is not able to host a file system in the normal sense (because
> layer over the MMC block transfer protocol is a "replay protected
> transaction" protocol, which could be used by a user-mode application
> directly reading/writing from /dev/block/mmcblkXXX).

Ok. That sounds like a use case for an ioctl interface then, if
we even want to expose it.
 
> > * What devices specifically have these new partitions? Only eMMC 4.4
> >  or also other versions?
> >
> 
> Boot partitions are available in 4.3. The other ones (4 general
> purpose ones, rpmb since 4.41).
 
ok.

> Unfortunately, since the SD spec is proprietary, I have no way of
> confirming whether the SD device partitioning (AFAIK there is a
> concept of boot partitions for eSD) works the same way or not, so I
> was maximally safe in supporting MMC device partitioning.

The public parts of the SD standard specifically require MS-DOS
partitioning to be used, so I assume that there is no internal
method in addition. They also describe the presence of a "secure
area" that can only be accessed after authentication. This could
use a similar method as the boot partition, but it's unclear to
me whether that is something that anyone is interested in.

> > * How does a user identify which hardware partition corresponds to
> >  a given block device and vice versa?
> 
> Right now, you would just need to know. With postfixes like
> mmcblk0b0/mmcblk0g0 you would be able to tell the device partitions
> apart from the main mmcblk0.

Regarding the naming, I would not use a trailing zero, but it's probably
a subjective thing. The other names I could imagine for the boot partition
of mmc 0 are mmcboot0, mmcblk0b or mmcblk0boot.

I also mentioned the character device option. Yet another way would be
to add a sysfs_bin_attribute that corresponds to the boot partition and
can be accessed using read/write, like we do for PCI resources.

	Arnd

  parent reply	other threads:[~2011-03-31 11:17 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-19 11:18 MMC/eMMC partitioning support Andrei Warkentin
2011-03-19 11:18 ` [RFC] MMC: MMC boot partitions support Andrei Warkentin
2011-03-19 12:13   ` Andrei Warkentin
2011-03-21 14:19   ` [PATCH] " Andrei Warkentin
2011-03-22  3:54   ` [PATCHv3] " Andrei Warkentin
2011-03-22 21:11   ` MMC partitions support (4th revision) Andrei Warkentin
2011-03-22 21:11   ` [PATCHv4] MMC: MMC boot partitions support Andrei Warkentin
2011-03-29 22:45     ` Andrei Warkentin
2011-03-30 12:03       ` Arnd Bergmann
2011-03-30 20:07         ` Andrei Warkentin
2011-03-30 22:43           ` Chris Ball
2011-03-30 22:46             ` Chris Ball
2011-03-30 23:18               ` Andrei Warkentin
2011-03-30 23:34                 ` Chris Ball
2011-03-31  6:57                   ` Andrei Warkentin
2011-03-31 11:01                     ` Arnd Bergmann
2011-03-31 19:17                       ` Andrei Warkentin
2011-03-31 19:37                         ` Chris Ball
2011-03-31 20:01                           ` Andrei Warkentin
2011-03-31 20:03                           ` Chris Ball
2011-03-31 20:01                             ` Andrei Warkentin
2011-04-01  9:23                               ` Arnd Bergmann
2011-04-01 14:52                                 ` Chris Ball
2011-04-01  9:21                         ` Arnd Bergmann
2011-03-31 11:17           ` Arnd Bergmann [this message]
2011-03-31 19:29             ` Andrei Warkentin
2011-04-01 10:38               ` Arnd Bergmann
2011-04-01 18:42                 ` Andrei Warkentin
2011-04-01 19:25                   ` Arnd Bergmann
2011-04-01 19:42                     ` Andrei Warkentin
2011-04-04 12:22                       ` [PATCH] " Andrei Warkentin
2011-04-04 11:52                         ` Andrei Warkentin
2011-04-11 21:13                           ` [patchv3 1/4] MMC: Rename erase_timeout to cmd_timeout_ms Andrei Warkentin
2011-04-11 21:13                           ` [patchv3 2/4] MMC: SDHCI R1B command handling + MMC_CAP_ERASE Andrei Warkentin
2011-04-12  9:06                             ` Dong, Chuanxiao
2011-04-12 18:05                               ` Andrei Warkentin
2011-04-13  1:59                                 ` Dong, Chuanxiao
2011-04-13  5:44                                   ` Andrei Warkentin
2011-04-15 21:34                                     ` Cyril Hrubis
2011-08-10 13:30                             ` Chris Ball
2011-04-11 21:13                           ` [patchv3 3/4] MMC: Allow setting CMD timeout for CMD6 (SWITCH) Andrei Warkentin
2011-04-11 21:13                           ` [patchv3 4/4] MMC: MMC boot partitions support Andrei Warkentin
2011-04-11 22:00                             ` Chris Ball
2011-04-11 22:10                               ` Andrei Warkentin
2011-04-11 22:22                                 ` Chris Ball
2011-04-11 22:18                                   ` Andrei Warkentin
2011-04-11 23:10                                     ` [patchv4 1/2] MMC: block.c cleanup for host claim/release Andrei Warkentin
2011-04-11 23:10                                     ` [patchv4 2/2] MMC: MMC boot partitions support Andrei Warkentin
2011-04-11 23:20                                     ` [patchv3 4/4] " Chris Ball
2011-04-11 23:24                                       ` Andrei Warkentin
2011-04-21  1:13                             ` Chris Ball
2011-04-21  1:30                               ` Chris Ball
2011-04-21  5:09                                 ` Philip Rakity
2011-04-21  5:22                                   ` Chris Ball
2011-04-21  5:31                                     ` Andrei Warkentin
2011-04-21  6:07                                       ` [RFC] MMC: Block: Ensure hardware partitions don't mess with mmcblk device naming Andrei Warkentin
2011-04-21  8:17                                         ` Andrei Warkentin
2011-04-21 14:44                                           ` Chris Ball
2011-04-22  0:20                                         ` Chris Ball
2011-04-22  3:46                                           ` [PATCH] " Andrei Warkentin
2011-04-22  3:50                                             ` Andrei Warkentin
2011-04-22 22:34                                             ` Chris Ball
2011-04-21  4:31                               ` [patchv3 4/4] MMC: MMC boot partitions support Jaehoon Chung

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=201103311317.22110.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=andreiw@motorola.com \
    --cc=linux-mmc@vger.kernel.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 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.