mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
push down vector linearization to posix-aio-compat.c (Christoph Hellwig)
Make all AIO requests vectored and defer linearization until the actual I/O thread. This prepares for using native preadv/pwritev. Also enables asynchronous direct I/O by handling that case in the I/O thread. Qcow and qcow2 propably want to be adopted to directly deal with multi-segment requests, but that can be implemented later. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7020 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
c87c067293
commit
f141eafe28
7 changed files with 318 additions and 285 deletions
|
@ -27,11 +27,18 @@
|
|||
struct qemu_paiocb
|
||||
{
|
||||
int aio_fildes;
|
||||
void *aio_buf;
|
||||
union {
|
||||
struct iovec *aio_iov;
|
||||
void *aio_ioctl_buf;
|
||||
};
|
||||
int aio_niov;
|
||||
size_t aio_nbytes;
|
||||
#define aio_ioctl_cmd aio_nbytes /* for QEMU_PAIO_IOCTL */
|
||||
int ev_signo;
|
||||
off_t aio_offset;
|
||||
unsigned aio_flags;
|
||||
/* 512 byte alignment required for buffer, offset and length */
|
||||
#define QEMU_AIO_SECTOR_ALIGNED 0x01
|
||||
|
||||
/* private */
|
||||
TAILQ_ENTRY(qemu_paiocb) node;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue