svn commit: r345094 - head/sys/compat/linuxkpi/common/include/linux

Hans Petter Selasky hselasky at FreeBSD.org
Wed Mar 13 18:00:26 UTC 2019


Author: hselasky
Date: Wed Mar 13 18:00:25 2019
New Revision: 345094
URL: https://svnweb.freebsd.org/changeset/base/345094

Log:
  Implement DEFINE_STATIC_SRCU() function macro in the LinuxKPI.
  
  Submitted by:		Johannes Lundberg <johalun0 at gmail.com>
  MFC after:		1 week
  Sponsored by:		Limelight Networks
  Sponsored by:		Mellanox Technologies

Modified:
  head/sys/compat/linuxkpi/common/include/linux/srcu.h

Modified: head/sys/compat/linuxkpi/common/include/linux/srcu.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/linux/srcu.h	Wed Mar 13 17:55:58 2019	(r345093)
+++ head/sys/compat/linuxkpi/common/include/linux/srcu.h	Wed Mar 13 18:00:25 2019	(r345094)
@@ -34,6 +34,9 @@ struct srcu_struct {
 
 #define	srcu_dereference(ptr,srcu)	((__typeof(*(ptr)) *)(ptr))
 
+#define	DEFINE_STATIC_SRCU(name) \
+	static struct srcu_struct name = {}
+
 /* prototypes */
 
 extern int srcu_read_lock(struct srcu_struct *);


More information about the svn-src-all mailing list