From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:36077) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tvxtn-0001Jh-EV for qemu-devel@nongnu.org; Thu, 17 Jan 2013 17:25:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tvxtm-0005NC-0P for qemu-devel@nongnu.org; Thu, 17 Jan 2013 17:25:27 -0500 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:40692) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tvxtl-0005N3-PZ for qemu-devel@nongnu.org; Thu, 17 Jan 2013 17:25:25 -0500 Message-ID: <50F87A53.7080108@weilnetz.de> Date: Thu, 17 Jan 2013 23:25:23 +0100 From: Stefan Weil MIME-Version: 1.0 References: <1358455528-29813-1-git-send-email-sw@weilnetz.de> <50F86D0D.7030104@redhat.com> In-Reply-To: <50F86D0D.7030104@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v2 0/5] block: Fix error report for wrong file format List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: Kevin Wolf , qemu-devel@nongnu.org, Stefan Hajnoczi Am 17.01.2013 22:28, schrieb Eric Blake: > On 01/17/2013 01:45 PM, Stefan Weil wrote: > >> These patches improve the error report if the file format was >> specified explicitly (example: -drive file=myfile,format=qcow2) >> and the given format does not match the real format. >> >> They fix those bugs: >> >> https://bugzilla.redhat.com/show_bug.cgi?id=556482 >> https://bugs.launchpad.net/qemu/+bug/1090600 >> >> Changes in v2: >> >> * Use error code EMEDIUMTYPE instead of inventing a new one. >> > Alas, EMEDIUMTYPE is non-standard, and doesn't exist outside of Linux. > If you are providing fallbacks for half the platforms because you don't > want to use a standard errno value, then why not go all the way and use > a fallback for all platforms. > That's what I did in v1 of my patches: it used BDRV_WRONG_FORMAT. I didn't introduce a EFILEFORMAT because it looks like something used outside of the QEMU world (which is not true). If EFILEFORMAT (or any other new name) is preferred, I won't object. In this case, I can either send a new patch series, or whoever commits my patches can do a simple replace operation. Regards, Stefan W.