configs/zynqmp_kria_kr260_defconfig: new defconfig
PATCH v3 1/1 configs/zynqmp_kria_kr260_defconfig: new defconfig
This patch adds support for Xilinx Kria KR260 starter kit.
KR260 features can be found here:
https://www.xilinx.com/products/som/kria/kr260-robotics-starter-kit.html
While the Kria SOM is based on a ZynqMP SoC, there are some key boot config differences from the other ZynqMP evaluation boards.
1. There are no boot switches on Kria SOMs. The boot mode is thus hard configured for QSPI flash. A pre-programmed boot.bin comes with every Starter Kit. U-Boot can then find the Linux kernel and file system on the SD card.
Optional instructions for updating the boot.bin in the QSPI flash can be found in the readme.txt file and the link below.
https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/1641152513/Kria+K26+SOM
2. Kria SOMs use UART1 for the console instead of UART0. For this reason, Kria Starter Kits will use a separate extlinux.conf file from other ZynqMP evaluation boards.
3. The KR260 has a USB to SD card bridge, so the Linux kernel and file system are found on /dev/sda1 and /dev/sda2.
4. The following patches have been submitted upstream for u-boot. They are required for enabling the pinctrl of the tri-state registers, so that u-boot can detect the SD card connected via the USB to SD card bridge on the KR260 carrier board. These patches are temporarily included with buildroot until they have been applied upstream.
http://patchwork.ozlabs.org/project/uboot/list/?series=368369
http://patchwork.ozlabs.org/project/uboot/list/?series=371196
---V1->V2:
- Submitted tri-state patches upstreamV2->V3:
- Formatted upstream patches to remove all of the mail server messages
--- DEVELOPERS | 1 + board/zynqmp/kria/kr260/kr260.sh | 12 + ...-zynqmp-Add-support-to-check-feature.patch | 58 ++ ...ion-check-for-TRISTATE-configuration.patch | 33 ++ ...utput-enable-and-bias-high-impedance.patch | 41 ++ ...ynqmp-Add-output-enable-pins-to-SOMs.patch | 223 ++++++++ board/zynqmp/kria/kr260/pm_cfg_obj.c | 496 ++++++++++++++++++ board/zynqmp/kria/readme.txt | 29 +- configs/zynqmp_kria_kr260_defconfig | 42 ++ 9 files changed, 929 insertions(+), 6 deletions(-) create mode 100755 board/zynqmp/kria/kr260/kr260.sh create mode 100644 board/zynqmp/kria/kr260/patches/uboot/0001-firmware-zynqmp-Add-support-to-check-feature.patch create mode 100644 board/zynqmp/kria/kr260/patches/uboot/0002-pinctrl-zynqmp-Add-version-check-for-TRISTATE-configuration.patch create mode 100644 board/zynqmp/kria/kr260/patches/uboot/0003-pinctrl-zynqmp-Add-support-for-output-enable-and-bias-high-impedance.patch create mode 100644 board/zynqmp/kria/kr260/patches/uboot/0004-arm64-zynqmp-Add-output-enable-pins-to-SOMs.patch create mode 100644 board/zynqmp/kria/kr260/pm_cfg_obj.c create mode 100644 configs/zynqmp_kria_kr260_defconfig
DEVELOPERS +1 -0
@@ -2188,6 +2188,7 @@ F: board/zynq/ F: board/zynqmp/ F: configs/versal_vck190_defconfig F: configs/zynq_zc706_defconfig +F: configs/zynqmp_kria_kr260_defconfig F: configs/zynqmp_kria_kv260_defconfig F: configs/zynqmp_zcu102_defconfig F: configs/zynqmp_zcu106_defconfig
board/zynqmp/kria/kr260/kr260.sh new file +12 -0
@@ -0,0 +1,12 @@ +#!/bin/sh + +# This is a temporary work around for generating kr260 u-boot.itb. +# The problem is there is no way to currently configure u-boot to apply +# the carrier board dtb overlay during build, so all kr260 carrier board +# drivers are missing. +# This will be removed when u-boot can build the kr260 u-boot.itb natively. + +UBOOT_DIR=$4 + +fdtoverlay -o ${UBOOT_DIR}/fit-dtb.blob -i ${UBOOT_DIR}/arch/arm/dts/zynqmp-smk-k26-revA.dtb ${UBOOT_DIR}/arch/arm/dts/zynqmp-sck-kr-g-revB.dtbo +${UBOOT_DIR}/tools/mkimage -E -f ${UBOOT_DIR}/u-boot.its -B 0x8 ${BINARIES_DIR}/u-boot.itb
board/zynqmp/kria/kr260/patches/uboot/0001-firmware-zynqmp-Add-support-to-check-feature.patch new file +58 -0
58 lines not on this page · raw message
board/zynqmp/kria/kr260/patches/uboot/0002-pinctrl-zynqmp-Add-version-check-for-TRISTATE-configuration.patch new file +33 -0
@@ -0,0 +1,33 @@ +From: Ashok Reddy Soma <[email protected]> +Subject: [PATCH 2/3] pinctrl: zynqmp: Add version check for TRISTATE + configuration +Date: Thu, 10 Aug 2023 23:48:28 -0600 + +Support for configuring TRISTATE parameter is added in ZYNQMP PMUFW(Xilinx +ZynqMP Platform Management Firmware) Configuration Param Set version 2.0. +If the requested configuration is TRISTATE then check the version before +requesting Xilinx firmware to set the configuration. + +Signed-off-by: Ashok Reddy Soma <[email protected]> +--- + + drivers/pinctrl/pinctrl-zynqmp.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/drivers/pinctrl/pinctrl-zynqmp.c b/drivers/pinctrl/pinctrl-zynqmp.c +index 02626a7561..e9857f5ed9 100644 +--- a/drivers/pinctrl/pinctrl-zynqmp.c ++++ b/drivers/pinctrl/pinctrl-zynqmp.c +@@ -158,6 +158,12 @@ static int zynqmp_pm_pinctrl_set_config(const u32 pin, const u32 param, u32 valu + { + int ret; + ++ if (param == PM_PINCTRL_CONFIG_TRI_STATE) { ++ ret = zynqmp_pm_feature(PM_PINCTRL_CONFIG_PARAM_SET); ++ if (ret < PM_PINCTRL_PARAM_SET_VERSION) ++ return -EOPNOTSUPP; ++ } ++ + /* Request the pin first */ + ret = xilinx_pm_request(PM_PINCTRL_REQUEST, pin, 0, 0, 0, NULL); + if (ret) {
board/zynqmp/kria/kr260/patches/uboot/0003-pinctrl-zynqmp-Add-support-for-output-enable-and-bias-high-impedance.patch new file +41 -0
41 lines not on this page · raw message
board/zynqmp/kria/kr260/patches/uboot/0004-arm64-zynqmp-Add-output-enable-pins-to-SOMs.patch new file +223 -0
223 lines not on this page · raw message
board/zynqmp/kria/kr260/pm_cfg_obj.c new file +496 -0
496 lines not on this page · raw message
board/zynqmp/kria/readme.txt +23 -6
@@ -3,14 +3,17 @@ Xilinx Kria SOM Starter Kits - ZynqMP SoC ************************************************** This document describes the Buildroot support for the Kria -KV260 starter kit by Xilinx, based on Kria SOM including the +KV260 and KR260 starter kits by Xilinx, based on Kria SOM including the Zynq UltraScale+ MPSoC (aka ZynqMP). It has been tested with -the KV260 production board. +the KV260 and KR260 production boards. -Evaluation board features can be found here with the link below. +Evaluation board features can be found here with the links below. KV260: -https://www.xilinx.com/products/boards-and-kits/kv260.html +https://www.xilinx.com/products/som/kria/kv260-vision-starter-kit.html + +KR260: +https://www.xilinx.com/products/som/kria/kr260-robotics-starter-kit.html How to build it ===============
@@ -65,7 +68,7 @@ in that the boot.bin and u-boot.itb files need to be flashed into the QSPI boot flash such that U-Boot can then load all of the remaining images from the SD card. -In addition, the KV260 Starter Kit QSPI comes pre-flashed with +In addition, the KV260 and KR260 Starter Kits QSPI comes pre-flashed with a utility designed to make updating the QSPI flash memory easier.
@@ -76,8 +79,9 @@ https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/1641152513/Kria+K26+SOM#Bo Additionally, it is possible to use u-boot for updating the QSPI with new boot.bin and u-boot.itb images with the u-boot -commands below: +commands below. +KV260 Flashing Instructions: Flashing u-boot.itb: $ sf probe $ fatload mmc 1 0x1000000 u-boot.itb
@@ -90,5 +94,18 @@ Flashing boot.bin: $ sf erase 0x200000 +$filesize $ sf write 0x1000000 0x200000 $filesize +KR260 Flashing Instructions: +Flashing u-boot.itb: + $ sf probe + $ fatload usb 0 0x1000000 u-boot.itb + $ sf erase 0xf80000 +$filesize + $ sf write 0x1000000 0xf80000 $filesize + +Flashing boot.bin: + $ sf probe + $ fatload usb 0 0x1000000 boot.bin + $ sf erase 0x200000 +$filesize + $ sf write 0x1000000 0x200000 $filesize + It is possible to boot the Buildroot generated SD card image without updating the QSPI boot.bin image, so this is an optional step.
configs/zynqmp_kria_kr260_defconfig new file +42 -0
42 lines not on this page · raw message
Signature · 6 lines
2.25.1 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Hi Neal,
Quoted 13 lines · On Sun, 3 Sep 2023 08:54:27 +0100 Neal Frager <[email protected]> wrote:
This patch adds support for Xilinx Kria KR260 starter kit.
KR260 features can be found here:
https://www.xilinx.com/products/som/kria/kr260-robotics-starter-kit.htmlWhile the Kria SOM is based on a ZynqMP SoC, there are some key boot config differences from the other ZynqMP evaluation boards.
1. There are no boot switches on Kria SOMs. The boot mode is thus hard configured for QSPI flash. A pre-programmed boot.bin comes with every Starter Kit. U-Boot can then find the Linux kernel and file system on the SD card.
Quoted 8 lines
Optional instructions for updating the boot.bin in the QSPI flash can be found in the readme.txt file and the link below.
https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/1641152513/Kria+K26+SOM
2. Kria SOMs use UART1 for the console instead of UART0. For this reason, Kria Starter Kits will use a separate extlinux.conf file from other ZynqMP evaluation boards.
The above 2 items are the same as the KV260, right?
Quoted 9 lines
3. The KR260 has a USB to SD card bridge, so the Linux kernel and file system are found on
/dev/sda1and/dev/sda2.4. The following patches have been submitted upstream for u-boot. They are required for enabling the pinctrl of the tri-state registers, so that u-boot can detect the SD card connected via the USB to SD card bridge on the KR260 carrier board. These patches are temporarily included with buildroot until they have been applied upstream.
Quoted 4 lines
http://patchwork.ozlabs.org/project/uboot/list/?series=368369
http://patchwork.ozlabs.org/project/uboot/list/?series=371196Signed-off-by Neal Frager <[email protected]>
Luca
Signature · 7 lines
Luca Ceresoli, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Hi Luca,
Quoted 17 lines
This patch adds support for Xilinx Kria KR260 starter kit.
KR260 features can be found here:
https://www.xilinx.com/products/som/kria/kr260-robotics-starter-kit.ht
mlWhile the Kria SOM is based on a ZynqMP SoC, there are some key boot config differences from the other ZynqMP evaluation boards.
1. There are no boot switches on Kria SOMs. The boot mode is thus hard configured for QSPI flash. A pre-programmed boot.bin comes with every Starter Kit. U-Boot can then find the Linux kernel and file system on the SD card.
Optional instructions for updating the boot.bin in the QSPI flash can be found in the readme.txt file and the link below.
Quoted 8 lines
https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/1641152513/Kria+
K26+SOM2. Kria SOMs use UART1 for the console instead of UART0. For this reason, Kria Starter Kits will use a separate extlinux.conf file from other ZynqMP evaluation boards.
The above 2 items are the same as the KV260, right?
Yes indeed. 1 and 2 apply to all Kria starter kits.
Quoted 12 lines
3. The KR260 has a USB to SD card bridge, so the Linux kernel and file system are found on
/dev/sda1and/dev/sda2.4. The following patches have been submitted upstream for u-boot. They are required for enabling the pinctrl of the tri-state registers, so that u-boot can detect the SD card connected via the USB to SD card bridge on the KR260 carrier board. These patches are temporarily included with buildroot until they have been applied upstream.
http://patchwork.ozlabs.org/project/uboot/list/?series=368369
http://patchwork.ozlabs.org/project/uboot/list/?series=371196
3 and 4 are specific to the KR260.
Quoted 5 lines
Signed-off-by Neal Frager <[email protected]>Reviewed-by Luca Ceresoli <[email protected]>Luca
Best regards,
Neal Frager
AMD
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot