pasted to wrong on this v2 - meant odp_queue_destroy On 5 March 2015 at 13:57, Mike Holmes <[email protected]> wrote:
> > > On 5 March 2015 at 10:57, Bill Fischofer <[email protected]> > wrote: > >> >> >> On Thu, Mar 5, 2015 at 3:47 AM, Ola Liljedahl <[email protected]> >> wrote: >> >>> Free queue and timeouts, destroy timeout pool before termination. >>> https://bugs.linaro.org/show_bug.cgi?id=1285 >>> >>> Signed-off-by: Ola Liljedahl <[email protected]> >>> >> >> Reviewed-and-tested-by: Bill Fischofer <[email protected]> >> >> >>> --- >>> (This document/code contribution attached is provided under the terms of >>> agreement LES-LTM-21309) >>> >>> Removed reference to Linaro CARDS as this is internal. >>> >>> test/validation/odp_timer.c | 9 +++++++++ >>> 1 file changed, 9 insertions(+) >>> >>> diff --git a/test/validation/odp_timer.c b/test/validation/odp_timer.c >>> index 88af61b..3e83367 100644 >>> --- a/test/validation/odp_timer.c >>> +++ b/test/validation/odp_timer.c >>> @@ -336,6 +336,11 @@ static void *worker_entrypoint(void *arg) >>> if (ev != ODP_EVENT_INVALID) >>> CU_FAIL("Unexpected event received"); >>> >>> + odp_queue_destroy(queue); >>> + for (i = 0; i < NTIMERS; i++) { >>> + if (tt[i].ev != ODP_EVENT_INVALID) >>> + >>> odp_timeout_free(odp_timeout_from_event(tt[i].ev)); >>> + } >>> LOG_DBG("Thread %u: exiting\n", thr); >>> return NULL; >>> } >>> @@ -426,6 +431,10 @@ static void test_odp_timer_all(void) >>> /* Destroy timer pool, all timers must have been freed */ >>> odp_timer_pool_destroy(tp); >>> >> > Still need to set > (void) odp_timer_pool_destroy(tp); > or > check the return code. > Else where in this file the explicit intention to ignore a return code is > signaled with (void) > > > >> >>> + /* Destroy timeout pool, all timeouts must have been freed */ >>> + int rc = odp_pool_destroy(tbp); >>> + CU_ASSERT(rc == 0); >>> + >>> CU_PASS("ODP timer test"); >>> } >>> >>> -- >>> 1.9.1 >>> >>> >>> _______________________________________________ >>> lng-odp mailing list >>> [email protected] >>> http://lists.linaro.org/mailman/listinfo/lng-odp >>> >> >> >> _______________________________________________ >> lng-odp mailing list >> [email protected] >> http://lists.linaro.org/mailman/listinfo/lng-odp >> >> > > > -- > Mike Holmes > Technical Manager - Linaro Networking Group > Linaro.org <http://www.linaro.org/> *│ *Open source software for ARM SoCs > > > -- Mike Holmes Technical Manager - Linaro Networking Group Linaro.org <http://www.linaro.org/> *│ *Open source software for ARM SoCs
_______________________________________________ lng-odp mailing list [email protected] http://lists.linaro.org/mailman/listinfo/lng-odp
