SlideShare a Scribd company logo
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 1
Vasileios Amoiridis
EP-CMD | CMS DAQ group
Acknowledgements: P. Žejdl & M. Dobson
Deploying and testing firmware/software
on Zynq MPSoC with GitLab CI/CD pipelines
Workflow for the Zynq MPSoC UltraScale+
• Vivado creates the Hardware Description File which contains the configuration of the ARM
processor and its peripherals. This file is used later by PetaLinux.
• PetaLinux creates the Firmware Images and the PetaLinux rootfs. The images are used to boot
the Zynq and the PetaLinux rootfs is used to create the Board Specific ROOTFS.
We use Network Boot:
• The images need to be deployed to the SD Card and the TFTP server that are going to be used for
booting. The ROOTFS needs to be deployed on the NFS server.
• When the board is booting its booting procedure is being monitored.
• After the board is booted, it is ready for automated testing!
In order to implement all the above steps, GitLab’s CI/CD Pipeline framework is used!
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 2
Linux on Zynq MPSoC UltraScale+
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 3
FSBL
PMU-FW
U-Boot ATF
Bootgen
BOOT.bin
CentOS 8 aarch64
(CERN repos)
Install CentOS 8
using QEMU VM
CentOS 8
(rootfs Image)
Xilinx Linux Kernel
(PetaLinux Package)
Build Kernel
CentOS 8 rootfs generation
Xilinx Linux Kernel
Device-Tree
(Board specific)
ZynqMP tools
(PetaLinux rootfs)
Bitstream
Source of inspiration: Exploration of ZynqUS+ for integrated slow control on Serenity for the CMS Track Trigger (Presentation given by Oliver Sander)
Kernel modules
Board Specific CentOS 8 rootfs
Kernel
Image
Install rootfs
CentOS 8 rootfs w/
ZynqMP support
Firmware
Integration
Image Repo
TFTP Server
NFS Server
SD Card
Vivado Pipeline
What is the role of the Vivado Pipeline?
• It is responsible to produce the Hardware Description File (.xsa) that is used by the PetaLinux Pipeline
• The .xsa file is the Hardware Description file. It has the configuration of the ARM processor and its peripherals
• The .bit file is the Bitstream file. It configures the Programmable Logic – FPGA. (Optional, i.e additional AXI bus)
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 4
Vivado Pipeline
Run
Synthesis
Run
Implementation
Generate Bitstream and
Hardware Description
Synthesis Implementation .bit and .xsa Generation
.xsa
.bit
• Every Vivado project is going under Synthesis and Implementation in a clean environment
• Runs inside a Docker Container with Vivado installed
Output files
PetaLinux Pipeline
What is the role of the PetaLinux Pipeline?
• It uses the Hardware Description File produced by the Vivado Pipeline
• It creates the binaries that are going to be downloaded in the Zynq
• It creates the packages and the kernel modules that are needed for the root filesystem
What are the different stages in the PetaLinux Pipeline?
• There are 3 different stages: Configuration, Build, Package
• The configuration stage is responsible to generate configuration files for the build process of the
firmware binaries, the bootloaders and the kernel
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 5
PetaLinux Pipeline
Configuration Build Package
.xsa file
BOOT.bin
&
rootfs.tar
Hardware
Description
Firmware
binaries
PetaLinux
rootfs
ROOTFS Generation
What is the role of the ROOTFS Pipeline?
• The ROOTFS Pipeline is responsible for creating the ROOTFS for the Zynq
• The Board Specific ROOTFS, needs the CentOS 8 ROOTFS and some extra PetaLinux tools and kernel modules
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 6
CentOS 8 ROOTFS Pipeline
Docker Image
Creation
Make ROOTFS
Create Container Run Container
• QEMU and Dependencies are installed
• Docker Image is saved on gitlab-registry.cern.ch
• It is independent of the ROOTFS
• It is reused every time the ROOTFS is being built
• A python script runs dnf to install the ROOTFS
CentOS 8
ROOTFS
Board Specific ROOTFS Pipeline
CentOS 8 &
PetaLinux
Make
BSROOTFS
Fetch Copy
PetaLinux
ROOTFS
Maestro Pipeline
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 7
Maestro Pipeline
Trigger
Vivado Pipeline
Vivado
Trigger
PetaLinux Pipeline
PetaLinux
Trigger
Board Specific
ROOTFS Pipeline
ROOTFS
Trigger
Boot Zynq Pipeline
Boot Zynq
Vivado
Pipeline
PetaLinux
Pipeline
Board Specific
ROOTFS Pipeline
Boot
Pipeline
.xsa binaries
Board Specific
ROOTFS
• Data Transfers
• Trigger
• Continuity
CentOS 8
ROOTFS Pipeline
CentOS 8
ROOTFS
PetaLinux
ROOTFS
Testing
Pipeline
Bootstrap
Pipeline
Maestro Pipeline
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 8
Maestro Pipeline
Trigger
Vivado Pipeline
Vivado
Trigger
PetaLinux Pipeline
PetaLinux
Trigger
Board Specific
ROOTFS Pipeline
ROOTFS
Trigger
Boot Zynq Pipeline
Boot Zynq
Vivado
Pipeline
PetaLinux
Pipeline
Board Specific
ROOTFS Pipeline
Boot
Pipeline
.xsa binaries
Board Specific
ROOTFS
• Data Transfers
• Trigger
• Continuity
CentOS 8
ROOTFS Pipeline
CentOS 8
ROOTFS
PetaLinux
ROOTFS
Testing
Pipeline
Bootstrap
Pipeline
Boot Zynq Pipeline
What is the role of the Boot Zynq Pipeline?
• Boot the board and check that the board was booted correctly
How does the CI/CD interface with the board?
• The GitLab Runner initiates a ssh connection to the board’s server that the board is connected to
• The appropriate files are copied from the repository to the board’s server in order to interface with it
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 9
Boot Zynq Pipeline
SSH to
board’s server
Connect
rsync files
Copy
Execute
scripts
Execute
Files:
• Dedicated images (firmware, U-Boot)
used for JTAG boot
• Scripts necessary to boot the board
Booting Procedure - Overview
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 10
pdu.py (pexpect)
jtag_boot.tcl (xsct console)
serial_line.py
execute (ssh to pdu)
execute in parallel
power cycle
Download
binaries
Console
Output
(pexpect)
Redirect Console
Booting Procedure - Zynq
What is the booting procedure and how do we implement the Network boot?
• The booting procedure is triggered from the Boot Zynq pipeline
• The repository of the Boot Zynq pipeline contains JTAG images to prepare the SD-Card
Stage 1: Prepare the SD-Card
• Boot through JTAG with the images and dedicated U-Boot for stage 1.
• During dedicated U-Boot:
• Fetch the final images from the TFTP server that were built in the previous pipelines
• Store these images in the SD-Card
• Change boot-mode through the internal registers (JTAG mode -> SD-Card mode)
• Reset the board (soft reset)
Stage 2: Default boot-mode
• The board starts booting from the SD-Card (firmware, U-Boot) and then continues with network boot:
• Linux Kernel and Device-Tree are downloaded from the TFTP server
• Mount root filesystem over NFS
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 11
DEMO – Scenario 1
Let’s create an error.
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 12
DEMO – Scenario 1 (Result)
Let’s create an error.
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 13
DEMO – Scenario 2
Let’s fix the error.
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 14
DEMO – Scenario 2 (Result)
Let’s fix the error.
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 15
Summary and Future Plans
Summarizing, the CI/CD pipelines:
• Compile the firmware and the software
• Build the root filesystem
• Deploy the images and the root filesystem
• Boot the board and monitor its booting process
The board is ready to be extensively tested! Peripherals and components on the PCB can be tested using
this infrastructure in order to test their functionality.
• Ethernet connectivity
• AXI Chip2Chip communication
• I2C, UART, SPI connectivity
• …
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 16
Merci beaucoup pour votre attention!
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 17
Any Questions?
Contacts:
petr.zejdl(at)cern.ch
marc.dobson(at)cern.ch
vasileios.amoiridis(at)cern.ch
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 18
BACKUP SLIDES
PetaLinux Pipeline
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 19
Silent Configuration
HW Configuration
HW Configuration API
Configuration
FSBL
ARM Trusted Firmware
Device-Tree
U-Boot
Xilinx Linux Kernel
PetaLinux ROOTFS
Build
Compress rootfs
Package
PetaLinux Pipeline
.xsa file
BOOT.bin
&
rootfs.tar
• Only the components
that changed are being
rebuilt (cache memory)
• Runs inside a Docker
Container with
PetaLinux installed
Hardware
Description
Firmware
binaries
&
PetaLinux
rootfs
Manual Trigger
Automatic External Trigger
PMU Firmware
This job runs if there is a
change in the configuration of
the ARM processor (.xsa)
Create Binaries
Extra Scripts
boot.tcl (Using xsct console)
• Connects to the board through JTAG
• Downloads the default binaries and boots the board
pdu.py (using pexpect package)
• Connects to the Power Distribution Unit (PDU) in the lab and power cycles the board
serial_line.py (using pexpect package)
• Reads the serial line output of the board while it is booting
• Prints out to the user the output of the serial line and checks the state of the booting process
• Generates an error if the board stuck during booting
runme.sh
• Runs the previous scripts in the correct order
3-May-2022 V. Amoiridis | SoC Interest Group Meeting 20

More Related Content

Similar to 2022-05-03 SoC Interest Group Meeting - Deploying and testing firmware-software on Zynq MPSoC with GitLab CI-CD pipelines.pdf

Easily emulating full systems on amazon fpg as
Easily emulating full systems on amazon fpg asEasily emulating full systems on amazon fpg as
Easily emulating full systems on amazon fpg as
RISC-V International
 
MikroTik User Guide
MikroTik User GuideMikroTik User Guide
MikroTik User Guide
seolangit4
 
OSDC 2014 ONIE by Nat Morris
OSDC 2014 ONIE by Nat MorrisOSDC 2014 ONIE by Nat Morris
OSDC 2014 ONIE by Nat Morris
Cumulus Networks
 
ONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
ONIE: Open Network Install Environment @ OSDC 2014 Netways, BerlinONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
ONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
Nat Morris
 
Lec 10-linux-review
Lec 10-linux-reviewLec 10-linux-review
Lec 10-linux-review
abinaya m
 
Container & kubernetes
Container & kubernetesContainer & kubernetes
Container & kubernetes
Ted Jung
 
Enable DPDK and SR-IOV for containerized virtual network functions with zun
Enable DPDK and SR-IOV for containerized virtual network functions with zunEnable DPDK and SR-IOV for containerized virtual network functions with zun
Enable DPDK and SR-IOV for containerized virtual network functions with zun
heut2008
 
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Odinot Stanislas
 
Porting Android
Porting AndroidPorting Android
Porting Android
Opersys inc.
 
Using VPP and SRIO-V with Clear Containers
Using VPP and SRIO-V with Clear ContainersUsing VPP and SRIO-V with Clear Containers
Using VPP and SRIO-V with Clear Containers
Michelle Holley
 
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
Qualcomm Developer Network
 
NXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded LinuxNXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded Linux
NEEVEE Technologies
 
Building Embedded Linux UDOONEO
Building Embedded Linux UDOONEOBuilding Embedded Linux UDOONEO
Building Embedded Linux UDOONEO
NEEVEE Technologies
 
”Bare-Metal Container" presented at HPCC2016
”Bare-Metal Container" presented at HPCC2016”Bare-Metal Container" presented at HPCC2016
”Bare-Metal Container" presented at HPCC2016
Kuniyasu Suzaki
 
Deployment of WebObjects applications on FreeBSD
Deployment of WebObjects applications on FreeBSDDeployment of WebObjects applications on FreeBSD
Deployment of WebObjects applications on FreeBSD
WO Community
 
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry PiEmbedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
Ahmed El-Arabawy
 
eBPF Basics
eBPF BasicseBPF Basics
eBPF Basics
Michael Kehoe
 
Linux io introduction-fudcon-2015-with-demo-slides
Linux io introduction-fudcon-2015-with-demo-slidesLinux io introduction-fudcon-2015-with-demo-slides
Linux io introduction-fudcon-2015-with-demo-slides
KASHISH BHATIA
 
Yocto Project Kernel Lab, Hands-On
Yocto Project Kernel Lab, Hands-OnYocto Project Kernel Lab, Hands-On
Yocto Project Kernel Lab, Hands-On
Trevor Woerner
 
CentOS Stream at Facebook
CentOS Stream at FacebookCentOS Stream at Facebook
CentOS Stream at Facebook
Davide Cavalca
 

Similar to 2022-05-03 SoC Interest Group Meeting - Deploying and testing firmware-software on Zynq MPSoC with GitLab CI-CD pipelines.pdf (20)

Easily emulating full systems on amazon fpg as
Easily emulating full systems on amazon fpg asEasily emulating full systems on amazon fpg as
Easily emulating full systems on amazon fpg as
 
MikroTik User Guide
MikroTik User GuideMikroTik User Guide
MikroTik User Guide
 
OSDC 2014 ONIE by Nat Morris
OSDC 2014 ONIE by Nat MorrisOSDC 2014 ONIE by Nat Morris
OSDC 2014 ONIE by Nat Morris
 
ONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
ONIE: Open Network Install Environment @ OSDC 2014 Netways, BerlinONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
ONIE: Open Network Install Environment @ OSDC 2014 Netways, Berlin
 
Lec 10-linux-review
Lec 10-linux-reviewLec 10-linux-review
Lec 10-linux-review
 
Container & kubernetes
Container & kubernetesContainer & kubernetes
Container & kubernetes
 
Enable DPDK and SR-IOV for containerized virtual network functions with zun
Enable DPDK and SR-IOV for containerized virtual network functions with zunEnable DPDK and SR-IOV for containerized virtual network functions with zun
Enable DPDK and SR-IOV for containerized virtual network functions with zun
 
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
 
Porting Android
Porting AndroidPorting Android
Porting Android
 
Using VPP and SRIO-V with Clear Containers
Using VPP and SRIO-V with Clear ContainersUsing VPP and SRIO-V with Clear Containers
Using VPP and SRIO-V with Clear Containers
 
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
Developing for Industrial IoT with Linux OS on DragonBoard™ 410c: Session 1
 
NXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded LinuxNXP IMX6 Processor - Embedded Linux
NXP IMX6 Processor - Embedded Linux
 
Building Embedded Linux UDOONEO
Building Embedded Linux UDOONEOBuilding Embedded Linux UDOONEO
Building Embedded Linux UDOONEO
 
”Bare-Metal Container" presented at HPCC2016
”Bare-Metal Container" presented at HPCC2016”Bare-Metal Container" presented at HPCC2016
”Bare-Metal Container" presented at HPCC2016
 
Deployment of WebObjects applications on FreeBSD
Deployment of WebObjects applications on FreeBSDDeployment of WebObjects applications on FreeBSD
Deployment of WebObjects applications on FreeBSD
 
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry PiEmbedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
Embedded Systems: Lecture 7: Lab 1: Preparing the Raspberry Pi
 
eBPF Basics
eBPF BasicseBPF Basics
eBPF Basics
 
Linux io introduction-fudcon-2015-with-demo-slides
Linux io introduction-fudcon-2015-with-demo-slidesLinux io introduction-fudcon-2015-with-demo-slides
Linux io introduction-fudcon-2015-with-demo-slides
 
Yocto Project Kernel Lab, Hands-On
Yocto Project Kernel Lab, Hands-OnYocto Project Kernel Lab, Hands-On
Yocto Project Kernel Lab, Hands-On
 
CentOS Stream at Facebook
CentOS Stream at FacebookCentOS Stream at Facebook
CentOS Stream at Facebook
 

More from xiso

se01.ppt
se01.pptse01.ppt
se01.ppt
xiso
 
IRDeck_Q322Highlights_FINAL.pdf
IRDeck_Q322Highlights_FINAL.pdfIRDeck_Q322Highlights_FINAL.pdf
IRDeck_Q322Highlights_FINAL.pdf
xiso
 
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdfTechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
xiso
 
Colin-Ian-King-Mentorship-Stress-ng.pdf
Colin-Ian-King-Mentorship-Stress-ng.pdfColin-Ian-King-Mentorship-Stress-ng.pdf
Colin-Ian-King-Mentorship-Stress-ng.pdf
xiso
 
Embedded-Linux-Community-Update-2022-02-JJ78.pdf
Embedded-Linux-Community-Update-2022-02-JJ78.pdfEmbedded-Linux-Community-Update-2022-02-JJ78.pdf
Embedded-Linux-Community-Update-2022-02-JJ78.pdf
xiso
 
slides.pdf
slides.pdfslides.pdf
slides.pdf
xiso
 
introduction.pdf
introduction.pdfintroduction.pdf
introduction.pdf
xiso
 
inside-linux-kernel-rng-presentation-sept-13-2022.pdf
inside-linux-kernel-rng-presentation-sept-13-2022.pdfinside-linux-kernel-rng-presentation-sept-13-2022.pdf
inside-linux-kernel-rng-presentation-sept-13-2022.pdf
xiso
 
Nydus_Image_Service_for_Confidential_Containers.pptx
Nydus_Image_Service_for_Confidential_Containers.pptxNydus_Image_Service_for_Confidential_Containers.pptx
Nydus_Image_Service_for_Confidential_Containers.pptx
xiso
 
murach12.pptx
murach12.pptxmurach12.pptx
murach12.pptx
xiso
 

More from xiso (10)

se01.ppt
se01.pptse01.ppt
se01.ppt
 
IRDeck_Q322Highlights_FINAL.pdf
IRDeck_Q322Highlights_FINAL.pdfIRDeck_Q322Highlights_FINAL.pdf
IRDeck_Q322Highlights_FINAL.pdf
 
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdfTechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
TechTalk5-WhatDoesItTakeToRunLLVMBuildbots.pdf
 
Colin-Ian-King-Mentorship-Stress-ng.pdf
Colin-Ian-King-Mentorship-Stress-ng.pdfColin-Ian-King-Mentorship-Stress-ng.pdf
Colin-Ian-King-Mentorship-Stress-ng.pdf
 
Embedded-Linux-Community-Update-2022-02-JJ78.pdf
Embedded-Linux-Community-Update-2022-02-JJ78.pdfEmbedded-Linux-Community-Update-2022-02-JJ78.pdf
Embedded-Linux-Community-Update-2022-02-JJ78.pdf
 
slides.pdf
slides.pdfslides.pdf
slides.pdf
 
introduction.pdf
introduction.pdfintroduction.pdf
introduction.pdf
 
inside-linux-kernel-rng-presentation-sept-13-2022.pdf
inside-linux-kernel-rng-presentation-sept-13-2022.pdfinside-linux-kernel-rng-presentation-sept-13-2022.pdf
inside-linux-kernel-rng-presentation-sept-13-2022.pdf
 
Nydus_Image_Service_for_Confidential_Containers.pptx
Nydus_Image_Service_for_Confidential_Containers.pptxNydus_Image_Service_for_Confidential_Containers.pptx
Nydus_Image_Service_for_Confidential_Containers.pptx
 
murach12.pptx
murach12.pptxmurach12.pptx
murach12.pptx
 

Recently uploaded

Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Dr.Costas Sachpazis
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
AmarGB2
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
ongomchris
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
zwunae
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
BrazilAccount1
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Sreedhar Chowdam
 
Fundamentals of Electric Drives and its applications.pptx
Fundamentals of Electric Drives and its applications.pptxFundamentals of Electric Drives and its applications.pptx
Fundamentals of Electric Drives and its applications.pptx
manasideore6
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
Massimo Talia
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
Jayaprasanna4
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
weather web application report.pdf
weather web application report.pdfweather web application report.pdf
weather web application report.pdf
Pratik Pawar
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
FluxPrime1
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang,  ICLR 2024, MLILAB, KAIST AI.pdfJ.Yang,  ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
Jayaprasanna4
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
Kamal Acharya
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
TeeVichai
 

Recently uploaded (20)

Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单专业办理
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
 
Fundamentals of Electric Drives and its applications.pptx
Fundamentals of Electric Drives and its applications.pptxFundamentals of Electric Drives and its applications.pptx
Fundamentals of Electric Drives and its applications.pptx
 
Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024Nuclear Power Economics and Structuring 2024
Nuclear Power Economics and Structuring 2024
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
weather web application report.pdf
weather web application report.pdfweather web application report.pdf
weather web application report.pdf
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang,  ICLR 2024, MLILAB, KAIST AI.pdfJ.Yang,  ICLR 2024, MLILAB, KAIST AI.pdf
J.Yang, ICLR 2024, MLILAB, KAIST AI.pdf
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
 
Railway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdfRailway Signalling Principles Edition 3.pdf
Railway Signalling Principles Edition 3.pdf
 

2022-05-03 SoC Interest Group Meeting - Deploying and testing firmware-software on Zynq MPSoC with GitLab CI-CD pipelines.pdf

  • 1. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 1 Vasileios Amoiridis EP-CMD | CMS DAQ group Acknowledgements: P. Žejdl & M. Dobson Deploying and testing firmware/software on Zynq MPSoC with GitLab CI/CD pipelines
  • 2. Workflow for the Zynq MPSoC UltraScale+ • Vivado creates the Hardware Description File which contains the configuration of the ARM processor and its peripherals. This file is used later by PetaLinux. • PetaLinux creates the Firmware Images and the PetaLinux rootfs. The images are used to boot the Zynq and the PetaLinux rootfs is used to create the Board Specific ROOTFS. We use Network Boot: • The images need to be deployed to the SD Card and the TFTP server that are going to be used for booting. The ROOTFS needs to be deployed on the NFS server. • When the board is booting its booting procedure is being monitored. • After the board is booted, it is ready for automated testing! In order to implement all the above steps, GitLab’s CI/CD Pipeline framework is used! 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 2
  • 3. Linux on Zynq MPSoC UltraScale+ 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 3 FSBL PMU-FW U-Boot ATF Bootgen BOOT.bin CentOS 8 aarch64 (CERN repos) Install CentOS 8 using QEMU VM CentOS 8 (rootfs Image) Xilinx Linux Kernel (PetaLinux Package) Build Kernel CentOS 8 rootfs generation Xilinx Linux Kernel Device-Tree (Board specific) ZynqMP tools (PetaLinux rootfs) Bitstream Source of inspiration: Exploration of ZynqUS+ for integrated slow control on Serenity for the CMS Track Trigger (Presentation given by Oliver Sander) Kernel modules Board Specific CentOS 8 rootfs Kernel Image Install rootfs CentOS 8 rootfs w/ ZynqMP support Firmware Integration Image Repo TFTP Server NFS Server SD Card
  • 4. Vivado Pipeline What is the role of the Vivado Pipeline? • It is responsible to produce the Hardware Description File (.xsa) that is used by the PetaLinux Pipeline • The .xsa file is the Hardware Description file. It has the configuration of the ARM processor and its peripherals • The .bit file is the Bitstream file. It configures the Programmable Logic – FPGA. (Optional, i.e additional AXI bus) 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 4 Vivado Pipeline Run Synthesis Run Implementation Generate Bitstream and Hardware Description Synthesis Implementation .bit and .xsa Generation .xsa .bit • Every Vivado project is going under Synthesis and Implementation in a clean environment • Runs inside a Docker Container with Vivado installed Output files
  • 5. PetaLinux Pipeline What is the role of the PetaLinux Pipeline? • It uses the Hardware Description File produced by the Vivado Pipeline • It creates the binaries that are going to be downloaded in the Zynq • It creates the packages and the kernel modules that are needed for the root filesystem What are the different stages in the PetaLinux Pipeline? • There are 3 different stages: Configuration, Build, Package • The configuration stage is responsible to generate configuration files for the build process of the firmware binaries, the bootloaders and the kernel 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 5 PetaLinux Pipeline Configuration Build Package .xsa file BOOT.bin & rootfs.tar Hardware Description Firmware binaries PetaLinux rootfs
  • 6. ROOTFS Generation What is the role of the ROOTFS Pipeline? • The ROOTFS Pipeline is responsible for creating the ROOTFS for the Zynq • The Board Specific ROOTFS, needs the CentOS 8 ROOTFS and some extra PetaLinux tools and kernel modules 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 6 CentOS 8 ROOTFS Pipeline Docker Image Creation Make ROOTFS Create Container Run Container • QEMU and Dependencies are installed • Docker Image is saved on gitlab-registry.cern.ch • It is independent of the ROOTFS • It is reused every time the ROOTFS is being built • A python script runs dnf to install the ROOTFS CentOS 8 ROOTFS Board Specific ROOTFS Pipeline CentOS 8 & PetaLinux Make BSROOTFS Fetch Copy PetaLinux ROOTFS
  • 7. Maestro Pipeline 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 7 Maestro Pipeline Trigger Vivado Pipeline Vivado Trigger PetaLinux Pipeline PetaLinux Trigger Board Specific ROOTFS Pipeline ROOTFS Trigger Boot Zynq Pipeline Boot Zynq Vivado Pipeline PetaLinux Pipeline Board Specific ROOTFS Pipeline Boot Pipeline .xsa binaries Board Specific ROOTFS • Data Transfers • Trigger • Continuity CentOS 8 ROOTFS Pipeline CentOS 8 ROOTFS PetaLinux ROOTFS Testing Pipeline Bootstrap Pipeline
  • 8. Maestro Pipeline 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 8 Maestro Pipeline Trigger Vivado Pipeline Vivado Trigger PetaLinux Pipeline PetaLinux Trigger Board Specific ROOTFS Pipeline ROOTFS Trigger Boot Zynq Pipeline Boot Zynq Vivado Pipeline PetaLinux Pipeline Board Specific ROOTFS Pipeline Boot Pipeline .xsa binaries Board Specific ROOTFS • Data Transfers • Trigger • Continuity CentOS 8 ROOTFS Pipeline CentOS 8 ROOTFS PetaLinux ROOTFS Testing Pipeline Bootstrap Pipeline
  • 9. Boot Zynq Pipeline What is the role of the Boot Zynq Pipeline? • Boot the board and check that the board was booted correctly How does the CI/CD interface with the board? • The GitLab Runner initiates a ssh connection to the board’s server that the board is connected to • The appropriate files are copied from the repository to the board’s server in order to interface with it 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 9 Boot Zynq Pipeline SSH to board’s server Connect rsync files Copy Execute scripts Execute Files: • Dedicated images (firmware, U-Boot) used for JTAG boot • Scripts necessary to boot the board
  • 10. Booting Procedure - Overview 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 10 pdu.py (pexpect) jtag_boot.tcl (xsct console) serial_line.py execute (ssh to pdu) execute in parallel power cycle Download binaries Console Output (pexpect) Redirect Console
  • 11. Booting Procedure - Zynq What is the booting procedure and how do we implement the Network boot? • The booting procedure is triggered from the Boot Zynq pipeline • The repository of the Boot Zynq pipeline contains JTAG images to prepare the SD-Card Stage 1: Prepare the SD-Card • Boot through JTAG with the images and dedicated U-Boot for stage 1. • During dedicated U-Boot: • Fetch the final images from the TFTP server that were built in the previous pipelines • Store these images in the SD-Card • Change boot-mode through the internal registers (JTAG mode -> SD-Card mode) • Reset the board (soft reset) Stage 2: Default boot-mode • The board starts booting from the SD-Card (firmware, U-Boot) and then continues with network boot: • Linux Kernel and Device-Tree are downloaded from the TFTP server • Mount root filesystem over NFS 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 11
  • 12. DEMO – Scenario 1 Let’s create an error. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 12
  • 13. DEMO – Scenario 1 (Result) Let’s create an error. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 13
  • 14. DEMO – Scenario 2 Let’s fix the error. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 14
  • 15. DEMO – Scenario 2 (Result) Let’s fix the error. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 15
  • 16. Summary and Future Plans Summarizing, the CI/CD pipelines: • Compile the firmware and the software • Build the root filesystem • Deploy the images and the root filesystem • Boot the board and monitor its booting process The board is ready to be extensively tested! Peripherals and components on the PCB can be tested using this infrastructure in order to test their functionality. • Ethernet connectivity • AXI Chip2Chip communication • I2C, UART, SPI connectivity • … 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 16
  • 17. Merci beaucoup pour votre attention! 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 17 Any Questions? Contacts: petr.zejdl(at)cern.ch marc.dobson(at)cern.ch vasileios.amoiridis(at)cern.ch
  • 18. 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 18 BACKUP SLIDES
  • 19. PetaLinux Pipeline 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 19 Silent Configuration HW Configuration HW Configuration API Configuration FSBL ARM Trusted Firmware Device-Tree U-Boot Xilinx Linux Kernel PetaLinux ROOTFS Build Compress rootfs Package PetaLinux Pipeline .xsa file BOOT.bin & rootfs.tar • Only the components that changed are being rebuilt (cache memory) • Runs inside a Docker Container with PetaLinux installed Hardware Description Firmware binaries & PetaLinux rootfs Manual Trigger Automatic External Trigger PMU Firmware This job runs if there is a change in the configuration of the ARM processor (.xsa) Create Binaries
  • 20. Extra Scripts boot.tcl (Using xsct console) • Connects to the board through JTAG • Downloads the default binaries and boots the board pdu.py (using pexpect package) • Connects to the Power Distribution Unit (PDU) in the lab and power cycles the board serial_line.py (using pexpect package) • Reads the serial line output of the board while it is booting • Prints out to the user the output of the serial line and checks the state of the booting process • Generates an error if the board stuck during booting runme.sh • Runs the previous scripts in the correct order 3-May-2022 V. Amoiridis | SoC Interest Group Meeting 20