Merge tag 'iommu-updates-v4.9' of git://git.kernel.org/pub/scm/linux/kernel/git/joro...
[cascardo/linux.git] / net / openvswitch / flow.h
index 03378e7..ae783f5 100644 (file)
@@ -50,6 +50,11 @@ struct ovs_tunnel_info {
        struct metadata_dst     *tun_dst;
 };
 
+struct vlan_head {
+       __be16 tpid; /* Vlan type. Generally 802.1q or 802.1ad.*/
+       __be16 tci;  /* 0 if no VLAN, VLAN_TAG_PRESENT set otherwise. */
+};
+
 #define OVS_SW_FLOW_KEY_METADATA_SIZE                  \
        (offsetof(struct sw_flow_key, recirc_id) +      \
        FIELD_SIZEOF(struct sw_flow_key, recirc_id))
@@ -69,7 +74,8 @@ struct sw_flow_key {
        struct {
                u8     src[ETH_ALEN];   /* Ethernet source address. */
                u8     dst[ETH_ALEN];   /* Ethernet destination address. */
-               __be16 tci;             /* 0 if no VLAN, VLAN_TAG_PRESENT set otherwise. */
+               struct vlan_head vlan;
+               struct vlan_head cvlan;
                __be16 type;            /* Ethernet frame type. */
        } eth;
        union {
@@ -172,14 +178,14 @@ struct sw_flow {
                struct hlist_node node[2];
                u32 hash;
        } flow_table, ufid_table;
-       int stats_last_writer;          /* NUMA-node id of the last writer on
+       int stats_last_writer;          /* CPU id of the last writer on
                                         * 'stats[0]'.
                                         */
        struct sw_flow_key key;
        struct sw_flow_id id;
        struct sw_flow_mask *mask;
        struct sw_flow_actions __rcu *sf_acts;
-       struct flow_stats __rcu *stats[]; /* One for each NUMA node.  First one
+       struct flow_stats __rcu *stats[]; /* One for each CPU.  First one
                                           * is allocated at flow creation time,
                                           * the rest are allocated on demand
                                           * while holding the 'stats[0].lock'.