virtio-9p/xen-9p: move 9p specific bits to core 9p code

These bits aren't related to the transport so let's move them to the core
code.

Signed-off-by: Greg Kurz <groug@kaod.org>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
This commit is contained in:
Greg Kurz 2017-05-25 10:30:13 +02:00
parent 9964e96dc9
commit 506f327582
4 changed files with 10 additions and 14 deletions

View file

@ -243,14 +243,10 @@ static int xen_9pfs_receive(Xen9pfsRing *ring)
/* cannot fail, because we only handle one request per ring at a time */
pdu = pdu_alloc(&ring->priv->state);
pdu->size = le32_to_cpu(h.size_le);
pdu->id = h.id;
pdu->tag = le32_to_cpu(h.tag_le);
ring->out_size = le32_to_cpu(h.size_le);
ring->out_cons = cons + le32_to_cpu(h.size_le);
qemu_co_queue_init(&pdu->complete);
pdu_submit(pdu);
pdu_submit(pdu, &h);
return 0;
}