Implement BUILD_BUG() function macro in the LinuxKPI.

MFC after:	1 week
Submitted by:	Johannes Lundberg <johalun0@gmail.com>
Sponsored by:	Mellanox Technologies
Sponsored by:	Limelight Networks
This commit is contained in:
Hans Petter Selasky 2018-03-04 18:19:44 +00:00
parent 6c51dfb060
commit 20c8d8270c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=330392

View File

@ -86,6 +86,7 @@
#define S64_C(x) x ## LL
#define U64_C(x) x ## ULL
#define BUILD_BUG() CTASSERT(0)
#define BUILD_BUG_ON(x) CTASSERT(!(x))
#define BUILD_BUG_ON_MSG(x, msg) BUILD_BUG_ON(x)
#define BUILD_BUG_ON_NOT_POWER_OF_2(x) BUILD_BUG_ON(!powerof2(x))