From patchwork Sat Jun 6 10:05:51 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 6559251 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id BDCE59F1CC for ; Sat, 6 Jun 2015 10:07:26 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 39030205FE for ; Sat, 6 Jun 2015 10:07:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 29FFF205BC for ; Sat, 6 Jun 2015 10:07:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750736AbbFFKHT (ORCPT ); Sat, 6 Jun 2015 06:07:19 -0400 Received: from mail-pa0-f51.google.com ([209.85.220.51]:34938 "EHLO mail-pa0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751137AbbFFKHR (ORCPT ); Sat, 6 Jun 2015 06:07:17 -0400 Received: by pacyx8 with SMTP id yx8so27525350pac.2; Sat, 06 Jun 2015 03:07:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=USh6N5y8gvO5f8VUm4S2wqPb0T8q5E1GcXr9VDsaSvI=; b=okk1VsghNmEp34Ifv/xlpfikNCw0RIqTvwayTxFANLFVJer2x8kX5VT0xAHOVs+uxh LTfIU6gm+MX6RG3MRenTh1k1Kb+4YtMxHJl0zXSiTfNXTPT4CQFOgWHuAu3TG5uEd1OH VDIi1ckUnXVaSnQdbsknxB2UEMfDsM2sq7xHaeg0w8pK1HYvN0X1do/iYBSaj/QNCugC lY6CrfeI+8pgPSXzXlwm6ngw5LbloZaxHwRj3XcoDcslVjtNnpwa58g5VmRqH4Nv3r0x 1AgMyMBBkhoweUQeIOHDIAJYVZemNSviTdU1C5dWvKoZ4VEydrInnFRKNT7HQFFz0lAu BTUw== X-Received: by 10.70.63.104 with SMTP id f8mr13093764pds.49.1433585236692; Sat, 06 Jun 2015 03:07:16 -0700 (PDT) Received: from localhost.localdomain ([125.130.175.98]) by mx.google.com with ESMTPSA id da3sm9195826pdb.8.2015.06.06.03.07.12 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 06 Jun 2015 03:07:15 -0700 (PDT) From: Krzysztof Kozlowski To: Jonathan Corbet , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, Kukjin Kim , linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org Cc: Russell King , Kevin Hilman , Arnd Bergmann , Olof Johansson , Javier Martinez Canillas , Bartlomiej Zolnierkiewicz , Krzysztof Kozlowski Subject: [PATCH] Documentation: ARM: EXYNOS: Describe boot loaders interface Date: Sat, 6 Jun 2015 19:05:51 +0900 Message-Id: <1433585151-3627-1-git-send-email-k.kozlowski.k@gmail.com> X-Mailer: git-send-email 2.1.4 Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Various boot loaders for Exynos based boards use certain memory addresses during booting for different purposes. Mostly this is one of following : 1. as a CPU boot address, 2. for storing magic cookie related to low power mode (AFTR, sleep). The document, based solely on kernel source code, tries to group the information scattered over different files. This would help in the future when adding support for new SoC or when extending features related to low power modes. Signed-off-by: Krzysztof Kozlowski --- Documentation/arm/Samsung/Bootloader-interface.txt | 53 ++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 Documentation/arm/Samsung/Bootloader-interface.txt diff --git a/Documentation/arm/Samsung/Bootloader-interface.txt b/Documentation/arm/Samsung/Bootloader-interface.txt new file mode 100644 index 000000000000..b96ead9a6919 --- /dev/null +++ b/Documentation/arm/Samsung/Bootloader-interface.txt @@ -0,0 +1,53 @@ + Interface between kernel and boot loaders on Exynos boards + ========================================================== + +Author: Krzysztof Kozlowski +Date : 6 June 2015 + +The document tries to describe currently used interface between Linux kernel +and boot loaders on Samsung Exynos based boards. This is not a definition +of interface but rather a description of existing state, a reference +for information purpose only. + +In the document "boot loader" means any of following: U-boot, proprietary +SBOOT or any other firmware for ARMv7 and ARMv8 initializing the board before +executing kernel. + + +1. Non-Secure mode +Address: sysram_ns_base_addr +Offset Value Purpose +============================================================================= +0x08 exynos_cpu_resume_ns System suspend +0x0c 0x00000bad (Magic cookie) System suspend +0x1c exynos4_secondary_startup Secondary CPU boot +0x1c + 4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot +0x20 0xfcba0d10 (Magic cookie) AFTR +0x24 exynos_cpu_resume_ns AFTR +0x28 + 4*cpu 0x8 (Magic cookie, Exynos3250) AFTR + + +2. Secure mode +Address: sysram_base_addr +Offset Value Purpose +============================================================================= +0x00 exynos4_secondary_startup Secondary CPU boot +0x04 exynos4_secondary_startup (Exynos542x) Secondary CPU boot +4*cpu exynos4_secondary_startup (Exynos4412) Secondary CPU boot +0x20 exynos_cpu_resume (Exynos4210 r1.0) AFTR +0x24 0xfcba0d10 (Magic cookie, Exynos4210 r1.0) AFTR + +Address: pmu_base_addr +Offset Value Purpose +============================================================================= +0x0800 exynos_cpu_resume AFTR +0x0814 exynos4_secondary_startup (Exynos4210 r1.1) Secondary CPU boot +0x0818 0xfcba0d10 (Magic cookie, Exynos4210 r1.1) AFTR +0x081C exynos_cpu_resume (Exynos4210 r1.1) AFTR + + +3. Other (regardless of secure/non-secure mode) +Address: pmu_base_addr +Offset Value Purpose +============================================================================= +0x0908 Non-zero (only Exynos3250) Secondary CPU boot up indicator