> -----Original Message-----
> From: ext Ola Liljedahl [mailto:ola.liljed...@linaro.org]
> Sent: Tuesday, February 03, 2015 10:49 AM
> To: Savolainen, Petri (NSN - FI/Espoo)
> Cc: lng-odp@lists.linaro.org
> Subject: Re: [lng-odp] [PATCH] api: odp_event.h: remove
> ODP_EVENT_TYPE_INVALID
> 
> On 3 February 2015 at 09:15, Savolainen, Petri (NSN - FI/Espoo)
> <petri.savolai...@nsn.com> wrote:
> >
> >
> >> -----Original Message-----
> >> From: lng-odp-boun...@lists.linaro.org [mailto:lng-odp-
> >> boun...@lists.linaro.org] On Behalf Of ext Ola Liljedahl
> >> Sent: Monday, February 02, 2015 6:01 PM
> >> To: lng-odp@lists.linaro.org
> >> Subject: [lng-odp] [PATCH] api: odp_event.h: remove
> ODP_EVENT_TYPE_INVALID
> >>
> >> Remove ODP_EVENT_TYPE_INVALID from odp_event.h.
> >> Update description of odp_event_type(), is does not return
> >> ODP_EVENT_TYPE_INVALID.
> >> Remove ODP_POOL_TYPE_INVALID from odp_pool.h. It was defined to
> >> ODP_EVENT_TYPE_INVALID.
> >>
> >> Signed-off-by: Ola Liljedahl <ola.liljed...@linaro.org>
> >> ---
> >> (This document/code contribution attached is provided under the terms
> of
> >> agreement LES-LTM-21309)
> >>
> >>  include/odp/api/event.h                               | 9 ++-------
> >>  include/odp/api/pool.h                                | 2 --
> >>  platform/linux-generic/include/odp/plat/event_types.h | 1 -
> >>  3 files changed, 2 insertions(+), 10 deletions(-)
> >>
> >> diff --git a/include/odp/api/event.h b/include/odp/api/event.h
> >> index 50c031a..ce97bdc 100644
> >> --- a/include/odp/api/event.h
> >> +++ b/include/odp/api/event.h
> >> @@ -36,11 +36,6 @@ extern "C" {
> >>   */
> >>
> >>  /**
> >> - * @def ODP_EVENT_TYPE_INVALID
> >> - * Invalid event type
> >> - */
> >> -
> >> -/**
> >>   * @def ODP_EVENT_BUFFER
> >>   * Buffer event
> >>   */
> >> @@ -61,11 +56,11 @@ extern "C" {
> >>   */
> >>
> >>  /**
> >> - * Event type
> >> + * Return type of event
> >
> > Don't change the Doxygen brief description. Almost every function return
> something, no need to mention that in the brief description. The detail
> description is there for full description/sentences.
> Most functions have side effects and it is the side effect you are
> after. What they return is normally just a status code or other
> information on how successful they were (e.g. number of items
> processed or written etc) in that side effect. This function *only*
> returns something with no side effects. Thus the difference in
> description.

When you browse or search through the doxygen API documentation. It would be 
nice to find the keyword pair "event type" easily (and consistently).

Currently most "get" type functions are labeled either "Type_x param_y" or "Get 
type_x param_y" (in brief description). You can change it to "Get event type", 
or leave as is. But do not change to "Return param_y of type_x".

-Petri

 

> 
> >
> > Otherwise OK.
> >
> > -Petri
> >
> >
> >>   *
> >>   * @param event    Event handle
> >>   *
> >> - * @return Event type or ODP_EVENT_TYPE_INVALID
> >> + * @return Event type
> >>   */
> >>  int odp_event_type(odp_event_t event);
> >>
> >> diff --git a/include/odp/api/pool.h b/include/odp/api/pool.h
> >> index 1582102..d09d92e 100644
> >> --- a/include/odp/api/pool.h
> >> +++ b/include/odp/api/pool.h
> >> @@ -79,8 +79,6 @@ typedef struct odp_pool_param_t {
> >>
> >>  } odp_pool_param_t;
> >>
> >> -/** Invalid pool type */
> >> -#define ODP_POOL_TYPE_INVALID ODP_EVENT_TYPE_INVALID
> >>  /** Packet pool*/
> >>  #define ODP_POOL_PACKET       ODP_EVENT_PACKET
> >>  /** Buffer pool */
> >> diff --git a/platform/linux-generic/include/odp/plat/event_types.h
> >> b/platform/linux-generic/include/odp/plat/event_types.h
> >> index 4a0756b..c98d416 100644
> >> --- a/platform/linux-generic/include/odp/plat/event_types.h
> >> +++ b/platform/linux-generic/include/odp/plat/event_types.h
> >> @@ -30,7 +30,6 @@ typedef odp_buffer_t odp_event_t;
> >>
> >>  #define ODP_EVENT_INVALID ODP_BUFFER_INVALID
> >>
> >> -#define ODP_EVENT_TYPE_INVALID (-1)
> >>  #define ODP_EVENT_BUFFER         1
> >>  #define ODP_EVENT_PACKET         2
> >>  #define ODP_EVENT_TIMEOUT        3
> >> --
> >> 1.9.1
> >>
> >>
> >> _______________________________________________
> >> 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

Reply via email to