From dbe136433789708d959eab52683b956110ef0785 Mon Sep 17 00:00:00 2001 From: Dmitry Eremin-Solenikov Date: Wed, 10 May 2017 21:53:38 +0300 Subject: [PATCH 1/2] api: ipsec: add AH capability RFC4301 marks AH support as MAY instead of MUST. Some platforms might skip implementing AH. Thus we should provide capability to allow applications to check if AH is actually implemented or not. Signed-off-by: Dmitry Eremin-Solenikov --- include/odp/api/spec/ipsec.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/odp/api/spec/ipsec.h b/include/odp/api/spec/ipsec.h index e83494d36c9..150e6912a76 100644 --- a/include/odp/api/spec/ipsec.h +++ b/include/odp/api/spec/ipsec.h @@ -244,6 +244,9 @@ typedef struct odp_ipsec_capability_t { /** Inline IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) support */ odp_support_t op_mode_inline; + /** IP Authenticated Header (ODP_IPSEC_AH) support */ + odp_support_t proto_ah; + /** * Support of pipelined classification (ODP_IPSEC_PIPELINE_CLS) of * resulting inbound packets From 5518256ecdf6ccf2be019c2173d963decd675fb7 Mon Sep 17 00:00:00 2001 From: Dmitry Eremin-Solenikov Date: Wed, 10 May 2017 23:50:18 +0300 Subject: [PATCH 2/2] api: ipsec: split INLINE capability into in and out pair Unlike SYNC/ASYNC operation modes, it well might be that the implementation provides only INLINE support only for inbound or outbound packets. Let's split the capability into two new caps. Signed-off-by: Dmitry Eremin-Solenikov --- include/odp/api/spec/ipsec.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/include/odp/api/spec/ipsec.h b/include/odp/api/spec/ipsec.h index 150e6912a76..daef2f2da3b 100644 --- a/include/odp/api/spec/ipsec.h +++ b/include/odp/api/spec/ipsec.h @@ -241,8 +241,17 @@ typedef struct odp_ipsec_capability_t { */ odp_support_t op_mode_async; - /** Inline IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) support */ - odp_support_t op_mode_inline; + /** + * Inline inbound IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) + * support + */ + odp_support_t op_mode_inline_in; + + /** + * Inline outgoing IPSEC operation mode (ODP_IPSEC_OP_MODE_INLINE) + * support + */ + odp_support_t op_mode_inline_out; /** IP Authenticated Header (ODP_IPSEC_AH) support */ odp_support_t proto_ah;