From 2a972212b43100dadbe9c2337264849f3b51552d Mon Sep 17 00:00:00 2001 From: Vladimir Oltean Date: Sat, 30 Aug 2025 20:33:12 +0300 Subject: [PATCH] package/qoriq-restool: new package Introduce a package for the restool program, which permits the user to modify the network configuration of the DPAA2 subsystem and create one that is adequate to their use case. We integrate the master branch, which is effectively the lf-6.12.20-2.0.0 release tag, plus some extra fixups specifically made for the Buildroot integration: - commit b44748ed0bb3 ("Avoid use of non-portable __WORDSIZE when defining BITS_PER_LONG") - commit b4a734f3512b ("restool: fix format string for 64 bit time_t in parse_obj_command()") Signed-off-by: Vladimir Oltean Reviewed-by: Vincent Jardin Signed-off-by: Thomas Petazzoni --- DEVELOPERS | 1 + package/Config.in | 1 + package/qoriq-restool/Config.in | 21 +++++++++++++++++++++ package/qoriq-restool/qoriq-restool.hash | 3 +++ package/qoriq-restool/qoriq-restool.mk | 24 ++++++++++++++++++++++++ 5 files changed, 50 insertions(+) create mode 100644 package/qoriq-restool/Config.in create mode 100644 package/qoriq-restool/qoriq-restool.hash create mode 100644 package/qoriq-restool/qoriq-restool.mk diff --git a/DEVELOPERS b/DEVELOPERS index f448c3b582..62867225eb 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -3405,6 +3405,7 @@ F: package/qoriq-ddr-phy-binary/ F: package/qoriq-firmware-inphi/ F: package/qoriq-mc-binary/ F: package/qoriq-mc-utils/ +F: package/qoriq-restool/ N: Volkov Viacheslav F: package/v4l2grab/ diff --git a/package/Config.in b/package/Config.in index 2b9e31ebb3..f5f1f6a741 100644 --- a/package/Config.in +++ b/package/Config.in @@ -445,6 +445,7 @@ menu "Firmware" source "package/qoriq-fm-ucode/Config.in" source "package/qoriq-mc-binary/Config.in" source "package/qoriq-mc-utils/Config.in" + source "package/qoriq-restool/Config.in" source "package/rcw-smarc-sal28/Config.in" source "package/rpi-firmware/Config.in" source "package/sunxi-boards/Config.in" diff --git a/package/qoriq-restool/Config.in b/package/qoriq-restool/Config.in new file mode 100644 index 0000000000..600c2c958d --- /dev/null +++ b/package/qoriq-restool/Config.in @@ -0,0 +1,21 @@ +config BR2_PACKAGE_QORIQ_RESTOOL + bool "qoriq-restool" + depends on BR2_aarch64 || BR2_aarch64_be + help + The DPAA2 architecture in Layerscape SoCs consists of + networking resources that can be assembled into various + nuggets of functionality, called "objects" (DPMAC, DPNI, + DPDMUX, DPSW etc), by the Management Complex (MC) firmware. + + The MC firmware reads a file called Data Path Layout (DPL) + which describes the set of networking objects it should + create statically, at boot time. + + The restool program is able to talk to the Management + Complex at runtime and permits the dynamic reconfiguration + of networking objects, as well as saving the current + configuration into a new DPL file. Without the restool + program, the only possible networking configuration is + that specified in the boot-time DPL file. + + https://github.com/nxp-qoriq/restool diff --git a/package/qoriq-restool/qoriq-restool.hash b/package/qoriq-restool/qoriq-restool.hash new file mode 100644 index 0000000000..72a34473f2 --- /dev/null +++ b/package/qoriq-restool/qoriq-restool.hash @@ -0,0 +1,3 @@ +# Locally calculated +sha256 2879f14c9dd810e92d4c51c7f1a3e6705a5a585c2445e507f63e39872ac6237d qoriq-restool-lf-6.12.20-2.0.0-3-gb44748e.tar.gz +sha256 ddc794a75f11c3bd01015f16b9776064a894015e7a1603541283ccbc2e1c3a40 LICENSE diff --git a/package/qoriq-restool/qoriq-restool.mk b/package/qoriq-restool/qoriq-restool.mk new file mode 100644 index 0000000000..4dd62a83dd --- /dev/null +++ b/package/qoriq-restool/qoriq-restool.mk @@ -0,0 +1,24 @@ +################################################################################ +# +# qoriq-restool +# +################################################################################ + +QORIQ_RESTOOL_VERSION = lf-6.12.20-2.0.0-3-gb44748e +QORIQ_RESTOOL_SITE = $(call github,nxp-qoriq,restool,$(QORIQ_RESTOOL_VERSION)) +QORIQ_RESTOOL_LICENSE = BSD-3-Clause or GPL-2.0-or-later +QORIQ_RESTOOL_LICENSE_FILES = LICENSE + +define QORIQ_RESTOOL_BUILD_CMDS + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) \ + CC="$(TARGET_CC)" \ + CROSS_COMPILE="$(TARGET_CROSS)" +endef + +define QORIQ_RESTOOL_INSTALL_TARGET_CMDS + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) \ + MANPAGE="" DESTDIR=$(TARGET_DIR) \ + prefix=/usr install +endef + +$(eval $(generic-package))