Message ID | 1435714761-23951-1-git-send-email-bill.fischofer@linaro.org |
---|---|
State | New |
Headers | show |
V3 posted incorporating review comments. On Fri, Jul 3, 2015 at 6:45 AM, Savolainen, Petri (Nokia - FI/Espoo) < petri.savolainen@nokia.com> wrote: > Patches 1, 2, 3 and 4 should be squashed during merge. Those change only > one thing: event type from int to odp_event_type_t. Those patches compile > because enum is int, but it's more logical that API changes are in sync > with implementation/tests. New APIs can be introduced in steps, but changes > to old ones should be in sync. > > Same thing for patches 5 and 6. Those change pool type from int to > odp_pool_type_t. Also, after patch 5 ODP_POOL_XXX are defined in two place > (old #defines and the new enum). > > > With two minor corrections (7 and 8) and patch squashing > > Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com> > > > > > > -----Original Message----- > > From: lng-odp [mailto:lng-odp-bounces@lists.linaro.org] On Behalf Of ext > > Bill Fischofer > > Sent: Wednesday, July 01, 2015 4:39 AM > > To: lng-odp@lists.linaro.org > > Subject: [lng-odp] [API-NEXT PATCHv2 01/10] linux-generic: event: convert > > event types to typedef enum > > > > Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org> > > --- > > platform/linux-generic/include/odp/plat/event_types.h | 13 +++++++++---- > > 1 file changed, 9 insertions(+), 4 deletions(-) > > > > diff --git a/platform/linux-generic/include/odp/plat/event_types.h > > b/platform/linux-generic/include/odp/plat/event_types.h > > index d91937d..06b15cd 100644 > > --- a/platform/linux-generic/include/odp/plat/event_types.h > > +++ b/platform/linux-generic/include/odp/plat/event_types.h > > @@ -30,10 +30,15 @@ typedef ODP_HANDLE_T(odp_event_t); > > > > #define ODP_EVENT_INVALID _odp_cast_scalar(odp_event_t, 0xffffffff) > > > > -#define ODP_EVENT_BUFFER 1 > > -#define ODP_EVENT_PACKET 2 > > -#define ODP_EVENT_TIMEOUT 3 > > -#define ODP_EVENT_CRYPTO_COMPL 4 > > +/** > > + * Event types > > + */ > > +typedef enum odp_event_type_t { > > + ODP_EVENT_BUFFER = 1, > > + ODP_EVENT_PACKET = 2, > > + ODP_EVENT_TIMEOUT = 3, > > + ODP_EVENT_CRYPTO_COMPL = 4, > > +} odp_event_type_t; > > > > /** Get printable format of odp_event_t */ > > static inline uint64_t odp_event_to_u64(odp_event_t hdl) > > -- > > 2.1.4 > > > > _______________________________________________ > > lng-odp mailing list > > lng-odp@lists.linaro.org > > https://lists.linaro.org/mailman/listinfo/lng-odp >
diff --git a/platform/linux-generic/include/odp/plat/event_types.h b/platform/linux-generic/include/odp/plat/event_types.h index d91937d..06b15cd 100644 --- a/platform/linux-generic/include/odp/plat/event_types.h +++ b/platform/linux-generic/include/odp/plat/event_types.h @@ -30,10 +30,15 @@ typedef ODP_HANDLE_T(odp_event_t); #define ODP_EVENT_INVALID _odp_cast_scalar(odp_event_t, 0xffffffff) -#define ODP_EVENT_BUFFER 1 -#define ODP_EVENT_PACKET 2 -#define ODP_EVENT_TIMEOUT 3 -#define ODP_EVENT_CRYPTO_COMPL 4 +/** + * Event types + */ +typedef enum odp_event_type_t { + ODP_EVENT_BUFFER = 1, + ODP_EVENT_PACKET = 2, + ODP_EVENT_TIMEOUT = 3, + ODP_EVENT_CRYPTO_COMPL = 4, +} odp_event_type_t; /** Get printable format of odp_event_t */ static inline uint64_t odp_event_to_u64(odp_event_t hdl)
Signed-off-by: Bill Fischofer <bill.fischofer@linaro.org> --- platform/linux-generic/include/odp/plat/event_types.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-)