[ovs-dev] route-table: Fix compatibility with pre-2.6.36 headers.

Submitted by Ben Pfaff on March 17, 2017, 9:21 p.m.

Details

Message ID 20170317212146.26079-1-blp@ovn.org
State New
Headers show

Commit Message

Ben Pfaff March 17, 2017, 9:21 p.m.
Reported-by: Timothy Redaelli <tredaelli@redhat.com>
Reported-at: https://mail.openvswitch.org/pipermail/ovs-dev/2017-March/329604.html
Signed-off-by: Ben Pfaff <blp@ovn.org>
---
 lib/route-table.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/lib/route-table.c b/lib/route-table.c
index ae8af438d864..67fda317638c 100644
--- a/lib/route-table.c
+++ b/lib/route-table.c
@@ -1,5 +1,5 @@ 
 /*
- * Copyright (c) 2011, 2012, 2013, 2014 Nicira, Inc.
+ * Copyright (c) 2011, 2012, 2013, 2014, 2017 Nicira, Inc.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -35,6 +35,10 @@ 
 #include "rtnetlink.h"
 #include "openvswitch/vlog.h"
 
+/* Linux 2.6.36 added RTA_MARK, so define it just in case we're building with
+ * old headers.  (We can't test for it with #ifdef because it's an enum.) */
+#define RTA_MARK 16
+
 VLOG_DEFINE_THIS_MODULE(route_table);
 
 struct route_data {