From patchwork Thu May 9 10:57:46 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 406 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f200.google.com (mail-pg1-f200.google.com [209.85.215.200]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 31DCD3F086 for ; Thu, 9 May 2019 12:58:15 +0200 (CEST) Received: by mail-pg1-f200.google.com with SMTP id o8sf1427005pgq.5 for ; Thu, 09 May 2019 03:58:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1557399494; cv=pass; d=google.com; s=arc-20160816; b=HL0NatB8nryQwFljlfrYqWXM80sxEpSQosro6oT6aAUBlhrhbWTOWtF7118KT2d6Ed H/940bgxxyQpaDSE3TTxWArKWQ0RGxF+72uoSKwmak3kTfgb01MqN0KNihnVQMIaVyuU pPyUw9mItx9jg+WR5H7BYz98JRSRO7hgsa+yoA5lSZpGeVIlIjly+mPTDCI5Nci3Y7/9 u+V4ERhJ+b+5rgS3s0WsKsRAuhDOY1NBAvBgJYo2DM89nDoS5JI29cc0+wWnUU/FGTYV 3X195oNP3LR4a1fe4MV7c8zoLwMyuQT/rVrzmffjwEpK4YlAu/vDnvCVPp7MpS2kjD6H QPXA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=6lQnsf7aHXKlsSjtIENlON7OY4Zy0xfJqZwvpuurt20=; b=shIraYV9WnQBKV0jIOT2MJPZH3oqynHxJMuUhfHx9IdqBFjw5tG8PEDYiHDN6N2uU8 DAX9CjpDRGxpMdm46BQmDEMK6cCmrbUvMo+tpFUCvMHuebS1j/whBEqdiwm42HP3uEet AdlDMcg9EXOdAbec38Z/iaOPx+VNce65nCLd137SrxDYnBfwgQGX2wNXS50+qNORTOJr A0DWkzcE7H9jDepgBK8Hq294vk5OBt0laEPsnKHiAg3GEMeGTy1bHo9tpp+oNDxlnuDZ 6VmKGv2z/bYpsJGpc3aQA7hM1/uNxZ0d9E6w1Tgfbbt7c7n/txb/ExlEEeJlwCgFWYNt HX/g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=TZD0q6H3; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=6lQnsf7aHXKlsSjtIENlON7OY4Zy0xfJqZwvpuurt20=; b=UWaKZ4k6ZZLGtBK2MqcVFBCYooUIWwRWDkfVXA1RG9NsmuB6/Y3rgftjTFUndkg0Fs DjkAe3WNBnlIOEsdMzdcngyUgiXT+UahPpyaD/9kQgdF/i2lrPMGsXFuEdegVIym44hB W51o3QLbUFRkIhJTXHbvtV/EXehpoU2R0N2Cs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-unsubscribe; bh=6lQnsf7aHXKlsSjtIENlON7OY4Zy0xfJqZwvpuurt20=; b=sD+axcYyadRa7kfI3YbXpj3t0PwClsxr3owLQGPBGNqJfhJM3M9N6FfWHbsP9ywf4+ d3gqijXADloyRVNM0HtCbG2bhKe9emYCB1f63rK5tvfoLZXPuoFe05PB07kcNpAgQGmj j2ICXtqW+Q4GppCvswpJt/OlHeudHiVgYxNAr32WbPqmY1UXWitVSKcIPZ/HsL5qQ1lv yujKOT2KKXI9LN2KQeal0iNjZYF/Ig9EyblwGhyU8Po9azquLrtyN5DKMnzl6OC5/1a9 G8kdAjCX3jJ7f8EmgUp+Qj2z5yj7gDrHjIwNXrK4usHzxeAn7cE1YgYEHyJPta7YtAws /E7Q== X-Gm-Message-State: APjAAAVKyaQpgg6R/T/rMDLF7DR96TCbU+blhEyoKw8aO0BW1w3hpaQr YbOVJWQaxhYQBKFhkltvTjfw2NuR X-Google-Smtp-Source: APXvYqxY/Yl0OT4AlqQ4Bl9JxeeQxSW4xKK061KQnX8iYTbcZy9+xTOnKmYt9pMQvhxCC3hTXNSf8w== X-Received: by 2002:a65:4183:: with SMTP id a3mr4429067pgq.121.1557399493957; Thu, 09 May 2019 03:58:13 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a17:902:e5:: with SMTP id a92ls591017pla.10.gmail; Thu, 09 May 2019 03:58:13 -0700 (PDT) X-Received: by 2002:a17:902:7895:: with SMTP id q21mr3888342pll.73.1557399493598; Thu, 09 May 2019 03:58:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557399493; cv=none; d=google.com; s=arc-20160816; b=ovucyPx0h+d8NE7tq9V9/lT8dYgn/NYAgHFIyfkujEJVoTwAYyIM9KZBVEdCVDvlxW 6OYqyt4Ncj3grReiWCigzuiqUGQ2elW1duV+EZhKz5rIu7+dD4DDYPQCCC5QNshtFkiE 45ma2RpUfROdDDSEE/8t1e6LynskEMuH6EOTkpF8SdC4YbbG8UqHg125+85jX0kFG/p1 mBGyCRYE45ofdRCbiISgtI11PlP8ANWh7fSZQ/K3SEQCsroDilM/0i41SVgma4eQ1VxU Shk0p2JaTmFZ+JTH1aAv5aDUKH1jnQYXGjpIZm+UXSCSRI487FjVqadTvDGMX3ia36kE QsDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=wo83Y9eMyqzW3i6WsLdjT9/MKteUZiUdWU8bx3448Bw=; b=j25rE2u/l7aZ48lYbSr/MHl40gCbfPFr/hWz3GIu6ehM/iO+2vqM0Xu/nc2VK+4N9F 1ykGTTD0zEN3kW8y52/vk53rpxnAlH8u7tPlUvcujvZqMZ5AX02lJ5B0rmd+92j/swlf 9sUEReEsOZ/JcM8YErWnMB3YAtdqiExfcWVWK4sWNpBn4Ye8DGNIKvZdZR20bT5ofAyC hac8AwIGsOq8PnbPy8iGk9GR2s9xp2DCK3Bg2KtnnoKLZ53uPM3nz3HN2nvLsQiTJrtm X2GvZ7giYQz2+/aGyPG5iGgq57ZEBBwvPZPqY9tFXh7fUp+Bz5x9pid8clNuSyAhyT92 5zfQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=TZD0q6H3; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id w25sor2263922pfg.23.2019.05.09.03.58.13 for (Google Transport Security); Thu, 09 May 2019 03:58:13 -0700 (PDT) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; X-Received: by 2002:aa7:8554:: with SMTP id y20mr4024998pfn.258.1557399493298; Thu, 09 May 2019 03:58:13 -0700 (PDT) Received: from localhost.localdomain ([115.97.185.144]) by smtp.gmail.com with ESMTPSA id n184sm5996234pfn.21.2019.05.09.03.58.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 09 May 2019 03:58:12 -0700 (PDT) From: Jagan Teki To: Kever Yang , Simon Glass , Philipp Tomsich Cc: linux-rockchip@lists.infradead.org, linux-amarula@amarulasolutions.com, u-boot@lists.denx.de, Jagan Teki Subject: [PATCH 3/3] doc: rockchip: Add doc for rk3399 TPL build/flash Date: Thu, 9 May 2019 16:27:46 +0530 Message-Id: <20190509105746.24830-3-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20190509105746.24830-1-jagan@amarulasolutions.com> References: <20190509105746.24830-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=TZD0q6H3; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This patch add documentation for TPL build and flashing steps for rk3399 boards. Add full boot log for future reference. Signed-off-by: Jagan Teki Reviewed-by: Kever Yang --- doc/README.rockchip | 51 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 50 insertions(+), 1 deletion(-) diff --git a/doc/README.rockchip b/doc/README.rockchip index ca4d6473b0..264f7e4994 100644 --- a/doc/README.rockchip +++ b/doc/README.rockchip @@ -173,7 +173,10 @@ For example: => make u-boot.itb (Get spl/u-boot-spl-dtb.bin, u-boot.itb images and some boards would get - spl/u-boot-spl.bin since it doesn't enable CONFIG_SPL_OF_CONTROL) + spl/u-boot-spl.bin since it doesn't enable CONFIG_SPL_OF_CONTROL + + If TPL enabled on the target, get tpl/u-boot-tpl-dtb.bin or tpl/u-boot-tpl.bin + if CONFIG_TPL_OF_CONTROL not enabled) Writing to the board with USB ============================= @@ -455,6 +458,52 @@ Net: eth0: ethernet@fe300000 Hit any key to stop autoboot: 0 => +Option 3: Package the image with TPL: + + - Prefix rk3399 header to TPL image + + => cd /path/to/u-boot + => ./tools/mkimage -n rk3399 -T rksd -d tpl/u-boot-tpl-dtb.bin out + + - Concatinate tpl with spl + + => cd /path/to/u-boot + => cat ./spl/u-boot-spl-dtb.bin >> out + + - Write tpl+spl at 64th sector + + => sudo dd if=out of=/dev/sdc seek=64 + + - Write U-Boot proper at 16384 sector + + => sudo dd if=u-boot.itb of=/dev/sdc seek=16384 + => sync + +Put this SD (or micro-SD) card into your board and reset it. You should see +something like: + +U-Boot TPL board init +Trying to boot from BOOTROM +Returning to boot ROM... + +U-Boot SPL board init +Trying to boot from MMC1 + + +U-Boot 2019.07-rc1-00241-g5b3244767a (May 08 2019 - 10:51:06 +0530) + +Model: Orange Pi RK3399 Board +DRAM: 2 GiB +MMC: dwmmc@fe310000: 2, dwmmc@fe320000: 1, sdhci@fe330000: 0 +Loading Environment from MMC... OK +In: serial@ff1a0000 +Out: serial@ff1a0000 +Err: serial@ff1a0000 +Model: Orange Pi RK3399 Board +Net: eth0: ethernet@fe300000 +Hit any key to stop autoboot: 0 +=> + Using fastboot on rk3288 ======================== - Write GPT partition layout to mmc device which fastboot want to use it to