On Thu, Jul 31, 2014 at 01:20:22AM +0800, Ming Lei wrote: > On Wed, Jul 30, 2014 at 10:00 PM, Paolo Bonzini <pbonz...@redhat.com> wrote: > > Il 30/07/2014 13:39, Ming Lei ha scritto: > >> This patch increases max event to 256 for the comming > >> virtio-blk multi virtqueue support. > >> > >> Signed-off-by: Ming Lei <ming....@canonical.com> > >> --- > >> block/linux-aio.c | 2 +- > >> 1 file changed, 1 insertion(+), 1 deletion(-) > > > > What makes the new magic number less magic than the old one? > > Just for supporting the coming multi virtqueue, otherwise it is > easy to trigger EAGAIN. > > Or do you have better idea to figure out a non-magic number?
The virtio-blk device knows how many requests can be in-flight at a time. laio_init() could take a size parameter. The messy thing is that the block layer is between the virtio-blk device and Linux AIO, so we'd need to pass that information down. Stefan
pgpVDlT80rRcr.pgp
Description: PGP signature