Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port the Yocto labs to Scarthgap #255

Merged
merged 22 commits into from
Nov 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
1978e7d
labs: yocto: stm32: update lab1 to scarthgap
antznin Oct 1, 2024
a1c16fb
labs: yocto: stm32: update lab2 to scarthgap
antznin Oct 2, 2024
c882b2a
slides: yocto: change example branch to scarthgap
antznin Oct 2, 2024
27eee7e
labs: yocto: stm32: update lab5 to scarthgap
antznin Oct 2, 2024
81aab8c
lab-data: yocto: stm32: udpate defconfig for 6.1 kernel
antznin Oct 4, 2024
94a6a20
labs: yocto: stm32: update lab6 to scarthgap
antznin Oct 4, 2024
dc807b6
labs: yocto: stm32: update lab8 to scarthgap
antznin Oct 4, 2024
d1af84d
labs: yocto: update lab9 to scarthgap
antznin Oct 14, 2024
2a84762
labs: yocto: beagleplay: update lab1 to scarthgap
antznin Oct 18, 2024
2b00532
labs: yocto: beagleplay: update lab2 to scarthgap
antznin Oct 18, 2024
3d1c2f2
labs: yocto: beagleplay: update lab5 to scarthgap
antznin Oct 18, 2024
cafcebc
labs: yocto: beagleplay: update lab6 to scarthgap
antznin Oct 18, 2024
0b87132
labs: yocto: beagleplay: update lab8 to scarthgap
antznin Oct 18, 2024
b1cb8ab
labs: yocto: beaglebone: update lab1 to scarthgap
antznin Oct 18, 2024
9b4fdd7
labs: yocto: beaglebone: update lab2 to scarthgap
antznin Oct 18, 2024
497516c
labs: yocto: beaglebone: update lab5 to scarthgap
antznin Oct 18, 2024
227cb23
labs: yocto: beaglebone: update lab6 to scarthgap
antznin Oct 18, 2024
e102eaa
labs: yocto: beaglebone: update lab8 to scarthgap
antznin Oct 18, 2024
177e9b9
slides: yocto: update kirkstone references to scarthgap
antznin Nov 13, 2024
5bc9424
slides: yocto: move to the classes-recipe/classes-global naming
antznin Nov 13, 2024
82114e4
labs: yocto: beagleplay: lab1: add a patch to enable uboot env saving
antznin Nov 13, 2024
78b94fb
labs: yocto: stm32: lab1: add note on setting username and email
antznin Nov 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
From 4169b7ca42f50a110250763362add21c1434bd0d Mon Sep 17 00:00:00 2001
From: Antonin Godard <[email protected]>
Date: Tue, 29 Oct 2024 09:13:06 +0100
Subject: [PATCH 2/3] Don't use a custom deployment directory

Using custom deployment directory is not following the standards. Revert
this change by meta-ti to give the good example to trainees.

Keep the definition of TI_COMMON_DEPLOY as it may be used by other
recipes.

Also, remove the change to TMPDIR done in the machine configuration, to
keep the temporary directory unified and avoid an error caused by the
change above.

Signed-off-by: Antonin Godard <[email protected]>
---
meta-ti-bsp/conf/layer.conf | 8 ++++----
meta-ti-bsp/conf/multiconfig/k3r5.conf | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/meta-ti-bsp/conf/layer.conf b/meta-ti-bsp/conf/layer.conf
index 462bf763..f632e8a1 100644
--- a/meta-ti-bsp/conf/layer.conf
+++ b/meta-ti-bsp/conf/layer.conf
@@ -28,7 +28,7 @@ SIGGEN_EXCLUDERECIPES_ABISAFE += " \

HOSTTOOLS_NONFATAL += "truncate xxd comm"

-TI_COMMON_DEPLOY ?= "${TOPDIR}/deploy-ti"
-DEPLOY_DIR_IMAGE:ti-soc = "${TI_COMMON_DEPLOY}/images/${MACHINE}"
-SDK_DEPLOY:ti-soc = "${TI_COMMON_DEPLOY}/sdk"
-PSEUDO_IGNORE_PATHS:append:ti-soc = ",${TI_COMMON_DEPLOY}"
+TI_COMMON_DEPLOY ?= "${DEPLOY_DIR}"
+# DEPLOY_DIR_IMAGE:ti-soc = "${TI_COMMON_DEPLOY}/images/${MACHINE}"
+# SDK_DEPLOY:ti-soc = "${TI_COMMON_DEPLOY}/sdk"
+# PSEUDO_IGNORE_PATHS:append:ti-soc = ",${TI_COMMON_DEPLOY}"
diff --git a/meta-ti-bsp/conf/multiconfig/k3r5.conf b/meta-ti-bsp/conf/multiconfig/k3r5.conf
index 936bce2f..0e1e4056 100644
--- a/meta-ti-bsp/conf/multiconfig/k3r5.conf
+++ b/meta-ti-bsp/conf/multiconfig/k3r5.conf
@@ -5,6 +5,6 @@ DEPLOY_DIR_IMAGE:k3r5 = "${TI_COMMON_DEPLOY}/images/${MAINMACHINE}"
MACHINE:append = "-k3r5"
TCLIBC = "baremetal"
TI_TMPDIR_APPEND ?= "-k3r5"
-TMPDIR:append = "${TI_TMPDIR_APPEND}"
+# TMPDIR:append = "${TI_TMPDIR_APPEND}"

SDKPKGSUFFIX = "k3r5-nativesdk"
--
2.46.1

Original file line number Diff line number Diff line change
@@ -1,31 +1,32 @@
From f8a4903a9a72275848d64c8e03d22f4880644db8 Mon Sep 17 00:00:00 2001
From: Jeremie Dautheribes <jdautheribes@build3.bootlin.com>
Date: Thu, 20 Jun 2024 07:00:23 +0200
Subject: [PATCH] Use extlinux.conf booting flow
From 6183d521239c18a0963757772aa52ec99f968bfa Mon Sep 17 00:00:00 2001
From: Antonin Godard <antonin.godard@bootlin.com>
Date: Tue, 29 Oct 2024 09:13:30 +0100
Subject: [PATCH 3/3] Use extlinux.conf booting flow

Switch from the default EFI-based boot process to a well-known
extlinux.conf boot flow.

This change is coherent with our other supported boards and
simplifies the labs significantly (which are therefore very similar
to those for the other boards). Moreover, I had trouble establishing
a stable Ethernet connection through the EFI-based flow.
This change is coherent with our other supported boards and simplifies
the labs significantly (which are therefore very similar to those for
the other boards). Moreover, I had trouble establishing a stable
Ethernet connection through the EFI-based flow.

Signed-off-by: Jeremie Dautheribes <[email protected]>
Signed-off-by: Antonin Godard <[email protected]>
---
meta-ti-bsp/conf/machine/beagleplay.conf | 3 ++-
meta-ti-bsp/conf/machine/include/extlinux-bb.inc | 9 +++++++++
2 files changed, 11 insertions(+), 1 deletion(-)
create mode 100644 meta-ti-bsp/conf/machine/include/extlinux-bb.inc

diff --git a/meta-ti-bsp/conf/machine/beagleplay.conf b/meta-ti-bsp/conf/machine/beagleplay.conf
index 9ea7ff75..fb9e7f9e 100644
index c5ce3902..0057e987 100644
--- a/meta-ti-bsp/conf/machine/beagleplay.conf
+++ b/meta-ti-bsp/conf/machine/beagleplay.conf
@@ -3,8 +3,9 @@
#@DESCRIPTION: Machine configuration for the BeaglePlay board (A53 core)

@@ -5,8 +5,9 @@
require conf/machine/include/k3.inc
require conf/machine/include/mc_k3r5.inc

-SOC_FAMILY:append = ":am62xx"
+require conf/machine/include/extlinux-bb.inc

Expand All @@ -49,5 +50,5 @@ index 00000000..02863fc2
+MACHINE_ESSENTIAL_EXTRA_RDEPENDS:append = " kernel-modules"
+
--
2.25.1
2.46.1

Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
From ec95a0130c23f498ef08f7226512ce596ecec604 Mon Sep 17 00:00:00 2001
From: Antonin Godard <[email protected]>
Date: Wed, 13 Nov 2024 13:48:41 +0100
Subject: [PATCH] u-boot: enable saving the env in fat partition

This is not enabled by default on the Beagleplay. Actually, CMD_SAVEENV
is defined but we only have ENV_IS_NOWHERE set so U-boot disables
saveenv. So this patch does the following:

- Set CONFIG_ENV_IS_IN_FAT and related variables.
- Unset CONFIG_ENV_IS_NOWHERE so that when U-boot fails to read the
file uboot.env on initial boot (the file is not present yet), it
doesn't fail to "save to nowhere" and save the env to uboot.env
instead.

Signed-off-by: Antonin Godard <[email protected]>
---
.../recipes-bsp/u-boot/u-boot-ti-staging/env-in-fat.cfg | 7 +++++++
.../recipes-bsp/u-boot/u-boot-ti-staging_2024.04.bb | 2 ++
2 files changed, 9 insertions(+)
create mode 100644 meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging/env-in-fat.cfg

diff --git a/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging/env-in-fat.cfg b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging/env-in-fat.cfg
new file mode 100644
index 00000000..a22b7db6
--- /dev/null
+++ b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging/env-in-fat.cfg
@@ -0,0 +1,7 @@
+CONFIG_ENV_IS_IN_FAT=y
+CONFIG_ENV_FAT_INTERFACE="mmc"
+CONFIG_ENV_FAT_DEVICE_AND_PART="1:1"
+CONFIG_ENV_FAT_FILE="uboot.env"
+CONFIG_SYS_MMC_ENV_DEV=0
+CONFIG_SYS_MMC_ENV_PART=0
+# CONFIG_ENV_IS_NOWHERE is not set
diff --git a/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging_2024.04.bb b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging_2024.04.bb
index e3e86b30..1740aa8b 100644
--- a/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging_2024.04.bb
+++ b/meta-ti-bsp/recipes-bsp/u-boot/u-boot-ti-staging_2024.04.bb
@@ -7,3 +7,5 @@ PR = "r0"
BRANCH = "ti-u-boot-2024.04"

SRCREV = "cdac8b4cd3cc1d1e9ac6354c1cfe03ddbbdf01fa"
+
+SRC_URI += "file://env-in-fat.cfg"
--
2.46.1

Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
From f7f9d4f5b2f271c5af407bfdaa55c0215d552b16 Mon Sep 17 00:00:00 2001
From 1e9526005c80e0d57c2589441e95d6494707c268 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Dautheribes?=
<[email protected]>
Date: Mon, 1 Jul 2024 13:54:33 +0000
Subject: [PATCH] Add nunchuk driver
Subject: [PATCH 1/2] Add nunchuk driver
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Jérémie Dautheribes <[email protected]>
Signed-off-by: Antonin Godard <[email protected]>
---
drivers/input/joystick/Kconfig | 13 ++
drivers/input/joystick/Makefile | 1 +
Expand All @@ -16,10 +17,10 @@ Signed-off-by: Jérémie Dautheribes <[email protected]>
create mode 100644 drivers/input/joystick/wiichuck.c

diff --git a/drivers/input/joystick/Kconfig b/drivers/input/joystick/Kconfig
index b080f0cfb068..e28371e399d2 100644
index ac6925ce8366..e155f724b789 100644
--- a/drivers/input/joystick/Kconfig
+++ b/drivers/input/joystick/Kconfig
@@ -205,6 +205,19 @@ config JOYSTICK_TWIDJOY
@@ -207,6 +207,19 @@ config JOYSTICK_TWIDJOY
To compile this driver as a module, choose M here: the
module will be called twidjoy.

Expand All @@ -40,20 +41,19 @@ index b080f0cfb068..e28371e399d2 100644
tristate "5-byte Zhenhua RC transmitter"
select SERIO
diff --git a/drivers/input/joystick/Makefile b/drivers/input/joystick/Makefile
index 58232b3057d3..c3991d71aa6e 100644
index 3937535f0098..7dee2e46303d 100644
--- a/drivers/input/joystick/Makefile
+++ b/drivers/input/joystick/Makefile
@@ -35,6 +35,7 @@ obj-$(CONFIG_JOYSTICK_TURBOGRAFX) += turbografx.o
@@ -38,5 +38,6 @@ obj-$(CONFIG_JOYSTICK_TURBOGRAFX) += turbografx.o
obj-$(CONFIG_JOYSTICK_TWIDJOY) += twidjoy.o
obj-$(CONFIG_JOYSTICK_WARRIOR) += warrior.o
obj-$(CONFIG_JOYSTICK_WALKERA0701) += walkera0701.o
+obj-$(CONFIG_JOYSTICK_WIICHUCK) += wiichuck.o
obj-$(CONFIG_JOYSTICK_XPAD) += xpad.o
obj-$(CONFIG_JOYSTICK_ZHENHUA) += zhenhua.o

diff --git a/drivers/input/joystick/wiichuck.c b/drivers/input/joystick/wiichuck.c
new file mode 100644
index 000000000000..50757fcdc3c8
index 000000000000..e20f2c7c25e3
--- /dev/null
+++ b/drivers/input/joystick/wiichuck.c
@@ -0,0 +1,204 @@
Expand Down Expand Up @@ -255,12 +255,12 @@ index 000000000000..50757fcdc3c8
+ .name = "nunchuk",
+ .of_match_table = nunchuk_dt_match,
+ },
+ .probe_new = nunchuk_probe,
+ .probe = nunchuk_probe,
+ .remove = nunchuk_remove,
+};
+module_i2c_driver(nunchuk_driver);
+
+MODULE_LICENSE("GPL");
--
2.34.1
2.46.1

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 0d8c85be0bdf9f96d25f74e91eea11255177732e Mon Sep 17 00:00:00 2001
From df724a0c5c07a2cf4a754059eaa3117ec70d8606 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9r=C3=A9mie=20Dautheribes?=
<[email protected]>
Date: Wed, 26 Jun 2024 12:35:43 +0000
Expand All @@ -11,42 +11,32 @@ Content-Transfer-Encoding: 8bit
mikrobus needs to be disabled

Signed-off-by: Jérémie Dautheribes <[email protected]>
Signed-off-by: Antonin Godard <[email protected]>
---
arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts b/arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts
index d779fd110d4a..bac06eca433c 100644
index 89cb616e1d1f..1b9c7b91562f 100644
--- a/arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts
+++ b/arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts
@@ -282,6 +282,7 @@ cpsw3g_phy1: ethernet-phy@1 {
};

mikrobus0: linux-mikrobus {
+ status = "disabled";
compatible = "linux,mikrobus";
pinctrl-names = "default", "pwm_default", "pwm_gpio",
"uart_default", "uart_gpio", "i2c_default",
@@ -1055,7 +1056,18 @@ it66121hdmitx_out: endpoint {

@@ -828,8 +828,15 @@ it66121_out: endpoint {
&main_i2c3 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&mikrobus_i2c_pins_default>;
- clock-frequency = <400000>;
+ clock-frequency = <100000>;
+
lucaceresoli marked this conversation as resolved.
Show resolved Hide resolved
+ pinctrl-names = "default";
+ pinctrl-0 = <&mikrobus_i2c_pins_default>;
status = "okay";
+
+ symlink = "play/mikrobus/i2c";
+
+ nunchuk: joystick@52 {
+ compatible = "nintendo,nunchuk";
+ reg = <0x52>;
+ };
+
};

&mailbox0_cluster0 {
&main_spi2 {
--
2.34.1
2.46.1

Loading
Loading