From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 8021DC43334 for ; Sun, 3 Jul 2022 19:20:34 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B8B2F844F8; Sun, 3 Jul 2022 21:20:32 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=suse.de header.i=@suse.de header.b="TztOrXJo"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="agvrvwGP"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 99B15844F6; Sun, 3 Jul 2022 21:20:31 +0200 (CEST) Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 6583A844E4 for ; Sun, 3 Jul 2022 21:20:29 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=msuchanek@suse.de Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 3473E2028A; Sun, 3 Jul 2022 19:20:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1656876029; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=AUXxZleKgrCSTqnirLiTCVSfS9pGipwoEwB+lo/WORk=; b=TztOrXJoVPikDOWqcjBSASvB+RTKl2odDr095X3pfSDN7MfTck/Li2zQlOzi3ClETmRJoU 3Q4md1Br8AyHH6lkmu/klvgNPT62YqYDejZivHODnJNdRYe72QvcIx+leYpo4pGPdBu4nK lJIuImlN0D6X0qC0EG6OkHnyzwON//I= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1656876029; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=AUXxZleKgrCSTqnirLiTCVSfS9pGipwoEwB+lo/WORk=; b=agvrvwGPMz63TzMLcRB5T6BYY+zRfyHlinS0OvBJn3XzErevGDwXU8WhGUiielWLGnU5RC otxCD3lgOR/kxIBg== Received: from naga.suse.cz (unknown [10.100.224.114]) by relay2.suse.de (Postfix) with ESMTP id 80A9D2C141; Sun, 3 Jul 2022 19:20:28 +0000 (UTC) From: Michal Suchanek To: u-boot@lists.denx.de Cc: Michal Suchanek , Andre Przywara , Simon Glass , Philipp Tomsich , Kever Yang , Jagan Teki , Andre Przywara , Andy Yan , Michal Simek , Igor Opaniuk Subject: [PATCH 0/2] Command for entering mask rom USB download mode Date: Sun, 3 Jul 2022 21:20:20 +0200 Message-Id: X-Mailer: git-send-email 2.36.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Hello, many ARM SoCs have a mask rom feature that provides interface for downloading firmware over USB. Downstream rockchip u-boot has 'brom' or 'rbrom' command for this purpose, and downstream sunxi u-boot provides 'efex' command. p-boot has code for entering FEL on A64 SoC. With this patch I am able to activate the USB downloader on a rk3399 but the rkflashtool fails to communicate with the device. On a H2+ I can get into the FEL mode and get flash parameters. YMMV I don't have any great idea how to structure this so that the command does not need platform-specific code. Is there an example of a command that has platform-specific implementations? Thanks Michal Andy Yan (1): cmd: boot: add brom cmd to reboot to brom dnl mode Michal Suchanek (1): cmd: boot: add brom cmd to reboot to FEL mode .../arm/include/asm/arch-rockchip/boot_mode.h | 1 + arch/arm/include/asm/arch-sunxi/cpu.h | 11 ++++++ arch/arm/mach-sunxi/Kconfig | 18 ++++++++++ arch/arm/mach-sunxi/board.c | 24 +++++++++++++ cmd/boot.c | 35 +++++++++++++++++++ 5 files changed, 89 insertions(+) -- 2.36.1