|
|
19d00e |
%global pkg be2iscsi
|
|
|
19d00e |
|
|
|
19d00e |
%global driver_version 5.14.0-1.el9
|
|
|
19d00e |
|
|
Kmods SIG |
01c6a1 |
%global kernel_version 5.14.0-44.el9
|
|
|
19d00e |
|
|
|
19d00e |
%global debug_package %{nil}
|
|
|
19d00e |
|
|
|
19d00e |
%global __spec_install_post \
|
|
|
19d00e |
%{?__debug_package:%{__debug_install_post}} \
|
|
|
19d00e |
%{__arch_install_post} \
|
|
|
19d00e |
%{__os_install_post} \
|
|
|
19d00e |
%{__mod_compress_install_post}
|
|
|
19d00e |
|
|
|
19d00e |
%global __mod_compress_install_post find %{buildroot}/lib/modules -type f -name \*.ko -exec xz \{\} \\;
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
Name: kmod-%{pkg}
|
|
|
efcf17 |
Version: 5.14.0.1
|
|
Kmods SIG |
01c6a1 |
Release: 9%{?dist}
|
|
|
19d00e |
Summary: Emulex OneConnectOpen-iSCSI (%{pkg}) driver
|
|
|
19d00e |
|
|
|
19d00e |
License: GPLv2
|
|
|
19d00e |
URL: https://www.kernel.org/
|
|
|
19d00e |
|
|
|
19d00e |
Source0: %{pkg}-%{driver_version}.tar.xz
|
|
|
19d00e |
Patch1: 0001-add-deprecated-ids.patch
|
|
|
19d00e |
|
|
|
19d00e |
ExclusiveArch: x86_64 aarch64
|
|
|
19d00e |
|
|
|
19d00e |
BuildRequires: elfutils-libelf-devel
|
|
|
19d00e |
BuildRequires: gcc
|
|
|
efcf17 |
BuildRequires: kernel-rpm-macros
|
|
|
19d00e |
BuildRequires: kmod
|
|
|
19d00e |
BuildRequires: make
|
|
|
19d00e |
BuildRequires: redhat-rpm-config
|
|
|
19d00e |
BuildRequires: xz
|
|
|
19d00e |
|
|
|
efcf17 |
BuildRequires: kernel-abi-stablelists = %{kernel_version}
|
|
|
19d00e |
BuildRequires: kernel-devel = %{kernel_version}
|
|
|
19d00e |
BuildRequires: kernel-devel-uname-r = %{kernel_version}.%{_arch}
|
|
|
19d00e |
|
|
|
efcf17 |
Requires: kernel >= %{kernel_version}
|
|
|
efcf17 |
Requires: kernel-uname-r >= %{kernel_version}.%{_arch}
|
|
|
efcf17 |
Requires: kernel-modules >= %{kernel_version}
|
|
|
efcf17 |
Requires: kernel-modules-uname-r >= %{kernel_version}.%{_arch}
|
|
|
19d00e |
|
|
|
19d00e |
Provides: installonlypkg(kernel-module)
|
|
|
efcf17 |
Provides: kernel-modules >= %{kernel_version}.%{_arch}
|
|
|
19d00e |
|
|
|
efcf17 |
Requires(post): %{_sbindir}/depmod
|
|
|
efcf17 |
Requires(postun): %{_sbindir}/depmod
|
|
|
19d00e |
|
|
|
efcf17 |
Requires(post): %{_sbindir}/weak-modules
|
|
|
efcf17 |
Requires(postun): %{_sbindir}/weak-modules
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%description
|
|
|
19d00e |
This package provides the Emulex OneConnectOpen-iSCSI (%{pkg}) driver. Compared
|
|
|
19d00e |
to the in-kernel driver this driver re-enables support for deprecated
|
|
|
19d00e |
BladeEngine 2 and 3 adapters.
|
|
|
19d00e |
|
|
|
19d00e |
BladeEngine 2 (BE2) devices:
|
|
|
19d00e |
- 0x19A2:0x0212: Emulex BladeEngine 2 10Gb iSCSI Initiator
|
|
|
19d00e |
- 0x19A2:0x0702: Emulex OneConnect OCe10101/OCm10101/OCe10102/OCm10102
|
|
|
19d00e |
- 0x19A2:0x0703: Emulex OneConnect OCe10100
|
|
|
19d00e |
|
|
|
19d00e |
BladeEngine 3 (BE3) devices:
|
|
|
19d00e |
- 0x19A2:0x0222: Emulex BladeEngine 3 iSCSI
|
|
|
19d00e |
- 0x19A2:0x0712: Emulex OneConnect Tomcat iSCSI
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%prep
|
|
|
19d00e |
%autosetup -p1 -n %{pkg}-%{driver_version}
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%build
|
|
|
19d00e |
pushd src
|
|
|
19d00e |
%{__make} -C /usr/src/kernels/%{kernel_version}.%{_arch} %{?_smp_mflags} M=$PWD modules
|
|
|
19d00e |
popd
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%install
|
|
|
19d00e |
%{__install} -D -t %{buildroot}/lib/modules/%{kernel_version}.%{_arch}/extra/drivers/scsi/%{pkg} src/%{pkg}.ko
|
|
|
19d00e |
|
|
|
19d00e |
# Make .ko objects temporarily executable for automatic stripping
|
|
|
19d00e |
find %{buildroot}/lib/modules -type f -name \*.ko -exec chmod u+x \{\} \+
|
|
|
19d00e |
|
|
|
efcf17 |
# Generate depmod.conf
|
|
|
efcf17 |
%{__install} -d %{buildroot}/%{_sysconfdir}/depmod.d/
|
|
|
efcf17 |
for kmod in $(find %{buildroot}/lib/modules/%{kernel_version}.%{_arch}/extra -type f -name \*.ko -printf "%%P\n" | sort)
|
|
|
efcf17 |
do
|
|
|
efcf17 |
echo "override $(basename $kmod .ko) * weak-updates/$(dirname $kmod)" >> %{buildroot}/%{_sysconfdir}/depmod.d/%{pkg}.conf
|
|
|
efcf17 |
done
|
|
|
efcf17 |
|
|
|
19d00e |
|
|
|
19d00e |
%clean
|
|
|
19d00e |
%{__rm} -rf %{buildroot}
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%post
|
|
|
19d00e |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
efcf17 |
printf '%s\n' "/lib/modules/%{kernel_version}.%{_arch}/extra/drivers/scsi/%{pkg}/%{pkg}.ko.xz" >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%preun
|
|
|
19d00e |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
efcf17 |
rpm -ql kmod-%{pkg}-%{?epoch:%{epoch}:}%{version}-%{release}.%{_arch} | grep '/lib/modules/%{kernel_version}.%{_arch}/.*\.ko\.xz$' >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%postun
|
|
|
efcf17 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove ]
|
|
|
19d00e |
then
|
|
|
efcf17 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove) )
|
|
|
efcf17 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove
|
|
|
19d00e |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
efcf17 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --remove-modules
|
|
|
19d00e |
fi
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
efcf17 |
%pretrans -p <lua>
|
|
|
efcf17 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add")
|
|
|
efcf17 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove")
|
|
|
efcf17 |
|
|
|
efcf17 |
|
|
|
19d00e |
%posttrans
|
|
|
efcf17 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add ]
|
|
|
19d00e |
then
|
|
|
efcf17 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add) )
|
|
|
efcf17 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
19d00e |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
efcf17 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --add-modules
|
|
|
19d00e |
fi
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%files
|
|
|
19d00e |
%defattr(644,root,root,755)
|
|
|
19d00e |
/lib/modules/%{kernel_version}.%{_arch}
|
|
|
19d00e |
%license COPYING
|
|
|
efcf17 |
%config(noreplace) %{_sysconfdir}/depmod.d/%{pkg}.conf
|
|
|
19d00e |
|
|
|
19d00e |
|
|
|
19d00e |
%changelog
|
|
Kmods SIG |
01c6a1 |
* Wed Jan 19 2022 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-9
|
|
Kmods SIG |
01c6a1 |
- Rebuild for 5.14.0-44.el9
|
|
Kmods SIG |
01c6a1 |
|
|
Kmods SIG |
d10530 |
* Tue Jan 18 2022 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-8
|
|
Kmods SIG |
d10530 |
- Rebuild for 5.14.0-43.el9
|
|
Kmods SIG |
d10530 |
|
|
Kmods SIG |
550cf4 |
* Mon Jan 17 2022 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-7
|
|
Kmods SIG |
550cf4 |
- Rebuild for 5.14.0-42.el9
|
|
Kmods SIG |
550cf4 |
|
|
Kmods SIG |
c0d291 |
* Fri Jan 14 2022 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-6
|
|
Kmods SIG |
c0d291 |
- Rebuild for 5.14.0-41.el9
|
|
Kmods SIG |
c0d291 |
|
|
|
9f796e |
* Sat Dec 25 2021 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-5
|
|
|
9f796e |
- Rebuild for 5.14.0-39.el9
|
|
|
9f796e |
- Skip unreleased kernel -38
|
|
Kmods SIG |
4ff075 |
|
|
Kmods SIG |
a87575 |
* Thu Dec 23 2021 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-4
|
|
Kmods SIG |
a87575 |
- Rebuild for 5.14.0-37.el9
|
|
Kmods SIG |
a87575 |
|
|
Kmods SIG |
2401b3 |
* Wed Dec 22 2021 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-3
|
|
Kmods SIG |
2401b3 |
- Rebuild for 5.14.0-36.el9
|
|
Kmods SIG |
2401b3 |
|
|
|
ed8b64 |
* Wed Dec 22 2021 Kmods SIG <sig-kmods@centosproject.org> - 5.14.0.1-2
|
|
|
ed8b64 |
- Rebuild for 5.14.0-34.el9
|
|
|
ed8b64 |
- Skip unreleased kernel -32 and -33
|
|
Kmods SIG |
ccf198 |
|
|
|
efcf17 |
* Thu Dec 16 2021 Peter Georg <peter.georg@physik.uni-regensburg.de> - 5.14.0.1-1
|
|
|
efcf17 |
- Convert to kABI tracking kmod package (kernel >= 5.14.0-31.el9)
|