On 12 November 2014 18:55, Mike Holmes <[email protected]> wrote:

>
>
> On 12 November 2014 03:06, <[email protected]> wrote:
>
>> From: Alexandru Badicioiu <[email protected]>
>>
>> Required by crypto unit testing.
>>
>> Signed-off-by: Alexandru Badicioiu <[email protected]>
>> ---
>>  platform/linux-generic/odp_crypto.c |   22 ++++++++++++++++++++++
>>  1 files changed, 22 insertions(+), 0 deletions(-)
>>
>> diff --git a/platform/linux-generic/odp_crypto.c
>> b/platform/linux-generic/odp_crypto.c
>> index 1475437..596c717 100644
>> --- a/platform/linux-generic/odp_crypto.c
>> +++ b/platform/linux-generic/odp_crypto.c
>> @@ -13,6 +13,7 @@
>>  #include <odp_align.h>
>>  #include <odp_shared_memory.h>
>>  #include <odp_crypto_internal.h>
>> +#include <odp_debug_internal.h>
>>  #include <odp_hints.h>
>>  #include <odph_packet.h>
>>
>> @@ -467,3 +468,24 @@ odp_crypto_get_ses_create_compl_session(odp_buffer_t
>> completion_event,
>>         result = odp_buffer_addr(completion_event);
>>         *session = result->session;
>>  }
>> +
>> +void
>> +odp_crypto_set_operation_compl_ctx(odp_buffer_t completion_event
>> ODP_UNUSED,
>> +                                  void *ctx ODP_UNUSED)
>> +{
>> +       ODP_UNIMPLEMENTED();
>> +}
>> +
>> +void
>> +*odp_crypto_get_operation_compl_ctx(odp_buffer_t completion_event
>> ODP_UNUSED)
>> +{
>> +       ODP_UNIMPLEMENTED();
>> +       return NULL;
>>
>
> The documentation makes no mention of NULL being a possible error case,
> it just says "Returns user data"  The documentation should be improved
> with this patch submission to indicate the error case NULL with a new
> @retval
>
[Alex] NULL is not an error case, if the context was not set or it was set
to NULL. The only error case is when _get_ operation does not return what
was set with _set_.

>
>
>> +}
>> +
>> +odp_packet_t
>> +odp_crypto_get_operation_compl_packet(odp_buffer_t completion_event
>> ODP_UNUSED)
>> +{
>> +       ODP_UNIMPLEMENTED();
>> +       return ODP_PACKET_INVALID;
>>
>
> The documentation makes no mention of ODP_PACKET_INVALID being a possible
> error case, it just says "Returns Packet structure where data now resides"
> The documentation should be improved with this patch submission to indicate
> the error case ODP_PACKET_INVALID with a new @retv
>
[Alex] This is also debatable and NULL may not represent an error case
related to this call only. If operation or operation submission fails NULL
is not an error case.

>
>
>
>> +}
>> --
>> 1.7.3.4
>>
>>
>> _______________________________________________
>> lng-odp mailing list
>> [email protected]
>> http://lists.linaro.org/mailman/listinfo/lng-odp
>>
>
>
>
> --
> *Mike Holmes*
> Linaro  Sr Technical Manager
> LNG - ODP
>
_______________________________________________
lng-odp mailing list
[email protected]
http://lists.linaro.org/mailman/listinfo/lng-odp

Reply via email to