Defined list_next_entry for older kernels.
authorFlorian Pose <fp@igh-essen.com>
Fri, 17 Apr 2015 11:32:54 +0200
changeset 2627 04c83089bac2
parent 2626 713058b68b43
child 2628 d123727b805b
Defined list_next_entry for older kernels.
master/domain.c
--- a/master/domain.c	Fri Apr 17 11:22:17 2015 +0200
+++ b/master/domain.c	Fri Apr 17 11:32:54 2015 +0200
@@ -47,6 +47,11 @@
  */
 #define DEBUG_REDUNDANCY 0
 
+#ifndef list_next_entry
+#define list_next_entry(pos, member) \
+    list_entry((pos)->member.next, typeof(*(pos)), member)
+#endif
+
 /*****************************************************************************/
 
 void ec_domain_clear_data(ec_domain_t *);
@@ -261,12 +266,12 @@
  *
  * \return Non-zero if error emplacing domain
  */
- static int emplace_datagram(ec_domain_t *domain,
+static int emplace_datagram(ec_domain_t *domain,
         uint32_t datagram_begin_offset,
         uint32_t datagram_end_offset,
         const ec_fmmu_config_t *datagram_first_fmmu,
         const ec_fmmu_config_t *datagram_end_fmmu
-)
+        )
 {
     unsigned int datagram_used[EC_DIR_COUNT];
     const ec_fmmu_config_t *curr_fmmu;