diff options
author | Jere Leppänen <jere.leppanen@nokia.com> | 2023-01-13 15:45:08 +0200 |
---|---|---|
committer | Matias Elo <matias.elo@nokia.com> | 2023-04-12 13:38:07 +0300 |
commit | c4128321423e7774190f7f5e65e0650ff64f6ca5 (patch) | |
tree | 9aa2f6ffabb2b2d51c9ae587a0def5c1392914d7 /include | |
parent | 78a78044c45740e7c915e7201143fa009decda88 (diff) |
api: cls: allow CoS pool to be set to ODP_POOL_INVALID
As a convenience, allow CoS pool to be set to ODP_POOL_INVALID, in
which case the originating pktin pool is used.
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com>
Reviewed-by: Kiran Kumar K <kirankumark@marvell.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/odp/api/spec/classification.h | 12 | ||||
-rw-r--r-- | include/odp/api/spec/packet_io.h | 2 |
2 files changed, 11 insertions, 3 deletions
diff --git a/include/odp/api/spec/classification.h b/include/odp/api/spec/classification.h index 723509fd5..d288e5956 100644 --- a/include/odp/api/spec/classification.h +++ b/include/odp/api/spec/classification.h @@ -671,7 +671,15 @@ typedef struct odp_cls_cos_param { odp_pktin_hash_proto_t hash_proto; }; }; - /** Pool associated with CoS */ + /** Pool associated with CoS + * + * May be set to ODP_POOL_INVALID, in which case the default pool of + * the originating packet input is used (@see odp_pktio_open()). If + * there is no originating packet input (e.g. with lookaside IPsec), + * then this parameter must be set to a valid pool. + * + * Default is ODP_POOL_INVALID. + */ odp_pool_t pool; #if ODP_DEPRECATED_API @@ -1017,7 +1025,7 @@ int odp_cls_cos_pool_set(odp_cos_t cos, odp_pool_t pool_id); * @param cos CoS handle * * @retval pool handle of the associated pool -* @retval ODP_POOL_INVALID if no associated pool found or in case of an error +* @retval ODP_POOL_INVALID on failure, or if the pool has not been set */ odp_pool_t odp_cls_cos_pool(odp_cos_t cos); diff --git a/include/odp/api/spec/packet_io.h b/include/odp/api/spec/packet_io.h index 9a6117cee..e1cf1d675 100644 --- a/include/odp/api/spec/packet_io.h +++ b/include/odp/api/spec/packet_io.h @@ -103,7 +103,7 @@ extern "C" { * the odp_pktio_default_cos_set() routine, or because a matching PMR * assigned the packet to a specific CoS. The default pool specified * here is applicable only for those packets that are not assigned to a - * more specific CoS. + * more specific CoS that specifies another pool. * * @see odp_pktio_start(), odp_pktio_stop(), odp_pktio_close() */ |