Lines Matching refs:rsgl
657 struct af_alg_rsgl *rsgl, *tmp; in af_alg_free_areq_sgls() local
662 list_for_each_entry_safe(rsgl, tmp, &areq->rsgl_list, list) { in af_alg_free_areq_sgls()
663 atomic_sub(rsgl->sg_num_bytes, &ctx->rcvused); in af_alg_free_areq_sgls()
664 af_alg_free_sg(&rsgl->sgl); in af_alg_free_areq_sgls()
665 list_del(&rsgl->list); in af_alg_free_areq_sgls()
666 if (rsgl != &areq->first_rsgl) in af_alg_free_areq_sgls()
667 sock_kfree_s(sk, rsgl, sizeof(*rsgl)); in af_alg_free_areq_sgls()
1147 struct af_alg_rsgl *rsgl; in af_alg_get_rsgl() local
1159 rsgl = &areq->first_rsgl; in af_alg_get_rsgl()
1161 rsgl = sock_kmalloc(sk, sizeof(*rsgl), GFP_KERNEL); in af_alg_get_rsgl()
1162 if (unlikely(!rsgl)) in af_alg_get_rsgl()
1166 rsgl->sgl.npages = 0; in af_alg_get_rsgl()
1167 list_add_tail(&rsgl->list, &areq->rsgl_list); in af_alg_get_rsgl()
1170 err = af_alg_make_sg(&rsgl->sgl, &msg->msg_iter, seglen); in af_alg_get_rsgl()
1172 rsgl->sg_num_bytes = 0; in af_alg_get_rsgl()
1178 af_alg_link_sg(&areq->last_rsgl->sgl, &rsgl->sgl); in af_alg_get_rsgl()
1180 areq->last_rsgl = rsgl; in af_alg_get_rsgl()
1183 rsgl->sg_num_bytes = err; in af_alg_get_rsgl()