!40 [sync] PR-39: fix tuna apply example.conf failed due to kernel version >=5.13

From: @openeuler-sync-bot 
Reviewed-by: @wang--ge 
Signed-off-by: @wang--ge
This commit is contained in:
openeuler-ci-bot 2025-01-14 11:30:58 +00:00 committed by Gitee
commit 4feddfd981
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1,6 +1,6 @@
Name: tuna Name: tuna
Version: 0.19 Version: 0.19
Release: 1 Release: 2
Summary: Application tuning GUI & command line utility Summary: Application tuning GUI & command line utility
License: GPLv2 License: GPLv2
URL: https://rt.wiki.kernel.org/index.php/Tuna URL: https://rt.wiki.kernel.org/index.php/Tuna
@ -57,6 +57,15 @@ install -p -m755 tuna-cmd.py %{buildroot}/%{_bindir}/tuna
install -p -m755 oscilloscope-cmd.py %{buildroot}/%{_bindir}/oscilloscope install -p -m755 oscilloscope-cmd.py %{buildroot}/%{_bindir}/oscilloscope
install -p -m644 help/kthreads/* %{buildroot}/%{_datadir}/tuna/help/kthreads/ install -p -m644 help/kthreads/* %{buildroot}/%{_datadir}/tuna/help/kthreads/
install -p -m644 docs/tuna.8 %{buildroot}/%{_mandir}/man8/ install -p -m644 docs/tuna.8 %{buildroot}/%{_mandir}/man8/
#kernel version >= 5.13 Move SCHED_DEBUG sysctl to debugfs
#https://github.com/torvalds/linux/commit/8a99b6833c884fa0e7919030d93fecedc69fc625
sed -i '/kernel.sched_latency_ns/d' etc/tuna/example.conf
sed -i '/kernel.sched_min_granularity_ns/d' etc/tuna/example.conf
sed -i '/kernel.sched_nr_migrate/d' etc/tuna/example.conf
sed -i '/kernel.sched_tunable_scaling/d' etc/tuna/example.conf
sed -i '/kernel.sched_wakeup_granularity_ns/d' etc/tuna/example.conf
sed -i '/kernel.sched_migration_cost_ns/d' etc/tuna/example.conf
install -p -m644 etc/tuna/example.conf %{buildroot}/%{_sysconfdir}/tuna/ install -p -m644 etc/tuna/example.conf %{buildroot}/%{_sysconfdir}/tuna/
install -p -m644 etc/tuna.conf %{buildroot}/%{_sysconfdir}/ install -p -m644 etc/tuna.conf %{buildroot}/%{_sysconfdir}/
install -p -m644 org.tuna.policy %{buildroot}/%{_datadir}/polkit-1/actions/ install -p -m644 org.tuna.policy %{buildroot}/%{_datadir}/polkit-1/actions/
@ -88,6 +97,9 @@ done
%doc ChangeLog %doc ChangeLog
%changelog %changelog
* Tue Jan 14 2025 xu_ping <707078654@qq.com> - 0.19-2
- fix tuna apply example.conf failed due to kernel version >=5.13
* Mon Oct 16 2023 chenyaqiang <chenyaqiang@huawei.com> - 0.19-1 * Mon Oct 16 2023 chenyaqiang <chenyaqiang@huawei.com> - 0.19-1
- Upgrade to 0.19 - Upgrade to 0.19