Development discussion of WireGuard
 help / color / mirror / Atom feed
* RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t'
@ 2020-04-11 18:21 Christian Weiss
  2020-04-14  9:06 ` Jason A. Donenfeld
  0 siblings, 1 reply; 2+ messages in thread
From: Christian Weiss @ 2020-04-11 18:21 UTC (permalink / raw)
  To: wireguard

Hello Dear Mailinglist,

with RHEL 7.8, kernel 3.10 and current Wireguard 1.0.20191226 make
throws the obove error:

# rpm -qa "wireguard*"
wireguard-tools-1.0.20191226-1.el7.x86_64
wireguard-dkms-1.0.20200401-1.el7.noarch

# cat /etc/oracle-release
Oracle Linux Server release 7.8

# uname -a
Linux xxxxxxxx 3.10.0-1127.el7.x86_64 #1 SMP Wed Apr 1 10:20:09 PDT 2020
x86_64 x86_64 x86_64 GNU/Linux

# make
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/main.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/noise.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/device.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/peer.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/timers.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/queueing.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/send.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/receive.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/socket.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/peerlookup.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/allowedips.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.o
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:25:1: error:
unknown type name ‘hsiphash_key_t’
 static hsiphash_key_t key;
 ^
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c: In function
‘wg_ratelimiter_allow’:
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:109:3: error:
implicit declaration of function ‘hsiphash_2u32’
[-Werror=implicit-function-declaration]
   bucket = &table_v4[hsiphash_2u32(net_word, ip, &key) &
   ^
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:116:3: error:
implicit declaration of function ‘hsiphash_3u32’
[-Werror=implicit-function-declaration]
   bucket = &table_v6[hsiphash_3u32(net_word, ip >> 32, ip, &key) &
   ^
cc1: some warnings being treated as errors
make[2]: *** [/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.o]
Error 1
make[1]: *** [_module_/var/lib/dkms/wireguard/1.0.20200401/build] Error 2
make: *** [module] Error 2


The following change works for me; make succeeds:
--- compat/compat.h.bak 2020-04-11 20:04:15.077425108 +0200
+++ compat/compat.h     2020-04-11 20:06:39.279397118 +0200
@@ -1034,7 +1034,7 @@
 }
 #endif

-#if defined(ISUBUNTU1604)
+#if defined(ISUBUNTU1604) || defined(ISRHEL7)
 #include <linux/siphash.h>
 #ifndef _WG_LINUX_SIPHASH_H
 #define hsiphash_2u32 siphash_2u32

Kind regards,
Christian

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t'
  2020-04-11 18:21 RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t' Christian Weiss
@ 2020-04-14  9:06 ` Jason A. Donenfeld
  0 siblings, 0 replies; 2+ messages in thread
From: Jason A. Donenfeld @ 2020-04-14  9:06 UTC (permalink / raw)
  To: Christian Weiss; +Cc: WireGuard mailing list

Hi Christian,

Thanks. Addressed here:
https://git.zx2c4.com/wireguard-linux-compat/commit/?id=c15894ad17cb0760471c2dd798bfbbea2081b4db
. I'll have a new release out shortly.

By the way, you'll have more reliability using the elrepo kmod these days:
https://lists.zx2c4.com/pipermail/wireguard/2020-April/005239.html

Jason

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-14  9:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-11 18:21 RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t' Christian Weiss
2020-04-14  9:06 ` Jason A. Donenfeld

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).