Received: from [140.186.70.92] (port=38984 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PrpK8-0008IS-V2 for qemu-devel@nongnu.org; Tue, 22 Feb 2011 05:18:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PrpK7-0005b0-Hu for qemu-devel@nongnu.org; Tue, 22 Feb 2011 05:18:28 -0500 Received: from mx1.redhat.com ([209.132.183.28]:23252) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PrpK7-0005at-89 for qemu-devel@nongnu.org; Tue, 22 Feb 2011 05:18:27 -0500 From: Jes.Sorensen@redhat.com Date: Tue, 22 Feb 2011 11:17:59 +0100 Message-Id: <1298369880-23859-1-git-send-email-Jes.Sorensen@redhat.com> Subject: [Qemu-devel] [PATCH] For AIO return -ENOSPC on short write List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: hch@infradead.org, kwolf@redhat.com, stefanha@linux.vnet.ibm.com From: Jes Sorensen Hi, Current AIO code returns -EINVAL on every error, even on write. In order to be able to report some more sensible error messages, I suggest we change it to return -ENOSPC if we are failing on a write request and we had a partial write. It matches more what one would expect. One way to reproduce the strange error return is this: 1) setup a loopback device for a file (say 2GB) 2) create an LVM volume over it 3) create a qcow2 image on top of it which is larger than the 2GB 4) try and install a guest..... Comments? any reason why this is a bad idea? Cheers, Jes Jes Sorensen (1): For AIO return -ENOSPC on short write linux-aio.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) -- 1.7.4