From patchwork Tue Sep 12 20:02:21 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 112384 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp34563qgf; Tue, 12 Sep 2017 13:02:35 -0700 (PDT) X-Google-Smtp-Source: ADKCNb5Vl2NKZSMMW874emt2sTA3cSPxVLnfX974lysmwlbACWjounTK6K0+MXUYQo3y+Z2N70Fl X-Received: by 10.80.129.68 with SMTP id 62mr6728917edc.175.1505246555659; Tue, 12 Sep 2017 13:02:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505246555; cv=none; d=google.com; s=arc-20160816; b=JjjjNgO75iWnlxsdbUAuTE27vvs7Bcp/AIjxahfi/IWEnRUyY49yO4kzhUozNtFgEY E4Gez6zBfHszXFVAAb66YmM0KoV6QNzUtEI8aeFHl6AuPrm23f9wmAbbdbUEzInwsJss L8mSxXTI20JxoqriW5nv8VcoXambs2Z/hWwZ8a9xahAFDe2KdJRJAMpT1a7lUhtGJOzm oOAU5zrxg8ohLCecu6Px94QSODhFjUB0eAj7nhAvFo2ngV8NbfRg6AieNSGjiocbOuuK GrA0Ouo7h5X1llXV0tH3TJ+9zGAvfdZ/y7G36DCvhd7vZulaVOXvb42huuvWqCL2pC8L 2y0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:message-id:date:to:from :arc-authentication-results; bh=05IPqX61reoSTNHTwN1qVvW86lMestj0O6zW6boMMcE=; b=K3Ks2xeGsKpY57+2Yq0x9YYV+net80a3S6TyQV3JBGfAUQWpPvavjYamADwJ3lifGQ X9sZVsI3fIIuBAXsc50+FpX4MU+7ur6BG5j+5qb9+uIO5tC1KPBlPBjNRX1KSDilGgLb d0CtjAJcQGiQs1oAutrenhFa6OSGTk2x9FLRmtxAULKlCVsWJ8Y627r5BXib+bQoIbeB 2tJKYW80Gtn8PB/x9umy9hSNINKGCJLq9jFkEaVRFSJ30ZVRRJXJNSkrT+6Nl90/JBQc zEjVGPDSWIIdLJFHz0Xmjt0Ido31Ur7YGv6nTPNdCHVt0YKo5RXWgFiUN49L2kH3tdlb y83w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id o35si11121403eda.272.2017.09.12.13.02.35; Tue, 12 Sep 2017 13:02:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by lists.denx.de (Postfix, from userid 105) id D8004C22147; Tue, 12 Sep 2017 20:02:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id B1FB5C21FD7; Tue, 12 Sep 2017 20:02:28 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id B0E2DC21FAD; Tue, 12 Sep 2017 20:02:27 +0000 (UTC) Received: from mail.free-electrons.com (mail.free-electrons.com [62.4.15.54]) by lists.denx.de (Postfix) with ESMTP id 69898C21F97 for ; Tue, 12 Sep 2017 20:02:27 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 110) id 2FF0F2083D; Tue, 12 Sep 2017 22:02:27 +0200 (CEST) Received: from localhost (LFbn-TOU-1-209-191.w86-201.abo.wanadoo.fr [86.201.56.191]) by mail.free-electrons.com (Postfix) with ESMTPSA id 06E7C20834; Tue, 12 Sep 2017 22:02:27 +0200 (CEST) From: Maxime Ripard To: Tom Rini Date: Tue, 12 Sep 2017 22:02:21 +0200 Message-Id: X-Mailer: git-send-email 2.13.5 Cc: u-boot@lists.denx.de, Jagan Teki , Maxime Ripard Subject: [U-Boot] [PATCH v2 0/3] mmc: sunxi: index hack removal X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" Hi, Here is an attempt at removing the hack in the sunxi code to switch the MMC indices depending on the boot device. It's based on Siarhei's suggestion to go through an environment variable set by the code, and then having a script in our default bootcmd to change the boot order in order to always favour the boot device, instead of always picking the external MMC first. Let me know what you think, Maxime Changes from v1: - Added the various tags - Rebased on top of v2017.09 - Split the spl_boot_device into a separate function instead of making it available in the !spl case Maxime Ripard (3): arm: sunxi: Move spl_boot_device in a separate function sunxi: Use sunxi_get_boot_device sunxi: Remove the MMC index hack arch/arm/include/asm/arch-sunxi/spl.h | 2 ++- arch/arm/mach-sunxi/board.c | 11 +++++--- board/sunxi/board.c | 26 ++++++++------------ cmd/fastboot/Kconfig | 2 ++- configs/A20-OLinuXino-Lime2-eMMC_defconfig | 1 +- configs/Sinlinx_SinA33_defconfig | 1 +- configs/parrot_r16_defconfig | 1 +- include/configs/sunxi-common.h | 30 ++++++++++++++++++----- 8 files changed, 47 insertions(+), 27 deletions(-) base-commit: c98ac3487e413c71e5d36322ef3324b21c6f60f9