summaryrefslogtreecommitdiff
path: root/rhel
diff options
context:
space:
mode:
authorAshish Varma <ashishvarma.ovs@gmail.com>2019-07-08 09:51:29 -0700
committerBen Pfaff <blp@ovn.org>2019-07-08 14:10:01 -0700
commit4afd1d8769de721a95a4f730fa023f77c9e51895 (patch)
treecb54115731709eee3c552e4f1ebcfc7c0f869b44 /rhel
parentc18c020e3cf789fbf5f3fc96e02fee4fc94c789c (diff)
downloadopenvswitch-4afd1d8769de721a95a4f730fa023f77c9e51895.tar.gz
rhel: Fixed a bug for checking the correct major version and revision.
Fixed a bug where checking for major version 3.10 and major revision not equal to 327 or 693 or 957 should have gone to the default else at the end. In the current code, the default else condition will not get executed for kernel with major version 3.10 and major revision not equal to 327/693/957 resulting in failure to load the kernel module. Fixes: 402efbe4e176 ("rhel: Add 4.12 kernel support in ovs-kmod-manage.sh") Signed-off-by: Ashish Varma <ashishvarma.ovs@gmail.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'rhel')
-rw-r--r--rhel/openvswitch-kmod-fedora.spec.in13
1 files changed, 6 insertions, 7 deletions
diff --git a/rhel/openvswitch-kmod-fedora.spec.in b/rhel/openvswitch-kmod-fedora.spec.in
index a50016d5e..b3588982e 100644
--- a/rhel/openvswitch-kmod-fedora.spec.in
+++ b/rhel/openvswitch-kmod-fedora.spec.in
@@ -90,13 +90,12 @@ if grep -qs "suse" /etc/os-release; then
if [ -x "%{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh" ]; then
%{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh
fi
-elif [ "$mainline_major" = "3" ] && [ "$mainline_minor" = "10" ]; then
- if [ "$major_rev" = "327" ] || [ "$major_rev" = "693" ] || \
- [ "$major_rev" = "957" ]; then
- # For RHEL 7.2, 7.4 and 7.6
- if [ -x "%{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh" ]; then
- %{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh
- fi
+elif [ "$mainline_major" = "3" ] && [ "$mainline_minor" = "10" ] &&
+ { [ "$major_rev" = "327" ] || [ "$major_rev" = "693" ] || \
+ [ "$major_rev" = "957" ]; }; then
+ # For RHEL 7.2, 7.4 and 7.6
+ if [ -x "%{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh" ]; then
+ %{_datadir}/openvswitch/scripts/ovs-kmod-manage.sh
fi
else
# Ensure that modprobe will find our modules.