add bsn_udf extension
diff --git a/c_gen/c_match.py b/c_gen/c_match.py
index fe6e56b..0da5227 100644
--- a/c_gen/c_match.py
+++ b/c_gen/c_match.py
@@ -295,6 +295,14 @@
     OF_OXM_INDEX_BSN_L3_SRC_CLASS_ID = 41,
     OF_OXM_INDEX_BSN_L3_DST_CLASS_ID = 42,
     OF_OXM_INDEX_BSN_EGR_PORT_GROUP_ID = 43,
+    OF_OXM_INDEX_BSN_UDF0 = 44,
+    OF_OXM_INDEX_BSN_UDF1 = 45,
+    OF_OXM_INDEX_BSN_UDF2 = 46,
+    OF_OXM_INDEX_BSN_UDF3 = 47,
+    OF_OXM_INDEX_BSN_UDF4 = 48,
+    OF_OXM_INDEX_BSN_UDF5 = 49,
+    OF_OXM_INDEX_BSN_UDF6 = 50,
+    OF_OXM_INDEX_BSN_UDF7 = 51,
 };
 
 #define OF_OXM_BIT(index) (((uint64_t) 1) << (index))
diff --git a/c_gen/c_type_maps.py b/c_gen/c_type_maps.py
index 19d7587..2b46932 100644
--- a/c_gen/c_type_maps.py
+++ b/c_gen/c_type_maps.py
@@ -544,6 +544,22 @@
         case 0x0b: return OF_OXM_BSN_L3_SRC_CLASS_ID_MASKED;
         case 0x0c: return OF_OXM_BSN_L3_DST_CLASS_ID;
         case 0x0d: return OF_OXM_BSN_L3_DST_CLASS_ID_MASKED;
+        case 0x10: return OF_OXM_BSN_UDF0;
+        case 0x11: return OF_OXM_BSN_UDF0_MASKED;
+        case 0x12: return OF_OXM_BSN_UDF1;
+        case 0x13: return OF_OXM_BSN_UDF1_MASKED;
+        case 0x14: return OF_OXM_BSN_UDF2;
+        case 0x15: return OF_OXM_BSN_UDF2_MASKED;
+        case 0x16: return OF_OXM_BSN_UDF3;
+        case 0x17: return OF_OXM_BSN_UDF3_MASKED;
+        case 0x18: return OF_OXM_BSN_UDF4;
+        case 0x19: return OF_OXM_BSN_UDF4_MASKED;
+        case 0x1a: return OF_OXM_BSN_UDF5;
+        case 0x1b: return OF_OXM_BSN_UDF5_MASKED;
+        case 0x1c: return OF_OXM_BSN_UDF6;
+        case 0x1d: return OF_OXM_BSN_UDF6_MASKED;
+        case 0x1e: return OF_OXM_BSN_UDF7;
+        case 0x1f: return OF_OXM_BSN_UDF7_MASKED;
         default: return OF_OBJECT_INVALID;
         }
     } else {
diff --git a/c_gen/match.py b/c_gen/match.py
index 2f12780..d9fdee5 100644
--- a/c_gen/match.py
+++ b/c_gen/match.py
@@ -468,6 +468,78 @@
         takes_mask_in_spec=True,
         order=1006,
         ),
+
+    bsn_udf0 = dict(
+        name="bsn_udf0",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf1 = dict(
+        name="bsn_udf1",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf2 = dict(
+        name="bsn_udf2",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf3 = dict(
+        name="bsn_udf3",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf4 = dict(
+        name="bsn_udf4",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf5 = dict(
+        name="bsn_udf5",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf6 = dict(
+        name="bsn_udf6",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
+
+    bsn_udf7 = dict(
+        name="bsn_udf7",
+        m_type="uint32_t",
+        print_type="PRIu32",
+        conditions="",
+        takes_mask_in_spec=True,
+        order=1010,
+        ),
 )
 
 match_keys_sorted = of_match_members.keys()
diff --git a/c_gen/templates/loci_show.h b/c_gen/templates/loci_show.h
index 5384837..f83e1bb 100644
--- a/c_gen/templates/loci_show.h
+++ b/c_gen/templates/loci_show.h
@@ -386,5 +386,13 @@
 #define LOCI_SHOW_u32_num_aux(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
 #define LOCI_SHOW_u64_checksum(writer, cookie, val) LOCI_SHOW_u64(writer, cookie, val)
 #define LOCI_SHOW_u32_bsn_egr_port_group_id(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf0(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf1(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf2(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf3(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf4(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf5(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf6(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
+#define LOCI_SHOW_u32_bsn_udf7(writer, cookie, val) LOCI_SHOW_u32(writer, cookie, val)
 
 #endif /* _LOCI_SHOW_H_ */