Lines Matching refs:sgs
23 struct scatterlist sgs[]; member
90 static void virtsnd_pcm_sg_from(struct scatterlist *sgs, int nsgs, u8 *data, in virtsnd_pcm_sg_from() argument
104 sg_phys(&sgs[idx]) + sgs[idx].length != page_to_phys(pg)) { in virtsnd_pcm_sg_from()
107 sg_set_page(&sgs[++idx], pg, pg_length, in virtsnd_pcm_sg_from()
110 sgs[idx].length += pg_length; in virtsnd_pcm_sg_from()
117 sg_mark_end(&sgs[idx]); in virtsnd_pcm_sg_from()
149 msg = kzalloc(struct_size(msg, sgs, sg_num + 2), GFP_KERNEL); in virtsnd_pcm_msg_alloc()
154 sg_init_one(&msg->sgs[PCM_MSG_SG_XFER], &msg->xfer, in virtsnd_pcm_msg_alloc()
156 sg_init_one(&msg->sgs[PCM_MSG_SG_STATUS], &msg->status, in virtsnd_pcm_msg_alloc()
159 virtsnd_pcm_sg_from(&msg->sgs[PCM_MSG_SG_DATA], sg_num, data, in virtsnd_pcm_msg_alloc()
217 &msg->sgs[PCM_MSG_SG_XFER], in virtsnd_pcm_msg_send()
218 &msg->sgs[PCM_MSG_SG_DATA], in virtsnd_pcm_msg_send()
219 &msg->sgs[PCM_MSG_SG_STATUS] in virtsnd_pcm_msg_send()