Skip to content

RFC mmc: Field Firmware Update

Holger Schurig linux-mmc lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest6 patches 14 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6mmc: move mmc_prepare_mrq() to core.cdrivers/mmc/card/mmc_test.c drivers/mmc/core/core.c include/linux/mmc/core.h+49 -440 replies
2/6mmc: move mmc_wait_busy() to coredrivers/mmc/card/mmc_test.c drivers/mmc/core/core.c include/linux/mmc/core.h+43 -420 replies
3/6mmc: move mmc_check_result() to core.cdrivers/mmc/card/mmc_test.c drivers/mmc/core/core.c include/linux/mmc/core.h+74 -710 replies
4/6mmc: move mmc_simple_transfer() to core.cdrivers/mmc/card/mmc_test.c drivers/mmc/core/core.c include/linux/mmc/core.h+36 -320 replies
5/6mmc: move mmc_send_cxd_data() to core.cdrivers/mmc/core/mmc_ops.c include/linux/mmc/core.h+5 -20 replies
6/6mmc: eMMC Field Firmware Update supportdrivers/mmc/card/Kconfig drivers/mmc/card/Makefile drivers/mmc/card/block.c +4 more+533 -00 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC 0/6] mmc: Field Firmware Update

There have been some attempts to add FFU (field firmware update). The last AFAIK in Nov 2014, http://www.spinics.net/lists/linux-mmc/msg29324.html

But it seems that the committers weren't persistent enought.

I took the liberty to take Avi's patch and make it hopefully maintainer-review friendly.

The first 5 patches just move functions out of mmc_test.c into core.c. Those functions will later be used by both mmc_test.c and mmc_ffu.c. Contrary to Avi's patch I didn't add static helper functions to mmc_test.c, e.g. there's no mmc_test_prepare_mrq() that calls mmc_prepare_mrq(). It's simpler to call mmc_prepare_mrq() directly. It's just one more dereference from *mmc_card to *mmc_test_card anyway.

The patch [6/6] is http://www.spinics.net/lists/linux-mmc/msg29326.html, but with less checkpatch warnings. And it doesn't use mmc_send_ext_csd() anymore, which has been deleted since November.

I'm sending this patch as RFC now. It compiles (for me). But I get the firmware update file from Kingston only next Tuesday. That means that so far I haven't been testing it. It won't do anything without the proper user-space command in mmc-utils anyway :-)

Comments welcome (I intent to get this patch into the kernel)

The patch is against Linux GIT (v4.3-11748-g46d862b).

Holger

 drivers/mmc/card/Kconfig    |  11 +
 drivers/mmc/card/Makefile   |   1 +
 drivers/mmc/card/block.c    |   5 +
 drivers/mmc/card/mmc_ffu.c  | 489 ++++++++++++++++++++++++++++++++++++++++++++
 drivers/mmc/card/mmc_test.c | 235 +++++----------------
 drivers/mmc/core/core.c     | 134 ++++++++++++
 drivers/mmc/core/mmc_ops.c  |   4 +-
 include/linux/mmc/card.h    |   1 +
 include/linux/mmc/core.h    |  41 ++++
 include/linux/mmc/mmc.h     |   6 +
 10 files changed, 739 insertions(+), 188 deletions(-)
 create mode 100644 drivers/mmc/card/mmc_ffu.c
Signature · 1 line
2.1.4