Lines Matching refs:trunks
40 struct hns_roce_buf_list *trunks; in hns_roce_buf_free() local
46 trunks = buf->trunk_list; in hns_roce_buf_free()
47 if (trunks) { in hns_roce_buf_free()
51 trunks[i].buf, trunks[i].map); in hns_roce_buf_free()
53 kfree(trunks); in hns_roce_buf_free()
70 struct hns_roce_buf_list *trunks; in hns_roce_buf_alloc() local
96 trunks = kcalloc(ntrunk, sizeof(*trunks), gfp_flags); in hns_roce_buf_alloc()
97 if (!trunks) { in hns_roce_buf_alloc()
105 trunks[i].buf = dma_alloc_coherent(hr_dev->dev, trunk_size, in hns_roce_buf_alloc()
106 &trunks[i].map, gfp_flags); in hns_roce_buf_alloc()
107 if (!trunks[i].buf) in hns_roce_buf_alloc()
119 trunks[i].buf, trunks[i].map); in hns_roce_buf_alloc()
121 kfree(trunks); in hns_roce_buf_alloc()
127 buf->trunk_list = trunks; in hns_roce_buf_alloc()