[LTP] [PATCH] crypto/af_alg02: use pthread_tryjoin_np() instead of pthread_kill()

Alexey Kodanev aleksei.kodanev@bell-sw.com
Fri Jul 16 15:35:08 CEST 2021


On 16.07.2021 16:21, Li Wang wrote:
> 
>          #define SALSA20_IV_SIZE       8
>          #define SALSA20_MIN_KEY_SIZE  16
>         +static int completed;
> 
>          static void *verify_encrypt(void *arg)
>          {
> 
> 
> But we still need to initialize '0' at the start of thread_B,
> in case of test running with '-i xx' parameter. Isn't it?
> 
>      tst_atomic_store(0, &completed);
> 

Yeah, right, and that's another reason to use pthread_tryjoin_np() :)

Because otherwise the thread resources not released... anyway we
could add pthread_join in the end of the run()...


> -- 
> Regards,
> Li Wang



More information about the ltp mailing list