diff options
| author | CoprDistGit <infra@openeuler.org> | 2026-11-11 15:48:43 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2026-11-11 15:48:43 +0000 |
| commit | 22c1ba64fdc351bc5cb133b003e5511bea1a00ef (patch) | |
| tree | 57580884119d88355822de7e401ee19a669b5b30 /kernel.spec | |
| parent | ba6f5a3f1736be133bebba749d6c928c0093d605 (diff) | |
automatic import of kernelopeneuler24.03_LTS_SP3
Diffstat (limited to 'kernel.spec')
| -rw-r--r-- | kernel.spec | 93 |
1 files changed, 72 insertions, 21 deletions
diff --git a/kernel.spec b/kernel.spec index ec5cd99..3ac84d1 100644 --- a/kernel.spec +++ b/kernel.spec @@ -39,10 +39,11 @@ rm -f test_openEuler_sign.ko test_openEuler_sign.ko.sig %global debuginfodir /usr/lib/debug %global upstream_version 7.3 -%global upstream_sublevel 0 +%global upstream_sublevel 1 %global devel_release 0 %global maintenance_release .0.0 %global pkg_release .17 +%global _disable_source_fetch 0 %global openeuler_lts 0 %global openeuler_major 0 @@ -92,7 +93,7 @@ Release: %{devel_release}%{?maintenance_release}%{?pkg_release} Summary: Linux Kernel License: GPLv2 URL: http://www.kernel.org/ -Source0: kernel.tar.gz +Source0: https://mirrors.aliyun.com/linux-kernel/v7.x/linux-%{version}.tar.xz Source10: sign-modules Source11: x509.genkey Source12: extra_certificates @@ -143,7 +144,7 @@ BuildRequires: python-devel %endif BuildRequires: elfutils-devel zlib-devel binutils-devel newt-devel perl(ExtUtils::Embed) bison -BuildRequires: audit-libs-devel libpfm-devel libtraceevent-devel +BuildRequires: audit-libs-devel libpfm-devel libtraceevent-devel libtracefs-devel libbpf-devel clang bpftool BuildRequires: pciutils-devel gettext BuildRequires: rpm-build, elfutils BuildRequires: numactl-devel python3-devel glibc-static python3-docutils @@ -263,6 +264,12 @@ Summary: Inspection and simple manipulation of eBPF programs and maps This package contains the bpftool, which allows inspection and simple manipulation of eBPF programs and maps. +%package -n rtla +Summary: The Linux real-time scheduling analysis tool +%description -n rtla +rtla (Real-Time Linux Analysis) enables the analysis of the scheduling and +execution latencies of the Linux kernel, based on the tracefs interface. + %package source Summary: the kernel source %description source @@ -292,6 +299,10 @@ package or when debugging this package.\ %files -n bpftool-debuginfo -f bpftool-debugfiles.list %{expand:%%global _find_debuginfo_opts %{?_find_debuginfo_opts} -p '.*%{_sbindir}/bpftool.*(\.debug)?|XXX' -o bpftool-debugfiles.list} +%debuginfo_template -n rtla +%files -n rtla-debuginfo -f rtla-debugfiles.list +%{expand:%%global _find_debuginfo_opts %{?_find_debuginfo_opts} -p '.*%{_bindir}/rtla.*(\.debug)?|.*%{_bindir}/osnoise.*(\.debug)?|XXX' -o rtla-debugfiles.list} + %debuginfo_template -n %{name}-tools %files -n %{name}-tools-debuginfo -f kernel-tools-debugfiles.list %{expand:%%global _find_debuginfo_opts %{?_find_debuginfo_opts} -p '.*%{_bindir}/centrino-decode.*(\.debug)?|.*%{_bindir}/powernow-k8-decode.*(\.debug)?|.*%{_bindir}/cpupower.*(\.debug)?|.*%{_libdir}/libcpupower.*|.*%{_libdir}/libcpupower.*|.*%{_bindir}/turbostat.(\.debug)?|.*%{_bindir}/.*gpio.*(\.debug)?|.*%{_bindir}/.*iio.*(\.debug)?|.*%{_bindir}/tmon.*(.debug)?|XXX' -o kernel-tools-debugfiles.list} @@ -322,9 +333,27 @@ package or when debugging this package.\ tar -xjf %{SOURCE9998} %endif -mv kernel linux-%{KernelVer} +mv linux-%{version} linux-%{KernelVer} cd linux-%{KernelVer} +# perf: the bootstrap bpftool fails to link under the hardened linker. +# +# tools/perf/bpf_skel.mak builds bootstrap bpftool via a separate sub-make +# $(Q)CFLAGS= $(MAKE) -C ../bpf/bpftool ... bootstrap +# that clears CFLAGS (bpftool derives HOST_CFLAGS from it), so the host +# compile loses the position-independent flags, while HOST_LDFLAGS still +# inherits -specs=...-hardened-ld (implying -pie) from the RPM macros. +# relocation R_X86_64_32 against `.rodata.str1.8' can not be used when +# making a PIE object; recompile with -fPIE +# HOST_EXTRACFLAGS is appended after HOST_CFLAGS is derived, so injecting +# -fPIE through it survives the CFLAGS reset. Upstream reports the same +# failure in "[PATCH] perf build: build BPF skeletons with fPIC". +sed -i 's|^\(\t\$(Q)CFLAGS= \$(MAKE) -C ../bpf/bpftool OUTPUT=\$(SKEL_TOOL_TMP_OUT)/ bootstrap\)$|\1 HOST_EXTRACFLAGS="-fPIE"|' \ + tools/perf/bpf_skel.mak +grep -q 'HOST_EXTRACFLAGS="-fPIE"' tools/perf/bpf_skel.mak \ + || { echo "ERROR: failed to patch tools/perf/bpf_skel.mak for -fPIE"; exit 1; } + + %if 0%{?with_patch} cp %{SOURCE9000} . cp %{SOURCE9001} . @@ -529,6 +558,11 @@ pushd tools/bpf/bpftool %{make} popd +# rtla +pushd tools/tracing/rtla +%{make} %{?_smp_mflags} +popd + # cpupower chmod +x tools/power/cpupower/utils/version-gen.sh %{make} %{?_smp_mflags} -C tools/power/cpupower CPUFREQ_BENCH=false @@ -860,6 +894,11 @@ pushd tools/bpf/bpftool %{make} DESTDIR=%{buildroot} prefix=%{_prefix} bash_compdir=%{_sysconfdir}/bash_completion.d/ mandir=%{_mandir} install doc-install popd +# rtla (STRIP=: keeps debuginfo until find-debuginfo runs) +pushd tools/tracing/rtla +%{make} DESTDIR=%{buildroot} STRIP=: install +popd + # resolve_btfids mkdir -p %{buildroot}/usr/src/kernels/%{KernelVer}/tools/bpf/resolve_btfids cp tools/bpf/resolve_btfids/resolve_btfids %{buildroot}/usr/src/kernels/%{KernelVer}/tools/bpf/resolve_btfids @@ -916,12 +955,18 @@ install -d -m 755 %{buildroot}/usr/share/licenses/kernel-tools cp -a COPYING %{buildroot}/usr/share/licenses/kernel-tools/COPYING install -d -m 755 %{buildroot}/usr/share/licenses/bpftool cp -a COPYING %{buildroot}/usr/share/licenses/bpftool/COPYING +install -d -m 755 %{buildroot}/usr/share/licenses/rtla +cp -a COPYING %{buildroot}/usr/share/licenses/rtla/COPYING %define __spec_install_post\ %{?__debug_package:%{__debug_install_post}}\ %{__arch_install_post}\ %{__os_install_post}\ %{__modsign_install_post}\ +find %{_builddir}/%{name}-%{version}/linux-%{KernelVer} -type f -name '*.o' -delete ; \ +find %{_builddir}/%{name}-%{version}/linux-%{KernelVer} -type f -name '*.ko' -delete ; \ +find %{_builddir}/%{name}-%{version}/linux-%{KernelVer} -type f -name '*.cmd' -delete ; \ +rm -f %{_builddir}/%{name}-%{version}/linux-%{KernelVer}/vmlinux* ; \ %{nil} %post @@ -1111,6 +1156,21 @@ fi %{_mandir}/man8/bpftool-token.8.gz %license linux-%{KernelVer}/COPYING +%files -n rtla +%{_bindir}/rtla +%{_bindir}/osnoise +%{_bindir}/hwnoise +%{_bindir}/timerlat +%{_mandir}/man1/rtla.1.gz +%{_mandir}/man1/rtla-hwnoise.1.gz +%{_mandir}/man1/rtla-osnoise.1.gz +%{_mandir}/man1/rtla-osnoise-hist.1.gz +%{_mandir}/man1/rtla-osnoise-top.1.gz +%{_mandir}/man1/rtla-timerlat.1.gz +%{_mandir}/man1/rtla-timerlat-hist.1.gz +%{_mandir}/man1/rtla-timerlat-top.1.gz +%license linux-%{KernelVer}/COPYING + %if 0%{?with_source} %files source %defattr(-,root,root) @@ -1119,24 +1179,15 @@ fi %endif %changelog -* Tue Nov 3 2026 Xie XiuQi <xiexiuqi@huawei.com> - 7.3.0-0.0.0.17 +* Tue Nov 3 2026 Xie XiuQi <xiexiuqi@huawei.com> - 7.3.0-0.0.0.14 - kernel: update to v7.3 -- config: regenerate kernel-aarch64.config and kernel-x86_64.config against the v7.3 Kconfig tree -- config: record ML-DSA module signing key options as disabled in kernel-x86_64.config - -* Wed Oct 14 2026 Xie XiuQi <xiexiuqi@huawei.com> - 6.18.56-0.0.0.16 -- kernel: update to v6.18.56 -- config: add ARM64_ERRATUM_3821522 on aarch64, X86_AMD_PSTATE_DYNAMIC_EPP on x86_64 - -* Tue Sep 1 2026 Xie XiuQi <xiexiuqi@huawei.com> - 6.18.48-0.0.0.15 -- kernel: update to v6.18.48 - -* Tue Aug 11 2026 Xie XiuQi <xiexiuqi@huawei.com> - 6.18.40-0.0.0.14 -- Add self-service EulerMaker EBS cloud build (scripts/ebs-build.sh) -- Add scripts/gen-source-tarball.sh for local kernel.tar.gz generation -- Add ebs-build.conf.example and newcomer guide docs/ebs-build.md -- Update README/README_cn with cloud and local build instructions -- Add SPDX license header to scripts/clean-config +- config: regenerate aarch64/x86_64 configs against the v7.3 Kconfig tree +- config: enable WireGuard, SM3 and aarch64 MPAM; switch to PREEMPT_LAZY +- Add rtla subpackage (real-time analysis tool from tools/tracing/rtla) +- kernel.spec: pass -fPIE to bootstrap bpftool so perf builds against + the hardened linker +- Add self-service EulerMaker EBS cloud build +- clean-config: add SPDX header and cover v7.3 probe symbols * Tue Aug 11 2026 Xie XiuQi <xiexiuqi@huawei.com> - 6.18.40-0.0.0.13 - Add README and README_cn, drop empty readme placeholder |
