Difference between revisions of "STM32MP15 U-Boot"

[quality revision] [quality revision]
m
m
 

Contents

1 STM32MP15

This article briefly describes the STM32MP15x lines More info.png support in U-Boot.

1 STM32MP15 in U-Boot STM32MP15x lines More info.png support[edit]

For detailed information, please read the file in the delivered U-Boot code = board/st/stm32mp1/README

Also available in official U-Boot Git: board/st/stm32mp1/README

1

.

1 STM32MP15 support[edit]

Code :

  • arch/arm/mach-stm32mp stm32mp : arch specific code for all STM32 ArmSTM32 Arm® Cortex® MPUs MPUs More info.png
  • board/st/stm32mp1 : generic STMicroelectronics board for STMP32MP1STM32MP1 Series
  • drivers/*/*stm32* : drivers

Configuration Files:

1.

2 Selecting targets : choose defconfig and Device Tree[edit]

Each boot chain is supported by one U-Boot configuration with defconfig

Boot chain defconfig FSBL SSBL TEE support
Trusted Boot stm32mp15_trusted_defconfig TF-A U-Boot
u-boot.stm32
-
Trusted Boot with OP-TEE stm32mp15_optee_defconfig TF-A U-Boot
u-boot.stm32
yes
Basic Boot stm32mp15_basic_defconfig SPL
u-boot-spl.stm32
U-Boot
u-boot.img
-
Warning white.png Warning
The basic boot chain is not supported/promoted by STMicroelectronics to make product (see Boot chains overview for details).

Several targets/ boards are supported with the associated device-tree (same name as kernel):

Board part number Description Device tree
STM32MP157C-EV1
Evaluation board More info.png
PMIC =
MB1262+MB1263 stm32mp157c-ev1
STM32MP157C-ED1
Evaluation
daughter board
daughterboard
PMIC =
MB1263 stm32mp157c-ed1
STM32MP157A-DK1
Discovery kit More info.png MB1272 stm32mp157a-dk1
STM32MP157C-DK2
Discovery kit More info.png MB1272+
DSI screen
MB1407 stm32mp157c-dk2
1.

3 Compilation[edit]

see U-Boot_overview#U-Boot_build

With <mode> = 'basic', 'trusted' or 'optee'

 
$> make stm32mp15_<mode>_defconfig
 $> make DEVICE_TREE=<device tree name> all
  • DEVICE_TREE: select in arch/arm/dts the device tree that is used
  • KBUILD_OUTPUT: change the destination directory for the build
  • EXT_DTB: select external device tree

2 4 Examples[edit]

24.1 STM32MP157C-EV1 Evaluation board More info.png trusted boot[edit]

 
$> make stm32mp15_trusted_defconfig
 $> make DEVICE_TREE=stm32mp157c-ev1 all

24.2 STM32MP157C-DK2 Discovery kit More info.png trusted boot[edit]

Using export to select the device tree

 
$> export KBUILD_OUTPUT=../build/trusted
 $> export DEVICE_TREE=stm32mp157c-dk2
 $> make stm32mp15_trusted_defconfig
 $> make all

24.3 STM32MP157C-ED1 Evaluation daughterboard basic boot[edit]

 
$> export KBUILD_OUTPUT=../build/basic
 $> make stm32mp15_basic_defconfig
 $> make DEVICE_TREE=stm32mp157c-ed1 all

24.4 Trusted boot chain with external device tree[edit]

 
$> make stm32mp15_trusted_defconfig
 $> make EXT_DTB=boot/stm32mp157c-myboard.dtb all


== STM32MP15 in U-Boot ==This article briefly describes the {{MicroprocessorDevice | device=15}} support in [[U-Boot_overview|U-Boot]].

== {{MicroprocessorDevice | device=15}} support ==
For detailed information, please read the file in the delivered U-Boot code = '''{{CodeSource | U-Boot | board/st/stm32mp1/README'''}}


Also available in official U-Boot Git: .

Code :
* {{CodeSource | U-Boot | board/st/stm32mp1/README}}

=== STM32MP15 support ===

Code :
* arch/arm/mach-stm32mp }}: arch specific code for all STM32 Arm<sup>&reg;</sup> Cortex<sup>&reg;</sup> MPUs
* board/st/stm32mp1{{MicroprocessorDevice | device=Class}}
* {{CodeSource | U-Boot | board/st/stm32mp1}}: generic STMicroelectronics board for STMP32MP1{{MicroprocessorDevice | device=1}}* drivers/*/*stm32* : drivers

Configuration Files:
* defconfig file
** {{CodeSource | U-Boot | configs/stm32mp15_basic_defconfig

** }}
** {{CodeSource | U-Boot | configs/stm32mp15_optee_defconfig

** }}
** {{CodeSource | U-Boot | configs/stm32mp15_trusted_defconfig}}

* config files
** {{CodeSource | U-Boot | include/configs/stm32mp1.h}}

* Device tree 

** arch/arm/dts/in {{CodeSource | U-Boot | arch/arm/dts }}
** stm32mp157*-<board>.dts : same as kernel
** arch/arm/dts/stm32mp157*-<board>-u-boot.dtsi : addition for u-boot ( <<device tree>>-u-boot.dtsi automatically included in build process)

=== Selecting targets : choose defconfig and Device Tree ===


Each [[Boot_chains_overview|boot chain]] is supported by one [[U-Boot_overview#Kbuild|U-Boot configuration with defconfig]]

{| class="wikitablest-table"
|-
! Boot chain  !! defconfig !! FSBL !! SSBL !! TEE support
|-
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] || stm32mp15_trusted_defconfig || TF-A  || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.stm32]] || -
|-
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] with [[OP-TEE_overview|'''OP-TEE''']] || stm32mp15_optee_defconfig || TF-A  || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.stm32]] || yes
|-
| [[Boot_chains_overview#STM32MP boot chains|'''Basic Boot''']] || stm32mp15_basic_defconfig || SPL<br>[[U-Boot_overview#Output_files|u-boot-spl.stm32]] || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.img]] || -
|}

{{Warning | The basic boot chain is not supported/promoted by STMicroelectronics to make product (see [[Boot_chains_overview#Boot_chains_features_set|Boot chains overview]] for details).}} 

Several [[STM32MP15_boards|targets/ boards]] are supported with the associated device-tree (same name as kernel):

{| class="wikitablest-table"
|-
! Board part number  !! Description !! Device tree
|-
| '''STM32MP157C-EV1''' || '''Evaluation board'''<br/>PMIC = MB1262+MB1263 || '''stm32mp157c-ev1'''
|-
| '''STM32MP157C-ED1''' || Evaluation daughter board<br/>PMIC = MB1263 || stm32mp157c-ed1
|-
| '''STM32MP157A-DK1''' || '''Discovery kit'''<br/>MB1272 || '''stm32mp157a-dk1'''
|-
| '''STM32MP157C-DK2''' || '''Discovery kit'''<br/>MB1272 + DSI screen || '''stm32mp157c-dk2'''
|}

=== Compilation ==={{Board | type=157C-EV1}}''' || [[MB1262]]+[[MB1263]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-ev1.dts|'''stm32mp157c-ev1'''}}
|-
| STM32MP157C-ED1 Evaluation daughterboard || [[MB1263]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-ed1.dts|stm32mp157c-ed1}}
|-
| '''{{Board | type=157A-DK1}}''' || [[MB1272]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157a-dk1.dts|'''stm32mp157a-dk1'''}}
|-
| '''{{Board | type=157C-DK2}}''' || [[MB1272]]+[[MB1407]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-dk2.dts|'''stm32mp157c-dk2'''}}
|}

== Compilation ==

see [[U-Boot_overview#U-Boot_build]]

With <mode> = 'basic', 'trusted' or 'optee'
$>{{PC$}} make stm32mp15_<mode>_defconfig$>{{PC$}} make DEVICE_TREE=<device tree name> all

*'''DEVICE_TREE''': select in arch/arm/dts the device tree that is used
* '''KBUILD_OUTPUT''': change the destination directory for the build
* '''EXT_DTB''': select external device tree

== Examples ==

===EV1 trusted boot ===
  $> {{Board | type=157C-EV1}}  trusted boot ===
  {{PC$}} make stm32mp15_trusted_defconfig$>{{PC$}} make DEVICE_TREE=stm32mp157c-ev1 all

=== DK2{{Board | type=157C-DK2}} trusted boot ===
Using export to select the device tree$>{{PC$}} export KBUILD_OUTPUT=../build/trusted$>{{PC$}} export DEVICE_TREE=stm32mp157c-dk2$>{{PC$}} make stm32mp15_trusted_defconfig$>{{PC$}} make all

=== STM32MP157C-ED1 Evaluation daughterboard basic boot ===$>{{PC$}} export KBUILD_OUTPUT=../build/basic$>{{PC$}} make stm32mp15_basic_defconfig$>{{PC$}} make DEVICE_TREE=stm32mp157c-ed1 all

=== Trusted boot chain with external device tree ===$>{{PC$}} make stm32mp15_trusted_defconfig$>{{PC$}} make EXT_DTB=boot/stm32mp157c-myboard.dtb all
<noinclude>

[[Category:U-Boot]]
{{PublicationRequestId | 12895 | 2019-08-01}}</noinclude>
(10 intermediate revisions by one other user not shown)
Line 1: Line 1:
== STM32MP15 in U-Boot ==
+
This article briefly describes the {{MicroprocessorDevice | device=15}} support in [[U-Boot_overview|U-Boot]].
For detailed information, please read the file in the delivered U-Boot code = '''board/st/stm32mp1/README'''
 
   
Also available in official U-Boot Git: {{CodeSource | U-Boot | board/st/stm32mp1/README}}
+
== {{MicroprocessorDevice | device=15}} support ==
   
=== STM32MP15 support ===
+
For detailed information, please read the file in the delivered U-Boot code = {{CodeSource | U-Boot | board/st/stm32mp1/README}}
  +
 
  +
Also available in official U-Boot Git.
   
 
Code :
 
Code :
* arch/arm/mach-stm32mp : arch specific code for all STM32 Arm<sup>&reg;</sup> Cortex<sup>&reg;</sup> MPUs
+
* {{CodeSource | U-Boot | arch/arm/mach-stm32mp}}: arch specific code for {{MicroprocessorDevice | device=Class}}
* board/st/stm32mp1: generic STMicroelectronics board for STMP32MP1
+
* {{CodeSource | U-Boot | board/st/stm32mp1}}: generic STMicroelectronics board for {{MicroprocessorDevice | device=1}}
 
* drivers/*/*stm32* : drivers
 
* drivers/*/*stm32* : drivers
   
 
Configuration Files:
 
Configuration Files:
 
* defconfig file
 
* defconfig file
** configs/stm32mp15_basic_defconfig
+
** {{CodeSource | U-Boot | configs/stm32mp15_basic_defconfig}}
** configs/stm32mp15_optee_defconfig
+
** {{CodeSource | U-Boot | configs/stm32mp15_optee_defconfig}}
** configs/stm32mp15_trusted_defconfig
+
** {{CodeSource | U-Boot | configs/stm32mp15_trusted_defconfig}}
 
* config files
 
* config files
** include/configs/stm32mp1.h
+
** {{CodeSource | U-Boot | include/configs/stm32mp1.h}}
* Device tree  
+
* Device tree in {{CodeSource | U-Boot | arch/arm/dts }}
** arch/arm/dts/stm32mp157*-<board>.dts : same as kernel
+
** stm32mp157*-<board>.dts : same as kernel
** arch/arm/dts/stm32mp157*-<board>-u-boot.dtsi : addition for u-boot ( <<device tree>>-u-boot.dtsi automatically included in build process)
+
** stm32mp157*-<board>-u-boot.dtsi : addition for u-boot ( <<device tree>>-u-boot.dtsi automatically included in build process)
   
=== Selecting targets : choose defconfig and Device Tree ===
+
== Selecting targets : choose defconfig and Device Tree ==
   
 
Each [[Boot_chains_overview|boot chain]] is supported by one [[U-Boot_overview#Kbuild|U-Boot configuration with defconfig]]
 
Each [[Boot_chains_overview|boot chain]] is supported by one [[U-Boot_overview#Kbuild|U-Boot configuration with defconfig]]
   
{| class="wikitable"
+
{| class="st-table"
 
|-
 
|-
 
! Boot chain  !! defconfig !! FSBL !! SSBL !! TEE support
 
! Boot chain  !! defconfig !! FSBL !! SSBL !! TEE support
 
|-
 
|-
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] || stm32mp15_trusted_defconfig || TF-A  || '''U-Boot'''<br>u-boot.stm32 || -
+
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] || stm32mp15_trusted_defconfig || TF-A  || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.stm32]] || -
 
|-
 
|-
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] with [[OP-TEE_overview|'''OP-TEE''']] || stm32mp15_optee_defconfig || TF-A  || '''U-Boot'''<br>u-boot.stm32 || yes
+
| [[Boot_chains_overview#STM32MP boot chains|''' Trusted Boot''']] with [[OP-TEE_overview|'''OP-TEE''']] || stm32mp15_optee_defconfig || TF-A  || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.stm32]] || yes
 
|-
 
|-
| [[Boot_chains_overview#STM32MP boot chains|'''Basic Boot''']] || stm32mp15_basic_defconfig || SPL<br>u-boot-spl.stm32 || '''U-Boot'''<br>u-boot.img || -
+
| [[Boot_chains_overview#STM32MP boot chains|'''Basic Boot''']] || stm32mp15_basic_defconfig || SPL<br>[[U-Boot_overview#Output_files|u-boot-spl.stm32]] || '''U-Boot'''<br>[[U-Boot_overview#Output_files|u-boot.img]] || -
 
|}
 
|}
   
Line 41: Line 42:
 
Several [[STM32MP15_boards|targets/ boards]] are supported with the associated device-tree (same name as kernel):
 
Several [[STM32MP15_boards|targets/ boards]] are supported with the associated device-tree (same name as kernel):
   
{| class="wikitable"
+
{| class="st-table"
 
|-
 
|-
 
! Board part number  !! Description !! Device tree
 
! Board part number  !! Description !! Device tree
 
|-
 
|-
| '''STM32MP157C-EV1''' || '''Evaluation board'''<br/>PMIC = MB1262+MB1263 || '''stm32mp157c-ev1'''
+
| '''{{Board | type=157C-EV1}}''' || [[MB1262]]+[[MB1263]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-ev1.dts|'''stm32mp157c-ev1'''}}
 
|-
 
|-
| '''STM32MP157C-ED1''' || Evaluation daughter board<br/>PMIC = MB1263 || stm32mp157c-ed1
+
| STM32MP157C-ED1 Evaluation daughterboard || [[MB1263]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-ed1.dts|stm32mp157c-ed1}}
 
|-
 
|-
| '''STM32MP157A-DK1''' || '''Discovery kit'''<br/>MB1272 || '''stm32mp157a-dk1'''
+
| '''{{Board | type=157A-DK1}}''' || [[MB1272]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157a-dk1.dts|'''stm32mp157a-dk1'''}}
 
|-
 
|-
| '''STM32MP157C-DK2''' || '''Discovery kit'''<br/>MB1272 + DSI screen || '''stm32mp157c-dk2'''
+
| '''{{Board | type=157C-DK2}}''' || [[MB1272]]+[[MB1407]] || {{CodeSource | U-Boot | arch/arm/dts/stm32mp157c-dk2.dts|'''stm32mp157c-dk2'''}}
 
|}
 
|}
   
=== Compilation ===
+
== Compilation ==
 
see [[U-Boot_overview#U-Boot_build]]
 
see [[U-Boot_overview#U-Boot_build]]
   
 
With <mode> = 'basic', 'trusted' or 'optee'
 
With <mode> = 'basic', 'trusted' or 'optee'
   
   $> make stm32mp15_<mode>_defconfig
+
   {{PC$}} make stm32mp15_<mode>_defconfig
   $> make DEVICE_TREE=<device tree name> all
+
   {{PC$}} make DEVICE_TREE=<device tree name> all
   
 
*'''DEVICE_TREE''': select in arch/arm/dts the device tree that is used
 
*'''DEVICE_TREE''': select in arch/arm/dts the device tree that is used
Line 68: Line 69:
 
== Examples ==
 
== Examples ==
   
===EV1 trusted boot ===
+
=== {{Board | type=157C-EV1}}  trusted boot ===
   $> make stm32mp15_trusted_defconfig
+
   {{PC$}} make stm32mp15_trusted_defconfig
   $> make DEVICE_TREE=stm32mp157c-ev1 all
+
   {{PC$}} make DEVICE_TREE=stm32mp157c-ev1 all
   
=== DK2 trusted boot ===
+
=== {{Board | type=157C-DK2}} trusted boot ===
 
Using export to select the device tree
 
Using export to select the device tree
   $> export KBUILD_OUTPUT=../build/trusted
+
   {{PC$}} export KBUILD_OUTPUT=../build/trusted
   $> export DEVICE_TREE=stm32mp157c-dk2
+
   {{PC$}} export DEVICE_TREE=stm32mp157c-dk2
   $> make stm32mp15_trusted_defconfig
+
   {{PC$}} make stm32mp15_trusted_defconfig
   $> make all
+
   {{PC$}} make all
   
=== ED1 basic boot ===
+
=== STM32MP157C-ED1 Evaluation daughterboard basic boot ===
   $> export KBUILD_OUTPUT=../build/basic
+
   {{PC$}} export KBUILD_OUTPUT=../build/basic
   $> make stm32mp15_basic_defconfig
+
   {{PC$}} make stm32mp15_basic_defconfig
   $> make DEVICE_TREE=stm32mp157c-ed1 all
+
   {{PC$}} make DEVICE_TREE=stm32mp157c-ed1 all
   
 
=== Trusted boot chain with external device tree ===
 
=== Trusted boot chain with external device tree ===
   $> make stm32mp15_trusted_defconfig
+
   {{PC$}} make stm32mp15_trusted_defconfig
   $> make EXT_DTB=boot/stm32mp157c-myboard.dtb all
+
   {{PC$}} make EXT_DTB=boot/stm32mp157c-myboard.dtb all
   
 
<noinclude>
 
<noinclude>