Update to 9.2.2
Signed-off-by: Igor Ivanov <igor.ivanov.va@gmail.com>
This commit is contained in:
parent
bf0a3154b8
commit
43c65e5da2
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,3 +1,4 @@
|
||||
/libvma-8.0.1.tar.gz
|
||||
/libvma-9.0.2.tar.gz
|
||||
/libvma-9.1.1.tar.gz
|
||||
/libvma-9.2.2.tar.gz
|
||||
|
94
0005-Fix-issues-for-gcc-11.patch
Normal file
94
0005-Fix-issues-for-gcc-11.patch
Normal file
@ -0,0 +1,94 @@
|
||||
From 3178430b32c71c0348eb33521d8323122714a58b Mon Sep 17 00:00:00 2001
|
||||
From: Igor Ivanov <igor.ivanov.va@gmail.com>
|
||||
Date: Wed, 16 Dec 2020 13:46:17 +0200
|
||||
Subject: [PATCH] Fix issues for gcc-11
|
||||
|
||||
1. The register storage class specifier is deprecated in C++11
|
||||
2. Disable -Wno-free-nonheap-object diagnostic that looks as
|
||||
incorrect for gcc-11
|
||||
|
||||
Signed-off-by: Igor Ivanov <igor.ivanov.va@gmail.com>
|
||||
---
|
||||
configure.ac | 8 ++++++--
|
||||
src/utils/asm-x86.h | 2 +-
|
||||
src/vma/sock/cleanable_obj.h | 9 ++++++++-
|
||||
src/vma/util/utils.cpp | 4 ++--
|
||||
4 files changed, 17 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 1540324a..811eb421 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -144,8 +144,12 @@ AC_MSG_CHECKING([for compiler])
|
||||
case $CC in
|
||||
gcc*|g++*)
|
||||
AC_MSG_RESULT([gcc])
|
||||
- CFLAGS="$CFLAGS -Wall -Wextra -Werror -Wundef -ffunction-sections -fdata-sections -Wsequence-point -pipe -Winit-self -Wmissing-include-dirs"
|
||||
- CXXFLAGS="$CXXFLAGS -Wshadow -Wall -Wextra -Werror -Wundef -ffunction-sections -fdata-sections -Wsequence-point -pipe -Winit-self -Wmissing-include-dirs"
|
||||
+ CFLAGS="$CFLAGS -Wall -Wextra -Werror -Wundef \
|
||||
+ -ffunction-sections -fdata-sections -Wsequence-point -pipe -Winit-self -Wmissing-include-dirs \
|
||||
+ -Wno-free-nonheap-object "
|
||||
+ CXXFLAGS="$CXXFLAGS -Wshadow -Wall -Wextra -Werror -Wundef \
|
||||
+ -ffunction-sections -fdata-sections -Wsequence-point -pipe -Winit-self -Wmissing-include-dirs \
|
||||
+ -Wno-free-nonheap-object "
|
||||
;;
|
||||
icc*|icpc*)
|
||||
AC_MSG_RESULT([icc])
|
||||
diff --git a/src/utils/asm-x86.h b/src/utils/asm-x86.h
|
||||
index 5dfb6f42..4e8f03ca 100644
|
||||
--- a/src/utils/asm-x86.h
|
||||
+++ b/src/utils/asm-x86.h
|
||||
@@ -110,7 +110,7 @@ static inline int atomic_fetch_and_add(int x, volatile int *ptr)
|
||||
*/
|
||||
static inline void gettimeoftsc(unsigned long long *p_tscval)
|
||||
{
|
||||
- register uint32_t upper_32, lower_32;
|
||||
+ uint32_t upper_32, lower_32;
|
||||
|
||||
// ReaD Time Stamp Counter (RDTCS)
|
||||
__asm__ __volatile__("rdtsc" : "=a" (lower_32), "=d" (upper_32));
|
||||
diff --git a/src/vma/sock/cleanable_obj.h b/src/vma/sock/cleanable_obj.h
|
||||
index 34801712..ea38f24b 100644
|
||||
--- a/src/vma/sock/cleanable_obj.h
|
||||
+++ b/src/vma/sock/cleanable_obj.h
|
||||
@@ -44,7 +44,14 @@ public:
|
||||
|
||||
virtual ~cleanable_obj(){};
|
||||
|
||||
- virtual void clean_obj(){ set_cleaned(); delete this; };
|
||||
+ /* This function should be used just for objects that
|
||||
+ * was allocated via new() (not by new[], nor by placement new, nor a local object on the stack,
|
||||
+ * nor a namespace-scope / global, nor a member of another object; but by plain ordinary new)
|
||||
+ */
|
||||
+ virtual void clean_obj(){
|
||||
+ set_cleaned();
|
||||
+ delete this;
|
||||
+ };
|
||||
|
||||
bool is_cleaned(){ return m_b_cleaned; };
|
||||
|
||||
diff --git a/src/vma/util/utils.cpp b/src/vma/util/utils.cpp
|
||||
index 5c0fe3e9..a4c3ce66 100644
|
||||
--- a/src/vma/util/utils.cpp
|
||||
+++ b/src/vma/util/utils.cpp
|
||||
@@ -235,7 +235,7 @@ unsigned short compute_ip_checksum(const unsigned short *buf, unsigned int nshor
|
||||
* */
|
||||
unsigned short compute_tcp_checksum(const struct iphdr *p_iphdr, const uint16_t *p_ip_payload)
|
||||
{
|
||||
- register unsigned long sum = 0;
|
||||
+ unsigned long sum = 0;
|
||||
uint16_t tcpLen = ntohs(p_iphdr->tot_len) - (p_iphdr->ihl<<2); // shift left 2 will multiply by 4 for converting to octets
|
||||
|
||||
//add the pseudo header
|
||||
@@ -277,7 +277,7 @@ unsigned short compute_tcp_checksum(const struct iphdr *p_iphdr, const uint16_t
|
||||
*/
|
||||
unsigned short compute_udp_checksum_rx(const struct iphdr *p_iphdr, const struct udphdr *udphdrp, mem_buf_desc_t* p_rx_wc_buf_desc)
|
||||
{
|
||||
- register unsigned long sum = 0;
|
||||
+ unsigned long sum = 0;
|
||||
unsigned short udp_len = htons(udphdrp->len);
|
||||
const uint16_t *p_ip_payload = (const uint16_t *) udphdrp;
|
||||
mem_buf_desc_t *p_ip_frag = p_rx_wc_buf_desc;
|
||||
--
|
||||
2.18.1
|
||||
|
@ -1,13 +0,0 @@
|
||||
diff --git a/src/utils/asm-x86.h b/src/utils/asm-x86.h
|
||||
index 5dfb6f4..4e8f03c 100644
|
||||
--- a/src/utils/asm-x86.h
|
||||
+++ b/src/utils/asm-x86.h
|
||||
@@ -110,7 +110,7 @@ static inline int atomic_fetch_and_add(int x, volatile int *ptr)
|
||||
*/
|
||||
static inline void gettimeoftsc(unsigned long long *p_tscval)
|
||||
{
|
||||
- register uint32_t upper_32, lower_32;
|
||||
+ uint32_t upper_32, lower_32;
|
||||
|
||||
// ReaD Time Stamp Counter (RDTCS)
|
||||
__asm__ __volatile__("rdtsc" : "=a" (lower_32), "=d" (upper_32));
|
10
libvma.spec
10
libvma.spec
@ -1,8 +1,8 @@
|
||||
%{!?configure_options: %global configure_options %{nil}}
|
||||
|
||||
Name: libvma
|
||||
Version: 9.1.1
|
||||
Release: 2%{?dist}
|
||||
Version: 9.2.2
|
||||
Release: 1%{?dist}
|
||||
Summary: A library for boosting TCP and UDP traffic (over RDMA hardware)
|
||||
|
||||
License: GPLv2 or BSD
|
||||
@ -11,7 +11,7 @@ Source0: https://github.com/Mellanox/libvma/archive/%{version}/%{name}-%{version
|
||||
Patch0: 0002-Update-systemctl-files.patch
|
||||
Patch1: 0003-Remove-30-libvma-limits.patch
|
||||
Patch2: 0004-Use-vmad-for-systemd.patch
|
||||
Patch3: %{name}-gcc11.patch
|
||||
Patch3: 0005-Fix-issues-for-gcc-11.patch
|
||||
|
||||
# libvma currently supports only the following architectures
|
||||
ExclusiveArch: x86_64 ppc64le ppc64 aarch64
|
||||
@ -102,6 +102,10 @@ install -D -m 644 contrib/scripts/vma.service $RPM_BUILD_ROOT/%{_prefix}/lib/sys
|
||||
%{_mandir}/man8/vma_stats.*
|
||||
|
||||
%changelog
|
||||
* Wed Dec 16 2020 Igor Ivanov <igor.ivanov.va@gmail.com> 9.2.2-1
|
||||
- Bump version to 9.2.2
|
||||
- Fix issues for gcc-11
|
||||
|
||||
* Thu Dec 10 2020 Jeff Law <law@redhat.com> 9.1.1-2
|
||||
- Don't use "register" in C++17. Still FTBFS though.
|
||||
|
||||
|
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (libvma-9.1.1.tar.gz) = 164d42de6c5d9c23cce8e75d8f9703f817ea69ba5a62f6ddc4ca760a5cb8ce4652409eeba814994e98268569b4ec2fe121f7c37763602dbd098191d2b5558554
|
||||
SHA512 (libvma-9.2.2.tar.gz) = 5a8a41442479107c8242938dad69ba86517823753ad6f0ed874b13e6c628f1536dc7e3de40d1244c0c06e3dbd025e619557488957681093b291de9c6fabb4a91
|
||||
|
Loading…
Reference in New Issue
Block a user