From 2e993abbe70bd1821713fa49ead351fdd3ddafa0 Mon Sep 17 00:00:00 2001 From: Zhao Hang Date: Tue, 5 Dec 2023 14:06:04 +0800 Subject: [PATCH] import accel-config-3.5.3-1.src.rpm Signed-off-by: Zhao Hang --- 0001-testing-vercheck.patch | 36 ++++++++++ README.md | 11 --- accel-config.spec | 131 ++++++++++++++++++++++++++++++++++++ dist | 1 + download | 1 + 5 files changed, 169 insertions(+), 11 deletions(-) create mode 100644 0001-testing-vercheck.patch delete mode 100644 README.md create mode 100644 accel-config.spec create mode 100644 dist create mode 100644 download diff --git a/0001-testing-vercheck.patch b/0001-testing-vercheck.patch new file mode 100644 index 0000000..8ad2812 --- /dev/null +++ b/0001-testing-vercheck.patch @@ -0,0 +1,36 @@ +diff --color -ur idxd-config-accel-config-v3.4.8/test/dsa_user_test_runner.sh idxd-config-accel-config-v3.4.8-new/test/dsa_user_test_runner.sh +--- idxd-config-accel-config-v3.4.8/test/dsa_user_test_runner.sh 2022-09-21 14:16:06.000000000 -0700 ++++ idxd-config-accel-config-v3.4.8-new/test/dsa_user_test_runner.sh 2022-10-06 16:36:02.838178412 -0700 +@@ -14,7 +14,7 @@ + + [ ! -f "$DSATEST" ] && echo "fail: $LINENO" && exit 1 + +-check_min_kver "5.6" || do_skip "kernel does not support idxd" ++check_min_kver "4.18" || do_skip "kernel does not support idxd" + + # skip if no pasid support as dsa_test does not support operation w/o pasid yet. + [ ! -f "/sys/bus/dsa/devices/$DSA/pasid_enabled" ] && echo "No SVM support" && exit "$EXIT_SKIP" +diff --color -ur idxd-config-accel-config-v3.4.8/test/iaa_user_test_runner.sh idxd-config-accel-config-v3.4.8-new/test/iaa_user_test_runner.sh +--- idxd-config-accel-config-v3.4.8/test/iaa_user_test_runner.sh 2022-09-21 14:16:06.000000000 -0700 ++++ idxd-config-accel-config-v3.4.8-new/test/iaa_user_test_runner.sh 2022-10-06 16:35:43.989998045 -0700 +@@ -14,7 +14,7 @@ + + [ ! -f "$IAATEST" ] && echo "fail: $LINENO" && exit 1 + +-check_min_kver "5.6" || do_skip "kernel does not support idxd" ++check_min_kver "4.18" || do_skip "kernel does not support idxd" + + # skip if no pasid support as iaa_test does not support operation w/o pasid yet. + [ ! -f "/sys/bus/dsa/devices/$IAA/pasid_enabled" ] && echo "No SVM support" && exit "$EXIT_SKIP" +diff --color -ur idxd-config-accel-config-v3.4.8/test/libaccfg.c idxd-config-accel-config-v3.4.8-new/test/libaccfg.c +--- idxd-config-accel-config-v3.4.8/test/libaccfg.c 2022-09-21 14:16:06.000000000 -0700 ++++ idxd-config-accel-config-v3.4.8-new/test/libaccfg.c 2022-10-06 16:36:31.090448787 -0700 +@@ -966,7 +966,7 @@ + struct accfg_device *device; + struct log_ctx log_ctx; + +- if (!accfg_test_attempt(test, KERNEL_VERSION(5, 6, 0))) ++ if (!accfg_test_attempt(test, KERNEL_VERSION(4, 18, 0))) + return EXIT_SKIP; + + accfg_set_log_priority(ctx, loglevel); diff --git a/README.md b/README.md deleted file mode 100644 index 7342728..0000000 --- a/README.md +++ /dev/null @@ -1,11 +0,0 @@ -Anolis OS -======================================= -# 代码仓库说明 -## 分支说明 ->进行代码开发工作时,请注意选择当前版本对应的分支 -* aX分支为对应大版本的主分支,如a8分支对应当前最新版本 -* aX.Y分支为对应小版本的维护分支,如a8.2分支对应8.2版本 -## 开发流程 -1. 首先fork目标分支到自己的namespace -2. 在自己的fork分支上做出修改 -3. 向对应的仓库中提交merge request,源分支为fork分支 diff --git a/accel-config.spec b/accel-config.spec new file mode 100644 index 0000000..3252b3d --- /dev/null +++ b/accel-config.spec @@ -0,0 +1,131 @@ +%global project_name idxd-config + +Name: accel-config +Version: 3.5.3 +Release: 1%{?dist} +Summary: Configure accelerator subsystem devices +# The entire source code is under GPLv2 except for accel-config +# library which is mostly LGPLv2, ccan/list which is BSD-MIT and +# the rest of ccan which is CC0. +License: GPLv2 and LGPLv2+ and MIT and CC0 +URL: https://github.com/intel/%{project_name} +Source0: %{URL}/archive/%{name}-v%{version}.tar.gz +Patch0: 0001-testing-vercheck.patch + +Requires: %{name}-libs%{?_isa} = %{version}-%{release} +BuildRequires: gcc +BuildRequires: autoconf +BuildRequires: asciidoc +BuildRequires: xmlto +BuildRequires: automake +BuildRequires: libtool +BuildRequires: pkgconfig +BuildRequires: pkgconfig(libkmod) +BuildRequires: pkgconfig(uuid) +BuildRequires: pkgconfig(json-c) +BuildRequires: pkgconfig(libudev) +BuildRequires: pkgconfig(zlib) +BuildRequires: systemd + +# accel-config is for configuring Intel DSA (Data-Streaming +# Accelerator) subsystem in the Linux kernel. It supports x86 only. +ExclusiveArch: %{ix86} x86_64 + +%description +Utility library for configuring the accelerator subsystem. + +%package devel +Summary: Development files for libaccfg +License: LGPLv2+ +Requires: %{name}-libs%{?_isa} = %{version}-%{release} + +%description devel +The %{name}-devel package contains libraries and header files for +developing applications that use %{name}. + + +%package libs +Summary: Configuration library for accelerator subsystem devices +# All source code of configuration library is LGPLv2, except +# ccan/list which is BSD-MIT and the rest of ccan/ which is CC0. +License: LGPLv2+ and MIT and CC0 +Requires: %{name}%{?_isa} = %{version}-%{release} + +%description libs +Libraries for %{name}. + +%package test +Summary: Tests for accel-config +License: GPLv2 +Requires: %{name}-libs%{?_isa} = %{version}-%{release} + +%description test +Tests for accel-config command. + +%prep +%autosetup -p1 -n %{project_name}-%{name}-v%{version} + +%build +echo %{version} > version +./autogen.sh +%configure --disable-static --disable-silent-rules --enable-test +%make_build + +%install +%make_install +find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' + +%check +make check + +%files +%license Documentation/COPYING licenses/BSD-MIT licenses/CC0 +%license licenses/accel-config-licenses LICENSE_GPL_2_0 +%{_bindir}/%{name} +%{_mandir}/man1/%{name}* +%{_sysconfdir}/%{name}/contrib/configs/* + +%files libs +%doc README.md +%license Documentation/COPYING licenses/BSD-MIT licenses/CC0 +%license licenses/libaccel-config-licenses accfg/lib/LICENSE_LGPL_2_1 +%{_libdir}/lib%{name}.so.* + +%files devel +%license Documentation/COPYING +%{_includedir}/%{name}/ +%{_libdir}/lib%{name}.so +%{_libdir}/pkgconfig/lib%{name}.pc + +%files test +%license Documentation/COPYING LICENSE_GPL_2_0 +#%doc test/README.md +%{_libexecdir}/accel-config/test/* + +%changelog +* Tue Apr 18 2023 Jerry Snitselaar - 3.5.3-1 +- Rebase to 3.5.3 release. +resolves: rhbz#2153898 + +* Sun Oct 16 2022 Jerry Snitselaar - 3.5.0-1 +- Rebase to the 3.5.0 release. +resolves: rhbz#2101608 + +* Thu Oct 06 2022 Jerry Snitselaar - 3.4.8-1 +- Rebase to 3.4.8 release. +resolves: rhbz#2101608 + +* Sun Apr 03 2022 Jerry Snitselaar - 3.4.6.3-1 +- Rebase to 3.4.6.3 release. +resolves: rhbz#2040076 + +* Thu Sep 09 2021 Jerry Snitselaar - 3.4.2-1 +- Rebase to 3.4.2 and add test subpackage. +resolves: rhbz#1971910 + +* Tue May 18 2021 Jerry Snitselaar - 3.1-1 +- Rebase to 3.1 release. +resolves: rhbz#1920762 + +* Fri Nov 6 2020 Yunying Sun - 2.8-1 +- Initial Packaging diff --git a/dist b/dist new file mode 100644 index 0000000..9c0e36e --- /dev/null +++ b/dist @@ -0,0 +1 @@ +an8 diff --git a/download b/download new file mode 100644 index 0000000..fef6e96 --- /dev/null +++ b/download @@ -0,0 +1 @@ +c1f72c4996105df3c03698b6a076778e accel-config-v3.5.3.tar.gz -- Gitee