+#define ICE_HASH_CFG_VALID(p) \
+ ((p)->hash_fld != 0 && (p)->pkt_hdr != 0)
+
+#define ICE_HASH_CFG_RESET(p) do { \
+ (p)->hash_fld = 0; \
+ (p)->pkt_hdr = 0; \
+} while (0)
+
+#define ICE_HASH_CFG_IS_ROTATING(p) \
+ ((p)->rotate == true)
+
+#define ICE_HASH_CFG_ROTATE_START(p) \
+ ((p)->rotate = true)
+
+#define ICE_HASH_CFG_ROTATE_STOP(p) \
+ ((p)->rotate = false)
+
+struct ice_hash_cfg {
+ uint32_t pkt_hdr;
+ uint64_t hash_fld;
+ bool rotate; /* rotate l3 rule after l4 rule. */
+ bool symm;
+};
+
+struct ice_hash_gtpu_ctx {
+ struct ice_hash_cfg ipv4;
+ struct ice_hash_cfg ipv6;
+ struct ice_hash_cfg ipv4_udp;
+ struct ice_hash_cfg ipv6_udp;
+ struct ice_hash_cfg ipv4_tcp;
+ struct ice_hash_cfg ipv6_tcp;
+};
+