Skip to contentSkip to conversation

Support use of HAVE_LINUX_BYTEORDER_SWABB_H for kernel versions older than 2.6.29

PATCH Lars Ellenberg 1 participant 1 message May 7, 2009 1 message not in the archive DRBD driver

lore
Share & tools
lore

Lars Ellenberg

author maintainer
#1 lore raw
In reply to a message not in the archive
Quoted 9 lines · Michael Prokop
drbd/linux/drbd_config.h +0 -0
index 4d323f7..ac14997 100644
@@ -74,7 +74,10 @@ extern const char *drbd_buildtag(void);
 #define HAVE_LINUX_SCATTERLIST_H

drbd/linux/drbd_config.h extern const char *drbd_buildtag(void); · line 83

Quoted 10 lines
drbd/linux/drbd_config.h +4 -1
 
 /* 2.6.29 and up no longer have swabb.h */
-//#define HAVE_LINUX_BYTEORDER_SWABB_H
+#include <linux/version.h>
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29)
+#define HAVE_LINUX_BYTEORDER_SWABB_H
+#endif
 
 /* Some vendor kernels < 2.6.7 might define msleep in one or
  * another way .. */

Thanks. But unneccessary.
For the other settings, scripts/adjust_drbd_config_h.sh has to be run anyways, which also takes care of this setting.

Signature · 5 lines
: Lars Ellenberg
: LINBIT | Your Way to High Availability
: DRBD/HA support and consulting http://www.linbit.com

DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.