Applying for a Queue
Prepare the memory for the struct wd_queue queue, which can be set using a local variable. Pay attention to the restrictions on the local variable and memory clearing.
1 2 3 4 5 6 7 8 9 10 11 | struct wcrypto_paras *priv; struct wd_queue q; q = calloc(1, sizeof(struct wd_queue)); memset(&q, 0, sizeof(q)); q.capa.alg = WD_ZLIB; q->capa.latency = 0; q->capa.throughput = 0; priv = &q->capa.priv; priv->direction = comp_optype; wd_request_queue(&q); |
Parent topic: CoMP Synchronization Interface Usage Examples