18c2ecf20Sopenharmony_ci==========================================================
28c2ecf20Sopenharmony_ciInterface between kernel and boot loaders on Exynos boards
38c2ecf20Sopenharmony_ci==========================================================
48c2ecf20Sopenharmony_ci
58c2ecf20Sopenharmony_ciAuthor: Krzysztof Kozlowski
68c2ecf20Sopenharmony_ci
78c2ecf20Sopenharmony_ciDate  : 6 June 2015
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_ciThe document tries to describe currently used interface between Linux kernel
108c2ecf20Sopenharmony_ciand boot loaders on Samsung Exynos based boards. This is not a definition
118c2ecf20Sopenharmony_ciof interface but rather a description of existing state, a reference
128c2ecf20Sopenharmony_cifor information purpose only.
138c2ecf20Sopenharmony_ci
148c2ecf20Sopenharmony_ciIn the document "boot loader" means any of following: U-boot, proprietary
158c2ecf20Sopenharmony_ciSBOOT or any other firmware for ARMv7 and ARMv8 initializing the board before
168c2ecf20Sopenharmony_ciexecuting kernel.
178c2ecf20Sopenharmony_ci
188c2ecf20Sopenharmony_ci
198c2ecf20Sopenharmony_ci1. Non-Secure mode
208c2ecf20Sopenharmony_ci
218c2ecf20Sopenharmony_ciAddress:      sysram_ns_base_addr
228c2ecf20Sopenharmony_ci
238c2ecf20Sopenharmony_ci============= ============================================ ==================
248c2ecf20Sopenharmony_ciOffset        Value                                        Purpose
258c2ecf20Sopenharmony_ci============= ============================================ ==================
268c2ecf20Sopenharmony_ci0x08          exynos_cpu_resume_ns, mcpm_entry_point       System suspend
278c2ecf20Sopenharmony_ci0x0c          0x00000bad (Magic cookie)                    System suspend
288c2ecf20Sopenharmony_ci0x1c          exynos4_secondary_startup                    Secondary CPU boot
298c2ecf20Sopenharmony_ci0x1c + 4*cpu  exynos4_secondary_startup (Exynos4412)       Secondary CPU boot
308c2ecf20Sopenharmony_ci0x20          0xfcba0d10 (Magic cookie)                    AFTR
318c2ecf20Sopenharmony_ci0x24          exynos_cpu_resume_ns                         AFTR
328c2ecf20Sopenharmony_ci0x28 + 4*cpu  0x8 (Magic cookie, Exynos3250)               AFTR
338c2ecf20Sopenharmony_ci0x28          0x0 or last value during resume (Exynos542x) System suspend
348c2ecf20Sopenharmony_ci============= ============================================ ==================
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ci
378c2ecf20Sopenharmony_ci2. Secure mode
388c2ecf20Sopenharmony_ci
398c2ecf20Sopenharmony_ciAddress:      sysram_base_addr
408c2ecf20Sopenharmony_ci
418c2ecf20Sopenharmony_ci============= ============================================ ==================
428c2ecf20Sopenharmony_ciOffset        Value                                        Purpose
438c2ecf20Sopenharmony_ci============= ============================================ ==================
448c2ecf20Sopenharmony_ci0x00          exynos4_secondary_startup                    Secondary CPU boot
458c2ecf20Sopenharmony_ci0x04          exynos4_secondary_startup (Exynos542x)       Secondary CPU boot
468c2ecf20Sopenharmony_ci4*cpu         exynos4_secondary_startup (Exynos4412)       Secondary CPU boot
478c2ecf20Sopenharmony_ci0x20          exynos_cpu_resume (Exynos4210 r1.0)          AFTR
488c2ecf20Sopenharmony_ci0x24          0xfcba0d10 (Magic cookie, Exynos4210 r1.0)   AFTR
498c2ecf20Sopenharmony_ci============= ============================================ ==================
508c2ecf20Sopenharmony_ci
518c2ecf20Sopenharmony_ciAddress:      pmu_base_addr
528c2ecf20Sopenharmony_ci
538c2ecf20Sopenharmony_ci============= ============================================ ==================
548c2ecf20Sopenharmony_ciOffset        Value                                        Purpose
558c2ecf20Sopenharmony_ci============= ============================================ ==================
568c2ecf20Sopenharmony_ci0x0800        exynos_cpu_resume                            AFTR, suspend
578c2ecf20Sopenharmony_ci0x0800        mcpm_entry_point (Exynos542x with MCPM)      AFTR, suspend
588c2ecf20Sopenharmony_ci0x0804        0xfcba0d10 (Magic cookie)                    AFTR
598c2ecf20Sopenharmony_ci0x0804        0x00000bad (Magic cookie)                    System suspend
608c2ecf20Sopenharmony_ci0x0814        exynos4_secondary_startup (Exynos4210 r1.1)  Secondary CPU boot
618c2ecf20Sopenharmony_ci0x0818        0xfcba0d10 (Magic cookie, Exynos4210 r1.1)   AFTR
628c2ecf20Sopenharmony_ci0x081C        exynos_cpu_resume (Exynos4210 r1.1)          AFTR
638c2ecf20Sopenharmony_ci============= ============================================ ==================
648c2ecf20Sopenharmony_ci
658c2ecf20Sopenharmony_ci3. Other (regardless of secure/non-secure mode)
668c2ecf20Sopenharmony_ci
678c2ecf20Sopenharmony_ciAddress:      pmu_base_addr
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci============= =============================== ===============================
708c2ecf20Sopenharmony_ciOffset        Value                           Purpose
718c2ecf20Sopenharmony_ci============= =============================== ===============================
728c2ecf20Sopenharmony_ci0x0908        Non-zero                        Secondary CPU boot up indicator
738c2ecf20Sopenharmony_ci                                              on Exynos3250 and Exynos542x
748c2ecf20Sopenharmony_ci============= =============================== ===============================
758c2ecf20Sopenharmony_ci
768c2ecf20Sopenharmony_ci
778c2ecf20Sopenharmony_ci4. Glossary
788c2ecf20Sopenharmony_ci
798c2ecf20Sopenharmony_ciAFTR - ARM Off Top Running, a low power mode, Cortex cores and many other
808c2ecf20Sopenharmony_cimodules are power gated, except the TOP modules
818c2ecf20Sopenharmony_ciMCPM - Multi-Cluster Power Management
82