]> git.kernelconcepts.de Git - karo-tx-uboot.git/commit
sunxi: Create helper function veryfing valid boot signature on MMC
authorDaniel Kochmański <dkochmanski@turtle-solutions.eu>
Fri, 29 May 2015 14:55:41 +0000 (16:55 +0200)
committerLothar Waßmann <LW@KARO-electronics.de>
Wed, 9 Sep 2015 11:49:04 +0000 (13:49 +0200)
commitf69ffb24ad76a9fde07a824000cb3e28e86a5d54
treeede4427431740e9dccfe4c8ff124f098de20e344
parente55ad34dc82eccd1fcb13a30f5327e02e25213de
sunxi: Create helper function veryfing valid boot signature on MMC

This patch extracts checking for valid SD card "eGON.BT0" signature from
`board_mmc_init` into function `sunxi_mmc_has_egon_boot_signature`.

Buffer for mmc sector is allocated and freed at runtime. `panic` is
triggered on malloc failure.

Signed-off-by: Daniel Kochmański <dkochmanski@turtle-solutions.eu>
CC: Roy Spliet <r.spliet@ultimaker.com>
Cc: Ian Campbell <ijc@hellion.org.uk>
[hdegoede@redhat.com: Small bugfix to make it work for devs other then mmc0]
Acked-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
arch/arm/include/asm/arch-sunxi/mmc.h
board/sunxi/board.c
drivers/mmc/sunxi_mmc.c