diff mbox series

[API-NEXT,v3,3/6] api: ipsec: outbound operation option flags

Message ID 1516892418-5660-4-git-send-email-odpbot@yandex.ru
State Superseded
Headers show
Series [API-NEXT,v3,1/6] api: ipsec: IP header parameter types | expand

Commit Message

Github ODP bot Jan. 25, 2018, 3 p.m. UTC
From: Petri Savolainen <petri.savolainen@linaro.org>


Add flags to select which options application uses. Currently,
there's no ambiguity, but as soon as there are multiple options
implementation needs to know which options are used and which
are ignored.

Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org>

---
/** Email created from pull request 403 (psavol:next-ipsec-tfc)
 ** https://github.com/Linaro/odp/pull/403
 ** Patch: https://github.com/Linaro/odp/pull/403.patch
 ** Base sha: 44974a09b01c79adb9637a5dff38539598a76737
 ** Merge commit sha: acecf073764f87bfadb64c598703458d344b39f4
 **/
 include/odp/api/spec/ipsec.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
diff mbox series

Patch

diff --git a/include/odp/api/spec/ipsec.h b/include/odp/api/spec/ipsec.h
index 1060a3ee2..08533d80d 100644
--- a/include/odp/api/spec/ipsec.h
+++ b/include/odp/api/spec/ipsec.h
@@ -983,6 +983,20 @@  typedef struct odp_ipsec_op_flag_t {
  * These may be used to override some SA level options
  */
 typedef struct odp_ipsec_out_opt_t {
+	/** Union of all flag bits */
+	union {
+		/** Option flags. Set flag for those options that are
+		 *  used, all other options are ignored. */
+		struct {
+			/** Use fragmentation mode option */
+			uint32_t frag_mode: 1;
+
+		} flag;
+
+		/** All flag bits */
+		uint32_t all_flags;
+	};
+
 	/** Fragmentation mode */
 	odp_ipsec_frag_mode_t frag_mode;