|
|
8374be |
%global pkg megaraid_mbox
|
|
|
8374be |
|
|
Kmods SIG |
b14f05 |
%global driver_version 4.18.0-80.el8
|
|
Kmods SIG |
b14f05 |
|
|
|
3e42a1 |
%global kernel_version 4.18.0-348.el8
|
|
|
8374be |
|
|
|
8374be |
%global _use_internal_dependency_generator 0
|
|
|
f7a6a6 |
%global __find_requires /usr/lib/rpm/redhat/find-requires
|
|
|
f7a6a6 |
%global __find_provides /usr/lib/rpm/redhat/find-provides
|
|
|
8374be |
|
|
|
8374be |
%global debug_package %{nil}
|
|
|
8374be |
|
|
|
8374be |
%global __spec_install_post \
|
|
|
8374be |
%{?__debug_package:%{__debug_install_post}} \
|
|
|
8374be |
%{__arch_install_post} \
|
|
|
8374be |
%{__os_install_post} \
|
|
|
8374be |
%{__mod_compress_install_post}
|
|
|
8374be |
|
|
|
8374be |
%global __mod_compress_install_post find %{buildroot}/lib/modules -type f -name \*.ko -exec xz \{\} \\;
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
Name: kmod-%{pkg}
|
|
Kmods SIG |
b14f05 |
Version: 4.18.0.80
|
|
|
3a9da6 |
Release: 3%{?dist}
|
|
|
8374be |
Summary: LSI Logic MegaRAID (%{pkg}) driver
|
|
|
8374be |
|
|
|
bcc757 |
License: GPLv2 and GPLv2+
|
|
|
8374be |
URL: https://www.kernel.org/
|
|
|
8374be |
|
|
Kmods SIG |
b14f05 |
Source0: %{pkg}-%{driver_version}.tar.xz
|
|
|
8374be |
|
|
|
b7234f |
ExclusiveArch: x86_64 aarch64 ppc64le
|
|
|
8374be |
|
|
|
8374be |
BuildRequires: elfutils-libelf-devel
|
|
|
8374be |
BuildRequires: gcc
|
|
|
f7a6a6 |
BuildRequires: kernel-rpm-macros
|
|
|
8374be |
BuildRequires: kmod
|
|
|
8374be |
BuildRequires: make
|
|
|
8374be |
BuildRequires: redhat-rpm-config
|
|
|
8374be |
BuildRequires: xz
|
|
|
8374be |
|
|
|
f7a6a6 |
BuildRequires: kernel-abi-stablelists = %{kernel_version}
|
|
|
8374be |
BuildRequires: kernel-devel = %{kernel_version}
|
|
|
8374be |
BuildRequires: kernel-devel-uname-r = %{kernel_version}.%{_arch}
|
|
|
8374be |
|
|
|
f7a6a6 |
Requires: kernel >= %{kernel_version}
|
|
|
f7a6a6 |
Requires: kernel-uname-r >= %{kernel_version}.%{_arch}
|
|
|
f7a6a6 |
Requires: kernel-modules >= %{kernel_version}
|
|
|
f7a6a6 |
Requires: kernel-modules-uname-r >= %{kernel_version}.%{_arch}
|
|
|
8374be |
|
|
|
8374be |
Provides: installonlypkg(kernel-module)
|
|
|
f7a6a6 |
Provides: kernel-modules >= %{kernel_version}.%{_arch}
|
|
|
8374be |
|
|
|
f7a6a6 |
Requires(post): %{_sbindir}/depmod
|
|
|
f7a6a6 |
Requires(postun): %{_sbindir}/depmod
|
|
|
8374be |
|
|
|
f7a6a6 |
Requires(post): %{_sbindir}/weak-modules
|
|
|
f7a6a6 |
Requires(postun): %{_sbindir}/weak-modules
|
|
|
8374be |
|
|
|
8374be |
Provides: kmod-megaraid_mm = %{?epoch:%{epoch}:}%{version}-%{release}
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%description
|
|
|
8374be |
This package provides the LSI Logic MegaRAID (%{pkg}) driver including the
|
|
|
8374be |
required LSI Logic Management Module (megaraid_mm) driver. Supported devices:
|
|
|
8374be |
|
|
|
8374be |
- 0x1000:0407:1000:0530: LSI MegaRAID SCSI 320-0X
|
|
|
8374be |
- 0x1000:0407:1000:0531: LSI MegaRAID SCSI 320-4X
|
|
|
8374be |
- 0x1000:0407:1000:0532: LSI MegaRAID SCSI 320-2X
|
|
|
8374be |
- 0x1000:0407:1028:0531: Dell PERC4/QC
|
|
|
8374be |
- 0x1000:0407:8086:0530: Intel RAID Controller SRCZCRX
|
|
|
8374be |
- 0x1000:0407:8086:0532: Intel RAID Controller SRCU42X
|
|
|
8374be |
- 0x1000:0408:1000:0001: LSI MegaRAID SCSI 320-1E
|
|
|
8374be |
- 0x1000:0408:1000:0002: LSI MegaRAID SCSI 320-2E
|
|
|
8374be |
- 0x1000:0408:1025:004D: ACER MegaRAID ROMB-2E
|
|
|
8374be |
- 0x1000:0408:1028:0001: Dell PERC 4e/SC
|
|
|
8374be |
- 0x1000:0408:1028:0002: Dell PERC 4e/DC
|
|
|
8374be |
- 0x1000:0408:1033:8287: NEC MegaRAID PCI Express ROMB
|
|
|
8374be |
- 0x1000:0408:1734:1065: FSC MegaRAID PCI Express ROMB
|
|
|
8374be |
- 0x1000:0408:8086:0002: Intel RAID Controller SRCU42E
|
|
|
8374be |
- 0x1000:0408:8086:3431: Intel RAID Controller SROMBU42E
|
|
|
8374be |
- 0x1000:0408:8086:3499: Intel RAID Controller SROMBU42E
|
|
|
8374be |
- 0x1000:0409:1000:3004: LSI MegaRAID SATA 300-4X
|
|
|
8374be |
- 0x1000:0409:1000:3008: LSI MegaRAID SATA 300-8X
|
|
|
8374be |
- 0x1000:0409:8086:3008: Intel RAID Controller SRCS28X
|
|
|
8374be |
- 0x1000:1960:1000:0518: LSI MegaRAID SCSI 320-2
|
|
|
8374be |
- 0x1000:1960:1000:0520: LSI MegaRAID SCSI 320-1
|
|
|
8374be |
- 0x1000:1960:1000:0523: LSI MegaRAID SATA 150-6
|
|
|
8374be |
- 0x1000:1960:1000:4523: LSI MegaRAID SATA 150-4
|
|
|
8374be |
- 0x1000:1960:1000:A520: LSI MegaRAID SCSI 320-0
|
|
|
8374be |
- 0x1000:1960:1028:0518: Dell PERC4/DC
|
|
|
8374be |
- 0x1000:1960:1028:0520: Dell PERC4/SC
|
|
|
8374be |
- 0x1000:1960:8086:0520: Intel RAID Controller SRCU51L
|
|
|
8374be |
- 0x1000:1960:8086:0523: Intel RAID Controller SRCS16
|
|
|
8374be |
- 0x101E:1960:1028:0471: Dell PERC3/QC
|
|
|
8374be |
- 0x101E:1960:1028:0475: Dell PERC3/SC
|
|
|
8374be |
- 0x101E:1960:1028:0493: Dell PERC3/DC
|
|
|
8374be |
- 0x1028:000E:1028:0123: Dell PERC3/Di
|
|
|
8374be |
- 0x1028:000F:1028:014A: Dell PERC4/Di
|
|
|
8374be |
- 0x1028:0013:1028:016C: Dell PERC 4e/Si
|
|
|
8374be |
- 0x1028:0013:1028:016D: Dell PERC 4e/Di
|
|
|
8374be |
- 0x1028:0013:1028:016E: Dell PERC 4e/Di
|
|
|
8374be |
- 0x1028:0013:1028:016F: Dell PERC 4e/Di
|
|
|
8374be |
- 0x1028:0013:1028:0170: Dell PERC 4e/Di
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%prep
|
|
Kmods SIG |
b14f05 |
%autosetup -p1 -n %{pkg}-%{driver_version}
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%build
|
|
|
8374be |
pushd src
|
|
|
8374be |
%{__make} -C /usr/src/kernels/%{kernel_version}.%{_arch} %{?_smp_mflags} M=$PWD modules
|
|
|
8374be |
popd
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%install
|
|
|
8374be |
%{__install} -D -t %{buildroot}/lib/modules/%{kernel_version}.%{_arch}/extra/drivers/scsi/megaraid src/%{pkg}.ko src/megaraid_mm.ko
|
|
|
8374be |
|
|
|
8374be |
# Make .ko objects temporarily executable for automatic stripping
|
|
|
8374be |
find %{buildroot}/lib/modules -type f -name \*.ko -exec chmod u+x \{\} \+
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%clean
|
|
|
8374be |
%{__rm} -rf %{buildroot}
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%post
|
|
|
8374be |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
f7a6a6 |
printf '%s\n' "/lib/modules/%{kernel_version}.%{_arch}/extra/drivers/scsi/megaraid/%{pkg}.ko.xz" >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
f7a6a6 |
printf '%s\n' "/lib/modules/%{kernel_version}.%{_arch}/extra/drivers/scsi/megaraid/megaraid_mm.ko.xz" >> %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%preun
|
|
|
8374be |
mkdir -p %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
f7a6a6 |
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
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%postun
|
|
|
f7a6a6 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove ]
|
|
|
8374be |
then
|
|
|
f7a6a6 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove) )
|
|
|
f7a6a6 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove
|
|
|
8374be |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
f7a6a6 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --remove-modules
|
|
|
8374be |
fi
|
|
|
8374be |
|
|
|
8374be |
|
|
|
f7a6a6 |
%pretrans -p <lua>
|
|
|
f7a6a6 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add")
|
|
|
f7a6a6 |
posix.unlink("%{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-remove")
|
|
|
f7a6a6 |
|
|
|
f7a6a6 |
|
|
|
8374be |
%posttrans
|
|
|
f7a6a6 |
if [ -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add ]
|
|
|
8374be |
then
|
|
|
f7a6a6 |
modules=( $(cat %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add) )
|
|
|
f7a6a6 |
rm -f %{_localstatedir}/lib/rpm-state/sig-kmods/weak-modules-add
|
|
|
8374be |
rmdir --ignore-fail-on-non-empty %{_localstatedir}/lib/rpm-state/sig-kmods
|
|
|
f7a6a6 |
printf '%s\n' "${modules[@]}" | %{_sbindir}/weak-modules --add-modules
|
|
|
8374be |
fi
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%files
|
|
|
8374be |
%defattr(644,root,root,755)
|
|
|
8374be |
/lib/modules/%{kernel_version}.%{_arch}
|
|
|
f2bca8 |
%license LICENSES
|
|
|
8374be |
|
|
|
8374be |
|
|
|
8374be |
%changelog
|
|
|
3a9da6 |
* Wed Jan 26 2022 Peter Georg <peter.georg@physik.uni-regensburg.de> - 4.18.0.80-3
|
|
|
3a9da6 |
- Drop dracut conf
|
|
|
3a9da6 |
|
|
|
b7234f |
* Sat Jan 22 2022 Peter Georg <peter.georg@physik.uni-regensburg.de> - 4.18.0.80-2
|
|
|
b7234f |
- Enable ppc64le
|
|
|
b7234f |
|
|
Kmods SIG |
b14f05 |
* Wed Jan 12 2022 Kmods SIG <sig-kmods@centosproject.org> - 4.18.0.80-1
|
|
Kmods SIG |
b14f05 |
- Switch to EL kernel source and versioning
|
|
Kmods SIG |
b14f05 |
- kABI tracking kmod package (kernel >= 4.18.0-348.el8)
|