diff mbox

[v1,5/5] Classification: APIs deferred from ODP v1.0

Message ID 1416560024-20661-5-git-send-email-bala.manoharan@linaro.org
State Superseded
Headers show

Commit Message

Balasubramanian Manoharan Nov. 21, 2014, 8:53 a.m. UTC
This patch removes Classification APIs which have been deferred from ODP v1.0
The following is the list of the deferred APIs
* odp_cos_set_queue_group
* odp_cos_set_pool
* odp_cos_set_headroom
* odp_cos_flow_set
* odp_cos_flow_is_set
* odp_cos_class_flow_signature
* odp_cos_port_flow_signature

Signed-off-by: Balasubramanian Manoharan <bala.manoharan@linaro.org>
---
 .../linux-generic/include/api/odp_classification.h | 96 ----------------------
 1 file changed, 96 deletions(-)

Comments

Mike Holmes Nov. 25, 2014, 8:21 p.m. UTC | #1
Bala

Can this patch be posted with just the clean up to the implementation so
that it builds ?
It gets us closer to the 1.0 API then.

Currently
odp_classification.c:30:5: error: no previous prototype for
'odp_cos_set_queue_group' [-Werror=missing-prototypes]
 int odp_cos_set_queue_group(odp_cos_t cos_id, odp_queue_group_t
queue_group_id)
     ^
odp_classification.c:38:5: error: no previous prototype for
'odp_cos_set_pool' [-Werror=missing-prototypes]
 int odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t pool_id)
     ^
odp_classification.c:85:5: error: no previous prototype for
'odp_cos_set_headroom' [-Werror=missing-prototypes]
 int odp_cos_set_headroom(odp_cos_t cos_id, size_t req_room)
     ^
odp_classification.c:122:1: error: no previous prototype for
'odp_cos_class_flow_signature' [-Werror=missing-prototypes]
 odp_cos_class_flow_signature(odp_cos_t cos_id,
 ^
odp_classification.c:131:1: error: no previous prototype for
'odp_cos_port_flow_signature' [-Werror=missing-prototypes]
 odp_cos_port_flow_signature(odp_pktio_t pktio_in,
 ^


Mike

On 25 November 2014 at 03:11, Savolainen, Petri (NSN - FI/Espoo) <
petri.savolainen@nsn.com> wrote:

> Reviewed-by: Petri Savolainen <petri.savolainen@linaro.org>
>
>
> > -----Original Message-----
> > From: lng-odp-bounces@lists.linaro.org [mailto:lng-odp-
> > bounces@lists.linaro.org] On Behalf Of ext Balasubramanian Manoharan
> > Sent: Friday, November 21, 2014 10:54 AM
> > To: lng-odp@lists.linaro.org
> > Subject: [lng-odp] [PATCH v1 5/5] Classification: APIs deferred from ODP
> > v1.0
> >
> > This patch removes Classification APIs which have been deferred from ODP
> > v1.0
> > The following is the list of the deferred APIs
> > * odp_cos_set_queue_group
> > * odp_cos_set_pool
> > * odp_cos_set_headroom
> > * odp_cos_flow_set
> > * odp_cos_flow_is_set
> > * odp_cos_class_flow_signature
> > * odp_cos_port_flow_signature
> >
> > Signed-off-by: Balasubramanian Manoharan <bala.manoharan@linaro.org>
> > ---
> >  .../linux-generic/include/api/odp_classification.h | 96
> -----------------
> > -----
> >  1 file changed, 96 deletions(-)
> >
> > diff --git a/platform/linux-generic/include/api/odp_classification.h
> > b/platform/linux-generic/include/api/odp_classification.h
> > index 091b10d..64ad73f 100644
> > --- a/platform/linux-generic/include/api/odp_classification.h
> > +++ b/platform/linux-generic/include/api/odp_classification.h
> > @@ -113,33 +113,6 @@ int odp_cos_destroy(odp_cos_t cos_id);
> >  int odp_cos_set_queue(odp_cos_t cos_id, odp_queue_t queue_id);
> >
> >  /**
> > - * Assign a homogenous queue-group to a class-of-service.
> > - *
> > - * @param[in]        cos_id          class-of-service instance
> > - * @param[in]        queue_group_id  Identifier of the queue group to
> > receive packets
> > - *                           associated with this class of service.
> > - *
> > - * @return                   0 on success, -1 on error.
> > - */
> > -int odp_cos_set_queue_group(odp_cos_t cos_id,
> > -                         odp_queue_group_t queue_group_id);
> > -
> > -/**
> > - * Assign packet buffer pool for specific class-of-service
> > - *
> > - * @param[in]        cos_id          class-of-service instance.
> > - * @param[in]        pool_id         Buffer pool identifier where all
> > packet buffers
> > - *                           will be sourced to store packet that
> > - *                           belong to this class of service.
> > - *
> > - * @return                   0 on success, -1 on error.
> > - *
> > - * @note Optional.
> > - */
> > -int odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t pool_id);
> > -
> > -
> > -/**
> >   * Assign packet drop policy for specific class-of-service
> >   *
> >   * @param[in]        cos_id          class-of-service instance.
> > @@ -206,21 +179,6 @@ int odp_pktio_set_skip(odp_pktio_t pktio_in, size_t
> > offset);
> >  int odp_pktio_set_headroom(odp_pktio_t pktio_in, size_t headroom);
> >
> >  /**
> > - * Specify per-cos buffer headroom
> > - *
> > - * @param[in]        cos_id          Class-of-service instance
> > - * @param[in]        headroom        Number of bytes of space preceding
> packet
> > - *                           data to reserve for use as headroom.
> > - *                           Must not exceed the implementation
> > - *                           defined ODP_PACKET_MAX_HEADROOM.
> > - *
> > - * @return                   0 on success, -1 on error.
> > - *
> > - * @note Optional.
> > - */
> > -int odp_cos_set_headroom(odp_cos_t cos_id, size_t headroom);
> > -
> > -/**
> >   * Request to override per-port class of service
> >   * based on Layer-2 priority field if present.
> >   *
> > @@ -266,60 +224,6 @@ int odp_cos_with_l3_qos(odp_pktio_t pktio_in,
> >  typedef uint16_t odp_cos_flow_set_t;
> >
> >  /**
> > - * Set a member of the flow signature fields data set
> > - */
> > -static inline
> > -odp_cos_flow_set_t odp_cos_flow_set(odp_cos_flow_set_t set,
> > -                                 odp_cos_hdr_flow_fields_e field)
> > -{
> > -     return set | (1U << field);
> > -}
> > -
> > -/**
> > - * Test a member of the flow signature fields data set
> > - */
> > -static inline bool
> > -odp_cos_flow_is_set(odp_cos_flow_set_t set, odp_cos_hdr_flow_fields_e
> > field)
> > -{
> > -     return (set & (1U << field)) != 0;
> > -}
> > -
> > -/**
> > - * Set up set of headers used to calculate a flow signature
> > - * based on class-of-service.
> > - *
> > - * @param[in]        cos_id          Class of service instance
> identifier
> > - * @param[in]        req_data_set    Requested data-set for
> > - *                           flow signature calculation
> > - *
> > - * @return                   Data-set that was successfully applied.
> > - *                           All-zeros data set indicates a failure to
> > - *                           assign any of the requested fields,
> > - *                           or other error.
> > - * @note Optional.
> > - */
> > -odp_cos_flow_set_t
> > -odp_cos_class_flow_signature(odp_cos_t cos_id,
> > -                          odp_cos_flow_set_t req_data_set);
> > -
> > -/**
> > - * Set up set of headers used to calculate a flow signature
> > - * based on ingress port.
> > - *
> > - * @param[in]        pktio_in        Ingress port identifier
> > - * @param[in]        req_data_set    Requested data-set for
> > - *                           flow signature calculation
> > - *
> > - * @return                   Data-set that was successfully applied.
> > - *                           An all-zeros data-set indicates a failure
> to
> > - *                           assign any of the requested fields,
> > - *                           or other error.
> > - */
> > -odp_cos_flow_set_t
> > -odp_cos_port_flow_signature(odp_pktio_t pktio_in,
> > -                         odp_cos_flow_set_t req_data_set);
> > -
> > -/**
> >   * PMR - Packet Matching Rule
> >   * Up to 32 bit of ternary matching of one of the available header
> fields
> >   */
> > --
> > 2.0.1.472.g6f92e5f
> >
> >
> > _______________________________________________
> > lng-odp mailing list
> > lng-odp@lists.linaro.org
> > http://lists.linaro.org/mailman/listinfo/lng-odp
>
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> http://lists.linaro.org/mailman/listinfo/lng-odp
>
Balasubramanian Manoharan Nov. 26, 2014, 5:35 a.m. UTC | #2
Hi Mike,

As you know these classification patches was submitted as being
interdependent on each other.
But sure I can redo this specific patch to be independently compilable unit.

Also it would be great if I could get review comments on classification
implementation patches so that I can fix any changes in the next revision.

Regards,
Bala

On 26 November 2014 01:51, Mike Holmes <mike.holmes@linaro.org> wrote:

> Bala
>
> Can this patch be posted with just the clean up to the implementation so
> that it builds ?
> It gets us closer to the 1.0 API then.
>
> Currently
> odp_classification.c:30:5: error: no previous prototype for
> 'odp_cos_set_queue_group' [-Werror=missing-prototypes]
>  int odp_cos_set_queue_group(odp_cos_t cos_id, odp_queue_group_t
> queue_group_id)
>      ^
> odp_classification.c:38:5: error: no previous prototype for
> 'odp_cos_set_pool' [-Werror=missing-prototypes]
>  int odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t pool_id)
>      ^
> odp_classification.c:85:5: error: no previous prototype for
> 'odp_cos_set_headroom' [-Werror=missing-prototypes]
>  int odp_cos_set_headroom(odp_cos_t cos_id, size_t req_room)
>      ^
> odp_classification.c:122:1: error: no previous prototype for
> 'odp_cos_class_flow_signature' [-Werror=missing-prototypes]
>  odp_cos_class_flow_signature(odp_cos_t cos_id,
>  ^
> odp_classification.c:131:1: error: no previous prototype for
> 'odp_cos_port_flow_signature' [-Werror=missing-prototypes]
>  odp_cos_port_flow_signature(odp_pktio_t pktio_in,
>  ^
>
>
> Mike
>
> On 25 November 2014 at 03:11, Savolainen, Petri (NSN - FI/Espoo) <
> petri.savolainen@nsn.com> wrote:
>
>> Reviewed-by: Petri Savolainen <petri.savolainen@linaro.org>
>>
>>
>> > -----Original Message-----
>> > From: lng-odp-bounces@lists.linaro.org [mailto:lng-odp-
>> > bounces@lists.linaro.org] On Behalf Of ext Balasubramanian Manoharan
>> > Sent: Friday, November 21, 2014 10:54 AM
>> > To: lng-odp@lists.linaro.org
>> > Subject: [lng-odp] [PATCH v1 5/5] Classification: APIs deferred from ODP
>> > v1.0
>> >
>> > This patch removes Classification APIs which have been deferred from ODP
>> > v1.0
>> > The following is the list of the deferred APIs
>> > * odp_cos_set_queue_group
>> > * odp_cos_set_pool
>> > * odp_cos_set_headroom
>> > * odp_cos_flow_set
>> > * odp_cos_flow_is_set
>> > * odp_cos_class_flow_signature
>> > * odp_cos_port_flow_signature
>> >
>> > Signed-off-by: Balasubramanian Manoharan <bala.manoharan@linaro.org>
>> > ---
>> >  .../linux-generic/include/api/odp_classification.h | 96
>> -----------------
>> > -----
>> >  1 file changed, 96 deletions(-)
>> >
>> > diff --git a/platform/linux-generic/include/api/odp_classification.h
>> > b/platform/linux-generic/include/api/odp_classification.h
>> > index 091b10d..64ad73f 100644
>> > --- a/platform/linux-generic/include/api/odp_classification.h
>> > +++ b/platform/linux-generic/include/api/odp_classification.h
>> > @@ -113,33 +113,6 @@ int odp_cos_destroy(odp_cos_t cos_id);
>> >  int odp_cos_set_queue(odp_cos_t cos_id, odp_queue_t queue_id);
>> >
>> >  /**
>> > - * Assign a homogenous queue-group to a class-of-service.
>> > - *
>> > - * @param[in]        cos_id          class-of-service instance
>> > - * @param[in]        queue_group_id  Identifier of the queue group to
>> > receive packets
>> > - *                           associated with this class of service.
>> > - *
>> > - * @return                   0 on success, -1 on error.
>> > - */
>> > -int odp_cos_set_queue_group(odp_cos_t cos_id,
>> > -                         odp_queue_group_t queue_group_id);
>> > -
>> > -/**
>> > - * Assign packet buffer pool for specific class-of-service
>> > - *
>> > - * @param[in]        cos_id          class-of-service instance.
>> > - * @param[in]        pool_id         Buffer pool identifier where all
>> > packet buffers
>> > - *                           will be sourced to store packet that
>> > - *                           belong to this class of service.
>> > - *
>> > - * @return                   0 on success, -1 on error.
>> > - *
>> > - * @note Optional.
>> > - */
>> > -int odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t pool_id);
>> > -
>> > -
>> > -/**
>> >   * Assign packet drop policy for specific class-of-service
>> >   *
>> >   * @param[in]        cos_id          class-of-service instance.
>> > @@ -206,21 +179,6 @@ int odp_pktio_set_skip(odp_pktio_t pktio_in, size_t
>> > offset);
>> >  int odp_pktio_set_headroom(odp_pktio_t pktio_in, size_t headroom);
>> >
>> >  /**
>> > - * Specify per-cos buffer headroom
>> > - *
>> > - * @param[in]        cos_id          Class-of-service instance
>> > - * @param[in]        headroom        Number of bytes of space
>> preceding packet
>> > - *                           data to reserve for use as headroom.
>> > - *                           Must not exceed the implementation
>> > - *                           defined ODP_PACKET_MAX_HEADROOM.
>> > - *
>> > - * @return                   0 on success, -1 on error.
>> > - *
>> > - * @note Optional.
>> > - */
>> > -int odp_cos_set_headroom(odp_cos_t cos_id, size_t headroom);
>> > -
>> > -/**
>> >   * Request to override per-port class of service
>> >   * based on Layer-2 priority field if present.
>> >   *
>> > @@ -266,60 +224,6 @@ int odp_cos_with_l3_qos(odp_pktio_t pktio_in,
>> >  typedef uint16_t odp_cos_flow_set_t;
>> >
>> >  /**
>> > - * Set a member of the flow signature fields data set
>> > - */
>> > -static inline
>> > -odp_cos_flow_set_t odp_cos_flow_set(odp_cos_flow_set_t set,
>> > -                                 odp_cos_hdr_flow_fields_e field)
>> > -{
>> > -     return set | (1U << field);
>> > -}
>> > -
>> > -/**
>> > - * Test a member of the flow signature fields data set
>> > - */
>> > -static inline bool
>> > -odp_cos_flow_is_set(odp_cos_flow_set_t set, odp_cos_hdr_flow_fields_e
>> > field)
>> > -{
>> > -     return (set & (1U << field)) != 0;
>> > -}
>> > -
>> > -/**
>> > - * Set up set of headers used to calculate a flow signature
>> > - * based on class-of-service.
>> > - *
>> > - * @param[in]        cos_id          Class of service instance
>> identifier
>> > - * @param[in]        req_data_set    Requested data-set for
>> > - *                           flow signature calculation
>> > - *
>> > - * @return                   Data-set that was successfully applied.
>> > - *                           All-zeros data set indicates a failure to
>> > - *                           assign any of the requested fields,
>> > - *                           or other error.
>> > - * @note Optional.
>> > - */
>> > -odp_cos_flow_set_t
>> > -odp_cos_class_flow_signature(odp_cos_t cos_id,
>> > -                          odp_cos_flow_set_t req_data_set);
>> > -
>> > -/**
>> > - * Set up set of headers used to calculate a flow signature
>> > - * based on ingress port.
>> > - *
>> > - * @param[in]        pktio_in        Ingress port identifier
>> > - * @param[in]        req_data_set    Requested data-set for
>> > - *                           flow signature calculation
>> > - *
>> > - * @return                   Data-set that was successfully applied.
>> > - *                           An all-zeros data-set indicates a failure
>> to
>> > - *                           assign any of the requested fields,
>> > - *                           or other error.
>> > - */
>> > -odp_cos_flow_set_t
>> > -odp_cos_port_flow_signature(odp_pktio_t pktio_in,
>> > -                         odp_cos_flow_set_t req_data_set);
>> > -
>> > -/**
>> >   * PMR - Packet Matching Rule
>> >   * Up to 32 bit of ternary matching of one of the available header
>> fields
>> >   */
>> > --
>> > 2.0.1.472.g6f92e5f
>> >
>> >
>> > _______________________________________________
>> > lng-odp mailing list
>> > lng-odp@lists.linaro.org
>> > http://lists.linaro.org/mailman/listinfo/lng-odp
>>
>> _______________________________________________
>> lng-odp mailing list
>> lng-odp@lists.linaro.org
>> http://lists.linaro.org/mailman/listinfo/lng-odp
>>
>
>
>
> --
> *Mike Holmes*
> Linaro  Sr Technical Manager
> LNG - ODP
>
diff mbox

Patch

diff --git a/platform/linux-generic/include/api/odp_classification.h b/platform/linux-generic/include/api/odp_classification.h
index 091b10d..64ad73f 100644
--- a/platform/linux-generic/include/api/odp_classification.h
+++ b/platform/linux-generic/include/api/odp_classification.h
@@ -113,33 +113,6 @@  int odp_cos_destroy(odp_cos_t cos_id);
 int odp_cos_set_queue(odp_cos_t cos_id, odp_queue_t queue_id);
 
 /**
- * Assign a homogenous queue-group to a class-of-service.
- *
- * @param[in]	cos_id		class-of-service instance
- * @param[in]	queue_group_id	Identifier of the queue group to receive packets
- *				associated with this class of service.
- *
- * @return			0 on success, -1 on error.
- */
-int odp_cos_set_queue_group(odp_cos_t cos_id,
-			    odp_queue_group_t queue_group_id);
-
-/**
- * Assign packet buffer pool for specific class-of-service
- *
- * @param[in]	cos_id		class-of-service instance.
- * @param[in]	pool_id		Buffer pool identifier where all packet buffers
- *				will be sourced to store packet that
- *				belong to this class of service.
- *
- * @return			0 on success, -1 on error.
- *
- * @note Optional.
- */
-int odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t pool_id);
-
-
-/**
  * Assign packet drop policy for specific class-of-service
  *
  * @param[in]	cos_id		class-of-service instance.
@@ -206,21 +179,6 @@  int odp_pktio_set_skip(odp_pktio_t pktio_in, size_t offset);
 int odp_pktio_set_headroom(odp_pktio_t pktio_in, size_t headroom);
 
 /**
- * Specify per-cos buffer headroom
- *
- * @param[in]	cos_id		Class-of-service instance
- * @param[in]	headroom	Number of bytes of space preceding packet
- *				data to reserve for use as headroom.
- *				Must not exceed the implementation
- *				defined ODP_PACKET_MAX_HEADROOM.
- *
- * @return			0 on success, -1 on error.
- *
- * @note Optional.
- */
-int odp_cos_set_headroom(odp_cos_t cos_id, size_t headroom);
-
-/**
  * Request to override per-port class of service
  * based on Layer-2 priority field if present.
  *
@@ -266,60 +224,6 @@  int odp_cos_with_l3_qos(odp_pktio_t pktio_in,
 typedef uint16_t odp_cos_flow_set_t;
 
 /**
- * Set a member of the flow signature fields data set
- */
-static inline
-odp_cos_flow_set_t odp_cos_flow_set(odp_cos_flow_set_t set,
-				    odp_cos_hdr_flow_fields_e field)
-{
-	return set | (1U << field);
-}
-
-/**
- * Test a member of the flow signature fields data set
- */
-static inline bool
-odp_cos_flow_is_set(odp_cos_flow_set_t set, odp_cos_hdr_flow_fields_e field)
-{
-	return (set & (1U << field)) != 0;
-}
-
-/**
- * Set up set of headers used to calculate a flow signature
- * based on class-of-service.
- *
- * @param[in]	cos_id		Class of service instance identifier
- * @param[in]	req_data_set	Requested data-set for
- *				flow signature calculation
- *
- * @return			Data-set that was successfully applied.
- *				All-zeros data set indicates a failure to
- *				assign any of the requested fields,
- *				or other error.
- * @note Optional.
- */
-odp_cos_flow_set_t
-odp_cos_class_flow_signature(odp_cos_t cos_id,
-			     odp_cos_flow_set_t req_data_set);
-
-/**
- * Set up set of headers used to calculate a flow signature
- * based on ingress port.
- *
- * @param[in]	pktio_in	Ingress port identifier
- * @param[in]	req_data_set	Requested data-set for
- *				flow signature calculation
- *
- * @return			Data-set that was successfully applied.
- *				An all-zeros data-set indicates a failure to
- *				assign any of the requested fields,
- *				or other error.
- */
-odp_cos_flow_set_t
-odp_cos_port_flow_signature(odp_pktio_t pktio_in,
-			    odp_cos_flow_set_t req_data_set);
-
-/**
  * PMR - Packet Matching Rule
  * Up to 32 bit of ternary matching of one of the available header fields
  */