From patchwork Mon Aug 19 07:41:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Patrick Barsanti X-Patchwork-Id: 3322 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-lj1-f200.google.com (mail-lj1-f200.google.com [209.85.208.200]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 2427D3F1F3 for ; Mon, 19 Aug 2024 09:42:37 +0200 (CEST) Received: by mail-lj1-f200.google.com with SMTP id 38308e7fff4ca-2ef23a67c5bsf34435911fa.3 for ; Mon, 19 Aug 2024 00:42:37 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1724053356; cv=pass; d=google.com; s=arc-20160816; b=M9RA0rDXTE8SE3MZvbAhglUbMdBYdxnIyctSHD3h+1ObHEek12FBheNcUsNMb5VZCo EKZvYKTpKc73wYQDZ6iimJ5RdIfUsdMDYrW46YYcGXjS7sPdFzsl2W+k6cJcNaXMY0wm NoMvrcDEoEbRjNkykLugh97Eiwz5J3Rnw+2bofzncO4fbreBLwsAIwOX8u9AvLmGRVJR JM2mz40oqgX/pGHUsjLZLCQvgbT7v6PbxqmW13nD7cr51iEyj2oP5JLWmVvrU5wliTTI WHlVXw+EyR00sDlSE4vnzbmSwYmPpqdaJIPiWKdW8bjkKZam6gteKjtyVIVrmn9jhXyn DWIA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=XAXlr3+xwZ+lfQ+Npx9/ma9XLfV/rDIe1dMvxGr0PFY=; fh=L+/Feclr5KPb0qzNxo+t/kOe17gvwTMIaDlExnMjcCM=; b=CuAdPgdKD2V1sPwFMY/aNkZ2ZPUXtWg+/5SwRL6BR+iT1LhGezW5ndVqpkQV5DHHTC ahxRBO0Uw9Mf5DehQ1Pm4AQk/Z3rt6cWmfBO/i+YFHaKjGNOIbW369E7HO7HoNawifgf mCaV7YKpcnZTsglF67Vk7xAIPaDAaJFkQtN8lGhKcQQd8N/x+hNNTn5A99+VcSI1+hXx /aagnAI8dQ4BeFAle18URTglJalw8pl4GY50xI7iEPTsX6J+IJ844IERndIhVFN6j9oD VTkb8dQhkzA/LPGm+88O+ZR8IR2NacxdGLZiVlZwm4g97qUbSnQfR1fIRLezPfhYh/Cr Le3w==; darn=patchwork.amarulasolutions.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ABMYH27O; spf=pass (google.com: domain of patrick.barsanti@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=patrick.barsanti@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1724053356; x=1724658156; darn=patchwork.amarulasolutions.com; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=XAXlr3+xwZ+lfQ+Npx9/ma9XLfV/rDIe1dMvxGr0PFY=; b=AMJ/9B3S7pA/QO6AM332/t8/1GaBoutvvZ6G1Hq03w2uuBUpLKHNtcphdU6PShUjJE EIwHOdMby0cw1NWVpcCOfd+/rzX9+4pxY/+zHPBqFry1lVKsoQKElpSTjlWr8vgxOB0e +ZTgOafOS7L4gveAgvejtfgDA0Gk62aXSapA8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724053356; x=1724658156; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :x-beenthere:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=XAXlr3+xwZ+lfQ+Npx9/ma9XLfV/rDIe1dMvxGr0PFY=; b=VlL0LOJTX+fFp3eRRXWTvc5KSivN9BTOxoOGB2saL+fuR5q2cn+6BdZ4hQPBvgVEF2 ur04hhQo138O3h0mbtoqdppLiGAcEug3rmuclNbT/nHJURpA8hcfLP5aH1pdIMheszVV zug1nmmlPUnTSU6Jv8qx9UKOsvPUp0TEuGOCbC/rP64DX1FH32s7l/sddFsKIgsz5EU0 bmleTNHVuzKLNGi6meDrCkyQ4p8BbcGt9fnP+tcI03RSjon+XM0Ij27u4upIrGibXKgK qOjjEny/WDmGaPZVqx1HTRgY4iUevZq19jnpvXI5hHkYb1ILK/dI7NJsQuOwMSoj0s0M yTJA== X-Forwarded-Encrypted: i=2; AJvYcCWH50MS9FxqDA4XO7S9KC5s+Q8CTy4XE0mYuPVFsfJ14jFAPg6InZr6+aG4SjvWc1etpgldTFF9/GsmJrys@patchwork.amarulasolutions.com X-Gm-Message-State: AOJu0YyOumkIiJy24EJ616S5+ncwlzr1kLYmKbFfGFzuVErIrSglNP5w Eg1aNOgW6nCkXxs9sO7p4Dq6/oOewh3WQeK40X7MT6eThLzYc+Fh1KdKoTYrVKmmgw== X-Google-Smtp-Source: AGHT+IES2OxFPIP6kqv/Rn3cZgcwi738wRYusR/Oghk0bR9pEXhcROloJzbEQuwD1Fqu+iu/mznYUQ== X-Received: by 2002:a2e:a456:0:b0:2ef:290e:5b47 with SMTP id 38308e7fff4ca-2f3be585aa9mr63628521fa.15.1724053355951; Mon, 19 Aug 2024 00:42:35 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6402:26c6:b0:5be:ef89:e7a6 with SMTP id 4fb4d7f45d1cf-5beef89ee84ls462757a12.2.-pod-prod-04-eu; Mon, 19 Aug 2024 00:42:34 -0700 (PDT) X-Received: by 2002:a17:907:d58c:b0:a7a:c256:3cc with SMTP id a640c23a62f3a-a8392a4c520mr670694866b.67.1724053354256; Mon, 19 Aug 2024 00:42:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1724053354; cv=none; d=google.com; s=arc-20160816; b=dln4cpYhtRmft2zDEWPGnldMBX6fwG84BdHXUreuHZ0NzLuzXR6DAQiDNm1sU7QChj yyVxqn5pP+lGUQ2ZnTCpmF+9YH79il4naQbhuH/4TPnxCjo+1SK+CHSkTXKNYqquMQ/S WAMRuz4HGysDlnLA4hOC5XYoxrMua9FkSc4CcJYtp76IRqVlSrUcFlrb8f8FwNym9p9Z q9E3bH1vmWe3yOHF7aDTClcSbFggQej3WV24cPZ2PAWYWkzsUjWiw4gvojvrI02uHtQL mLf/mywGMLL2JBpYtolRKgt+kK5XRhGLzYVZg68CA2AdtcZTVrGicvJC9pdQNh6tGzbm h8ZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=syLnBzafuVKnhstxCYcGAmKddsE1KzpOP71iaEMfbEk=; fh=u9hQ0FYhgFaRYZt60LMCTuHprfvTVd18Zbk+lSMUPZs=; b=i1Q656oUYlycAmXfbvGT9evL6WQ1+cpavchqs88wZvOA5r+JbdOaGqcmzm7peFtrR9 u98QdKd30P5aH+2NU34212jd3B7vxontX6hPCcPJjjz/XBXbURGyQzV+qmEFqQHV2U3v 2Zzbsu9gbyX1cMG5p3FZ5ZJspWVRyEOft9D6UXg+Y4DAHsEqVH4EbQTrFsZF3Dn8OM44 EBWYS26W47FGm27eZxwSBLHsbgxh37or1Urmu8eQf7kOoK8LKZN0TBTwFIqi25u7zmlE YFNL1b80GOkCqZhenP0V3m4DNV+T5lmogXotFj8rMWtI3rpD7l7RYLZu2Lgw7loDAeXh luXQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ABMYH27O; spf=pass (google.com: domain of patrick.barsanti@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=patrick.barsanti@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id a640c23a62f3a-a838393b88esor215267066b.16.2024.08.19.00.42.34 for (Google Transport Security); Mon, 19 Aug 2024 00:42:34 -0700 (PDT) Received-SPF: pass (google.com: domain of patrick.barsanti@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:a17:907:9488:b0:a80:f840:9004 with SMTP id a640c23a62f3a-a83928a646cmr807179166b.12.1724053353456; Mon, 19 Aug 2024 00:42:33 -0700 (PDT) Received: from localhost.localdomain (i116103.upc-i.chello.nl. [62.195.116.103]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a83838c68f2sm598333966b.2.2024.08.19.00.42.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Aug 2024 00:42:33 -0700 (PDT) From: Patrick Barsanti To: linux-amarula@amarulasolutions.com Cc: michael@amarulasolutions.com, adam.duskett@amarulasolutions.com, Patrick Barsanti Subject: [PATCH 2/6] rtla: Revert Makefile changes for rtla Date: Mon, 19 Aug 2024 09:41:58 +0200 Message-ID: <20240819074202.34144-3-patrick.barsanti@amarulasolutions.com> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20240819074202.34144-1-patrick.barsanti@amarulasolutions.com> References: <20240819074202.34144-1-patrick.barsanti@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: patrick.barsanti@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ABMYH27O; spf=pass (google.com: domain of patrick.barsanti@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=patrick.barsanti@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , With this specific linux upstream commit, the building process for rtla is broken inside Yocto: | Auto-detecting system features: | ... libtraceevent: [ on ] | ... libtracefs: [ OFF ] | | libtracefs is missing. Please install libtracefs-dev/libtracefs-devel Since it is working correctly with linux-yocto_6.6%, and after confirming this commit is in fact the only cause of incorrect behaviour, add a patch to revert it. Signed-off-by: Patrick Barsanti --- ...a-Use-tools-build-makefiles-to-build.patch | 414 ++++++++++++++++++ meta/recipes-kernel/linux/linux-yocto_6.10.bb | 3 +- 2 files changed, 416 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-kernel/linux/files/0001-Revert-tools-rtla-Use-tools-build-makefiles-to-build.patch diff --git a/meta/recipes-kernel/linux/files/0001-Revert-tools-rtla-Use-tools-build-makefiles-to-build.patch b/meta/recipes-kernel/linux/files/0001-Revert-tools-rtla-Use-tools-build-makefiles-to-build.patch new file mode 100644 index 0000000000..0578730e7f --- /dev/null +++ b/meta/recipes-kernel/linux/files/0001-Revert-tools-rtla-Use-tools-build-makefiles-to-build.patch @@ -0,0 +1,414 @@ +From a3d719bdd9fb6b787d7098004e2bf588a2dd67c6 Mon Sep 17 00:00:00 2001 +From: Patrick Barsanti +Date: Fri, 16 Aug 2024 18:05:58 +0200 +Subject: [PATCH] Revert "tools/rtla: Use tools/build makefiles to build rtla" + +This reverts commit 01474dc706cabbdaab600a46a107220ac5de9386. + +Upstream-Status: Pending +Signed-Off-By: Patrick Barsanti +--- + tools/tracing/rtla/.gitignore | 7 +- + tools/tracing/rtla/Build | 1 - + tools/tracing/rtla/Makefile | 217 ++++++++++++++++--------- + tools/tracing/rtla/Makefile.rtla | 80 --------- + tools/tracing/rtla/Makefile.standalone | 26 --- + tools/tracing/rtla/src/Build | 11 -- + 6 files changed, 145 insertions(+), 197 deletions(-) + delete mode 100644 tools/tracing/rtla/Build + delete mode 100644 tools/tracing/rtla/Makefile.rtla + delete mode 100644 tools/tracing/rtla/Makefile.standalone + delete mode 100644 tools/tracing/rtla/src/Build + +diff --git a/tools/tracing/rtla/.gitignore b/tools/tracing/rtla/.gitignore +index 293f0dbb0ca2..e9df32419b2b 100644 +--- a/tools/tracing/rtla/.gitignore ++++ b/tools/tracing/rtla/.gitignore +@@ -1,6 +1 @@ +-# SPDX-License-Identifier: GPL-2.0-only +-rtla +-rtla-static +-fixdep +-feature +-FEATURE-DUMP ++/rtla +diff --git a/tools/tracing/rtla/Build b/tools/tracing/rtla/Build +deleted file mode 100644 +index 6c9d5b36a315..000000000000 +--- a/tools/tracing/rtla/Build ++++ /dev/null +@@ -1 +0,0 @@ +-rtla-y += src/ +diff --git a/tools/tracing/rtla/Makefile b/tools/tracing/rtla/Makefile +index b5878be36125..afd18c678ff5 100644 +--- a/tools/tracing/rtla/Makefile ++++ b/tools/tracing/rtla/Makefile +@@ -1,86 +1,157 @@ +-# SPDX-License-Identifier: GPL-2.0-only +- +-ifeq ($(srctree),) +- srctree := $(patsubst %/,%,$(dir $(CURDIR))) +- srctree := $(patsubst %/,%,$(dir $(srctree))) +- srctree := $(patsubst %/,%,$(dir $(srctree))) ++NAME := rtla ++# Follow the kernel version ++VERSION := $(shell cat VERSION 2> /dev/null || make -sC ../../.. kernelversion | grep -v make) ++ ++# From libtracefs: ++# Makefiles suck: This macro sets a default value of $(2) for the ++# variable named by $(1), unless the variable has been set by ++# environment or command line. This is necessary for CC and AR ++# because make sets default values, so the simpler ?= approach ++# won't work as expected. ++define allow-override ++ $(if $(or $(findstring environment,$(origin $(1))),\ ++ $(findstring command line,$(origin $(1)))),,\ ++ $(eval $(1) = $(2))) ++endef ++ ++# Allow setting CC and AR, or setting CROSS_COMPILE as a prefix. ++$(call allow-override,CC,$(CROSS_COMPILE)gcc) ++$(call allow-override,AR,$(CROSS_COMPILE)ar) ++$(call allow-override,STRIP,$(CROSS_COMPILE)strip) ++$(call allow-override,PKG_CONFIG,pkg-config) ++$(call allow-override,LD_SO_CONF_PATH,/etc/ld.so.conf.d/) ++$(call allow-override,LDCONFIG,ldconfig) ++ ++INSTALL = install ++MKDIR = mkdir ++FOPTS := -flto=auto -ffat-lto-objects -fexceptions -fstack-protector-strong \ ++ -fasynchronous-unwind-tables -fstack-clash-protection ++WOPTS := -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -Wno-maybe-uninitialized ++ ++ifeq ($(CC),clang) ++ FOPTS := $(filter-out -ffat-lto-objects, $(FOPTS)) ++ WOPTS := $(filter-out -Wno-maybe-uninitialized, $(WOPTS)) + endif + +-include $(srctree)/tools/scripts/Makefile.include +- +-# O is an alias for OUTPUT +-OUTPUT := $(O) +- +-ifeq ($(OUTPUT),) +- OUTPUT := $(CURDIR) ++TRACEFS_HEADERS := $$($(PKG_CONFIG) --cflags libtracefs) ++ ++CFLAGS := -O -g -DVERSION=\"$(VERSION)\" $(FOPTS) $(MOPTS) $(WOPTS) $(TRACEFS_HEADERS) $(EXTRA_CFLAGS) ++LDFLAGS := -flto=auto -ggdb $(EXTRA_LDFLAGS) ++LIBS := $$($(PKG_CONFIG) --libs libtracefs) ++ ++SRC := $(wildcard src/*.c) ++HDR := $(wildcard src/*.h) ++OBJ := $(SRC:.c=.o) ++DIRS := src ++FILES := Makefile README.txt ++CEXT := bz2 ++TARBALL := $(NAME)-$(VERSION).tar.$(CEXT) ++TAROPTS := -cvjf $(TARBALL) ++BINDIR := /usr/bin ++DATADIR := /usr/share ++DOCDIR := $(DATADIR)/doc ++MANDIR := $(DATADIR)/man ++LICDIR := $(DATADIR)/licenses ++SRCTREE := $(or $(BUILD_SRC),$(CURDIR)) ++ ++# If running from the tarball, man pages are stored in the Documentation ++# dir. If running from the kernel source, man pages are stored in ++# Documentation/tools/rtla/. ++ifneq ($(wildcard Documentation/.*),) ++DOCSRC = Documentation/ + else +- # subdir is used by the ../Makefile in $(call descend,) +- ifneq ($(subdir),) +- OUTPUT := $(OUTPUT)/$(subdir) +- endif +-endif +- +-ifneq ($(patsubst %/,,$(lastword $(OUTPUT))),) +- OUTPUT := $(OUTPUT)/ ++DOCSRC = $(SRCTREE)/../../../Documentation/tools/rtla/ + endif + +-RTLA := $(OUTPUT)rtla +-RTLA_IN := $(RTLA)-in.o ++LIBTRACEEVENT_MIN_VERSION = 1.5 ++LIBTRACEFS_MIN_VERSION = 1.3 + +-VERSION := $(shell sh -c "make -sC ../../.. kernelversion | grep -v make") +-DOCSRC := ../../../Documentation/tools/rtla/ ++.PHONY: all warnings show_warnings ++all: warnings rtla + +-FEATURE_TESTS := libtraceevent +-FEATURE_TESTS += libtracefs +-FEATURE_DISPLAY := libtraceevent +-FEATURE_DISPLAY += libtracefs +- +-ifeq ($(V),1) +- Q = +-else +- Q = @ ++TEST_LIBTRACEEVENT = $(shell sh -c "$(PKG_CONFIG) --atleast-version $(LIBTRACEEVENT_MIN_VERSION) libtraceevent > /dev/null 2>&1 || echo n") ++ifeq ("$(TEST_LIBTRACEEVENT)", "n") ++WARNINGS = show_warnings ++MISSING_LIBS += echo "** libtraceevent version $(LIBTRACEEVENT_MIN_VERSION) or higher"; ++MISSING_PACKAGES += "libtraceevent-devel" ++MISSING_SOURCE += echo "** https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/ "; + endif + +-all: $(RTLA) +- +-include $(srctree)/tools/build/Makefile.include +-include Makefile.rtla +- +-# check for dependencies only on required targets +-NON_CONFIG_TARGETS := clean install tarball doc doc_clean doc_install +- +-config := 1 +-ifdef MAKECMDGOALS +-ifeq ($(filter-out $(NON_CONFIG_TARGETS),$(MAKECMDGOALS)),) +- config := 0 +-endif ++TEST_LIBTRACEFS = $(shell sh -c "$(PKG_CONFIG) --atleast-version $(LIBTRACEFS_MIN_VERSION) libtracefs > /dev/null 2>&1 || echo n") ++ifeq ("$(TEST_LIBTRACEFS)", "n") ++WARNINGS = show_warnings ++MISSING_LIBS += echo "** libtracefs version $(LIBTRACEFS_MIN_VERSION) or higher"; ++MISSING_PACKAGES += "libtracefs-devel" ++MISSING_SOURCE += echo "** https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/ "; + endif + +-ifeq ($(config),1) +- include $(srctree)/tools/build/Makefile.feature +- include Makefile.config ++define show_dependencies ++ @echo "********************************************"; \ ++ echo "** NOTICE: Failed build dependencies"; \ ++ echo "**"; \ ++ echo "** Required Libraries:"; \ ++ $(MISSING_LIBS) \ ++ echo "**"; \ ++ echo "** Consider installing the latest libtracefs from your"; \ ++ echo "** distribution, e.g., 'dnf install $(MISSING_PACKAGES)' on Fedora,"; \ ++ echo "** or from source:"; \ ++ echo "**"; \ ++ $(MISSING_SOURCE) \ ++ echo "**"; \ ++ echo "********************************************" ++endef ++ ++show_warnings: ++ $(call show_dependencies); ++ ++ifneq ("$(WARNINGS)", "") ++ERROR_OUT = $(error Please add the necessary dependencies) ++ ++warnings: $(WARNINGS) ++ $(ERROR_OUT) + endif + +-CFLAGS += $(INCLUDES) $(LIB_INCLUDES) +- +-export CFLAGS OUTPUT srctree +- +-$(RTLA): $(RTLA_IN) +- $(QUIET_LINK)$(CC) $(LDFLAGS) -o $(RTLA) $(RTLA_IN) $(EXTLIBS) +- +-static: $(RTLA_IN) +- $(eval LDFLAGS += -static) +- $(QUIET_LINK)$(CC) -static $(LDFLAGS) -o $(RTLA)-static $(RTLA_IN) $(EXTLIBS) +- +-rtla.%: fixdep FORCE +- make -f $(srctree)/tools/build/Makefile.build dir=. $@ +- +-$(RTLA_IN): fixdep FORCE +- make $(build)=rtla +- +-clean: doc_clean fixdep-clean +- $(call QUIET_CLEAN, rtla) +- $(Q)find . -name '*.o' -delete -o -name '\.*.cmd' -delete -o -name '\.*.d' -delete +- $(Q)rm -f rtla rtla-static fixdep FEATURE-DUMP rtla-* +- $(Q)rm -rf feature +-.PHONY: FORCE clean ++rtla: $(OBJ) ++ $(CC) -o rtla $(LDFLAGS) $(OBJ) $(LIBS) ++ ++static: $(OBJ) ++ $(CC) -o rtla-static $(LDFLAGS) --static $(OBJ) $(LIBS) -lpthread -ldl ++ ++.PHONY: install ++install: doc_install ++ $(MKDIR) -p $(DESTDIR)$(BINDIR) ++ $(INSTALL) rtla -m 755 $(DESTDIR)$(BINDIR) ++ $(STRIP) $(DESTDIR)$(BINDIR)/rtla ++ @test ! -f $(DESTDIR)$(BINDIR)/osnoise || rm $(DESTDIR)$(BINDIR)/osnoise ++ ln -s rtla $(DESTDIR)$(BINDIR)/osnoise ++ @test ! -f $(DESTDIR)$(BINDIR)/hwnoise || rm $(DESTDIR)$(BINDIR)/hwnoise ++ ln -s rtla $(DESTDIR)$(BINDIR)/hwnoise ++ @test ! -f $(DESTDIR)$(BINDIR)/timerlat || rm $(DESTDIR)$(BINDIR)/timerlat ++ ln -s rtla $(DESTDIR)$(BINDIR)/timerlat ++ ++.PHONY: clean tarball ++clean: doc_clean ++ @test ! -f rtla || rm rtla ++ @test ! -f rtla-static || rm rtla-static ++ @test ! -f src/rtla.o || rm src/rtla.o ++ @test ! -f $(TARBALL) || rm -f $(TARBALL) ++ @rm -rf *~ $(OBJ) *.tar.$(CEXT) ++ ++tarball: clean ++ rm -rf $(NAME)-$(VERSION) && mkdir $(NAME)-$(VERSION) ++ echo $(VERSION) > $(NAME)-$(VERSION)/VERSION ++ cp -r $(DIRS) $(FILES) $(NAME)-$(VERSION) ++ mkdir $(NAME)-$(VERSION)/Documentation/ ++ cp -rp $(SRCTREE)/../../../Documentation/tools/rtla/* $(NAME)-$(VERSION)/Documentation/ ++ tar $(TAROPTS) --exclude='*~' $(NAME)-$(VERSION) ++ rm -rf $(NAME)-$(VERSION) ++ ++.PHONY: doc doc_clean doc_install ++doc: ++ $(MAKE) -C $(DOCSRC) ++ ++doc_clean: ++ $(MAKE) -C $(DOCSRC) clean ++ ++doc_install: ++ $(MAKE) -C $(DOCSRC) install +diff --git a/tools/tracing/rtla/Makefile.rtla b/tools/tracing/rtla/Makefile.rtla +deleted file mode 100644 +index 3ff0b8970896..000000000000 +--- a/tools/tracing/rtla/Makefile.rtla ++++ /dev/null +@@ -1,80 +0,0 @@ +-# SPDX-License-Identifier: GPL-2.0-only +- +-define allow-override +- $(if $(or $(findstring environment,$(origin $(1))),\ +- $(findstring command line,$(origin $(1)))),,\ +- $(eval $(1) = $(2))) +-endef +- +-# Allow setting CC and AR, or setting CROSS_COMPILE as a prefix. +-$(call allow-override,CC,$(CROSS_COMPILE)gcc) +-$(call allow-override,AR,$(CROSS_COMPILE)ar) +-$(call allow-override,STRIP,$(CROSS_COMPILE)strip) +-$(call allow-override,PKG_CONFIG,pkg-config) +-$(call allow-override,LD_SO_CONF_PATH,/etc/ld.so.conf.d/) +-$(call allow-override,LDCONFIG,ldconfig) +-export CC AR STRIP PKG_CONFIG LD_SO_CONF_PATH LDCONFIG +- +-FOPTS := -flto=auto -ffat-lto-objects -fexceptions -fstack-protector-strong \ +- -fasynchronous-unwind-tables -fstack-clash-protection +-WOPTS := -O -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 \ +- -Wp,-D_GLIBCXX_ASSERTIONS -Wno-maybe-uninitialized +- +-ifeq ($(CC),clang) +- FOPTS := $(filter-out -flto=auto -ffat-lto-objects, $(FOPTS)) +- WOPTS := $(filter-out -Wno-maybe-uninitialized, $(WOPTS)) +-endif +- +-CFLAGS := -g -DVERSION=\"$(VERSION)\" $(FOPTS) $(WOPTS) $(CFLAGS) +-LDFLAGS := -ggdb $(LDFLAGS) +- +-RM := rm -rf +-LN := ln -s +-INSTALL := install +-MKDIR := mkdir +-STRIP := strip +-BINDIR := /usr/bin +- +-.PHONY: install +-install: doc_install +- @$(MKDIR) -p $(DESTDIR)$(BINDIR) +- $(call QUIET_INSTALL,rtla)$(INSTALL) rtla -m 755 $(DESTDIR)$(BINDIR) +- @$(STRIP) $(DESTDIR)$(BINDIR)/rtla +- @test ! -f $(DESTDIR)$(BINDIR)/osnoise || $(RM) $(DESTDIR)$(BINDIR)/osnoise +- @$(LN) rtla $(DESTDIR)$(BINDIR)/osnoise +- @test ! -f $(DESTDIR)$(BINDIR)/hwnoise || $(RM) $(DESTDIR)$(BINDIR)/hwnoise +- @$(LN) -s rtla $(DESTDIR)$(BINDIR)/hwnoise +- @test ! -f $(DESTDIR)$(BINDIR)/timerlat || $(RM) $(DESTDIR)$(BINDIR)/timerlat +- @$(LN) -s rtla $(DESTDIR)$(BINDIR)/timerlat +- +-.PHONY: doc doc_clean doc_install +-doc: +- $(MAKE) -C $(DOCSRC) +- +-doc_clean: +- $(MAKE) -C $(DOCSRC) clean +- +-doc_install: +- $(MAKE) -C $(DOCSRC) install +- +-# This section is neesary for the tarball, when the tarball +-# support is removed, we can delete these entries. +-NAME := rtla +-DIRS := src +-FILES := Makefile README.txt +-CEXT := bz2 +-TARBALL := $(NAME)-$(VERSION).tar.$(CEXT) +-TAROPTS := -cvjf $(TARBALL) +-SRCTREE := $(or $(BUILD_SRC),$(CURDIR)) +- +-tarball: clean +- $(RM) $(NAME)-$(VERSION) && $(MKDIR) $(NAME)-$(VERSION) +- echo $(VERSION) > $(NAME)-$(VERSION)/VERSION +- cp -r $(DIRS) $(FILES) $(NAME)-$(VERSION) +- $(MKDIR) $(NAME)-$(VERSION)/Documentation/ +- cp -rp $(SRCTREE)/../../../Documentation/tools/$(NAME)/* $(NAME)-$(VERSION)/Documentation/ +- cp Makefile.standalone $(NAME)-$(VERSION)/Makefile +- cp Makefile.$(NAME) $(NAME)-$(VERSION)/ +- tar $(TAROPTS) --exclude='*~' $(NAME)-$(VERSION) +- $(RM) $(NAME)-$(VERSION) +-.PHONY: tarball +diff --git a/tools/tracing/rtla/Makefile.standalone b/tools/tracing/rtla/Makefile.standalone +deleted file mode 100644 +index 86d07cb52fa5..000000000000 +--- a/tools/tracing/rtla/Makefile.standalone ++++ /dev/null +@@ -1,26 +0,0 @@ +-# SPDX-License-Identifier: GPL-2.0-only +- +-VERSION := $(shell cat VERSION) +-CFLAGS += $$($(PKG_CONFIG) --cflags libtracefs) +-EXTLIBS += $$($(PKG_CONFIG) --libs libtracefs) +- +-rtla: +- +-include Makefile.rtla +- +-SRC := $(wildcard src/*.c) +-HDR := $(wildcard src/*.h) +-OBJ := $(SRC:.c=.o) +-DOCSRC := Documentation/ +- +-rtla: $(OBJ) +- $(CC) -o rtla $(LDFLAGS) $(OBJ) $(LIBS) $(EXTLIBS) +- $(info This is a deprecated method to compile RTLA, please compile from Linux kernel source) +- +-.PHONY: clean tarball +-clean: doc_clean +- @test ! -f rtla || rm rtla +- @test ! -f rtla-static || rm rtla-static +- @test ! -f src/rtla.o || rm src/rtla.o +- @test ! -f $(TARBALL) || rm -f $(TARBALL) +- @rm -rf *~ $(OBJ) *.tar.$(CEXT) +diff --git a/tools/tracing/rtla/src/Build b/tools/tracing/rtla/src/Build +deleted file mode 100644 +index dbed9e31829b..000000000000 +--- a/tools/tracing/rtla/src/Build ++++ /dev/null +@@ -1,11 +0,0 @@ +-rtla-y += trace.o +-rtla-y += utils.o +-rtla-y += osnoise.o +-rtla-y += osnoise_top.o +-rtla-y += osnoise_hist.o +-rtla-y += timerlat.o +-rtla-y += timerlat_top.o +-rtla-y += timerlat_hist.o +-rtla-y += timerlat_u.o +-rtla-y += timerlat_aa.o +-rtla-y += rtla.o +-- +2.46.0 + diff --git a/meta/recipes-kernel/linux/linux-yocto_6.10.bb b/meta/recipes-kernel/linux/linux-yocto_6.10.bb index c0b1b0b6cc..c022d86c8c 100644 --- a/meta/recipes-kernel/linux/linux-yocto_6.10.bb +++ b/meta/recipes-kernel/linux/linux-yocto_6.10.bb @@ -41,7 +41,8 @@ PN:class-devupstream = "linux-yocto-upstream" KBRANCH:class-devupstream = "v6.10/base" SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH};protocol=https \ - git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-6.10;destsuffix=${KMETA};protocol=https" + git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-6.10;destsuffix=${KMETA};protocol=https \ + file://${THISDIR}/files/0001-Revert-tools-rtla-Use-tools-build-makefiles-to-build.patch" LIC_FILES_CHKSUM = "file://COPYING;md5=6bc538ed5bd9a7fc9398086aedcd7e46" LINUX_VERSION ?= "6.10.3"