From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:57734) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S75KY-000288-2Q for qemu-devel@nongnu.org; Mon, 12 Mar 2012 09:30:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S75KR-0006TQ-Io for qemu-devel@nongnu.org; Mon, 12 Mar 2012 09:30:29 -0400 Received: from mail-yw0-f45.google.com ([209.85.213.45]:41909) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S75KR-0006T6-C7 for qemu-devel@nongnu.org; Mon, 12 Mar 2012 09:30:23 -0400 Received: by yhoo21 with SMTP id o21so3013420yho.4 for ; Mon, 12 Mar 2012 06:30:21 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <4F5DFA66.80900@redhat.com> Date: Mon, 12 Mar 2012 14:30:14 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1331430564-32745-1-git-send-email-mjt@msgid.tls.msk.ru> <1331430564-32745-7-git-send-email-mjt@msgid.tls.msk.ru> <4F5CBE4F.1040007@redhat.com> <4F5CC41E.1080106@msgid.tls.msk.ru> In-Reply-To: <4F5CC41E.1080106@msgid.tls.msk.ru> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCHv2 6/7] cleanup qemu_co_sendv(), qemu_co_recvv() and friends List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Tokarev Cc: qemu-devel@nongnu.org Il 11/03/2012 16:26, Michael Tokarev ha scritto: > Note that - I still hope - in the end there will be no sendv or > recv calls at all, only common sendv_recvv with is_write passed > as an argument from upper layer. It will be easier to remove > that #define - just two lines of code instead of minimum 5 :) This is what I don't really like in the second part of these patches. You are doing changes for the sake of other changes which are not upstream yet, for which there is no clear vision, and for which there is no clear benefit. While I agree that there is a lot of duplicated code in block.c and block/*, I don't think that what we need is more parameters to the functions. We have places where we need to know the request flags, for example, but the methods are already quite unwieldy and have a lot of arguments. So I'm not sure that this kind of unification buys anything. On top of this, your patches unify things that are similar but not quite identical, and you do not provide hints in the commit messages that you did so. For example, qemu_co_recvv has handling for receiving 0, but qemu_co_sendv does not. Can you please separate the changes to make the argument order uniform? Those should be easy to get in. Paolo