On 29 January 2015 at 17:46, Taras Kondratiuk
<taras.kondrat...@linaro.org> wrote:
> Hi
>
> We had a discussion recently about wrong ODP handles passed to API
> functions. As far as I remember we agreed that in this case behavior is
> undefined. What about passing xxx_INVALID values to API?
>
> Currently packet IO verification tests pass ODP_PKTIO_INVALID explicitly to
> some API functions and expect them to return error.
Unless specifically documented, ODP API calls do not support invalid
handles in any reliable or robust way. Specifying invalid parameters
leads to undefined behavior. If this is not public ODP documentation
(architecture, user's guide etc), we need to add it.

Some calls could support their specific ODP_XXX_INVALID handles as a
valid parameters with well-defined semantics. That should then be
documented in those calls. I am not aware of any such call though.

Petri requires calls on shared resources (e.g. shared memory, pools)
to be robust even when called with *stale* handles (because some other
thread might just have freed the shared resource).

>
> _______________________________________________
> 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