From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58001) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xswgl-0002Mk-Va for qemu-devel@nongnu.org; Mon, 24 Nov 2014 11:40:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xswgf-0002tB-Ob for qemu-devel@nongnu.org; Mon, 24 Nov 2014 11:40:35 -0500 Received: from mx1.redhat.com ([209.132.183.28]:44466) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xswgf-0002st-Bd for qemu-devel@nongnu.org; Mon, 24 Nov 2014 11:40:29 -0500 Date: Mon, 24 Nov 2014 16:40:23 +0000 From: Stefan Hajnoczi Message-ID: <20141124164023.GA14760@stefanha-thinkpad.redhat.com> References: <1416839379-19677-1-git-send-email-ming.lei@canonical.com> <1416839379-19677-2-git-send-email-ming.lei@canonical.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="bg08WKrSYDhXBjb5" Content-Disposition: inline In-Reply-To: <1416839379-19677-2-git-send-email-ming.lei@canonical.com> Subject: Re: [Qemu-devel] [PATCH v5 1/3] linux-aio: fix submit aio as a batch List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Ming Lei Cc: Kevin Wolf , Paolo Bonzini , qemu-devel@nongnu.org --bg08WKrSYDhXBjb5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Nov 24, 2014 at 10:29:37PM +0800, Ming Lei wrote: > + /* submit immediately if queue depth is above 2/3 */ > + if (idx > s->io_q.size * 2 / 3) { > + return ioq_submit(s); The return value of ioq_submit() is the number of requests submitted (0 or more). This has no meaning to the caller and therefore shouldn't be the return value of this function. Please drop the return here. --bg08WKrSYDhXBjb5 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJUc193AAoJEJykq7OBq3PI4HUH/3hk8DHczrqmWqTAyByKvVNC jZQeM6GEhFHzaAzjxiGJvrXIPzise18tllGqfzScviK8xvMto1QRgQQAwatTf0Tl EBWDVhNggCncN44H3hE3sh7S099qdreST3U0D6KLakVi9GnrSZ2k4CqFjqmjy6Z/ KsnO0/JsFZRGC9NQUnOk7IL5ZvaohXZS0Mkn3OBzjfaslA5C9COyw0mJicAVaRDV Hko6fS+FUU4kVqhvubJcrYAnkNaUuwy5D++UglJiLot22+o1FdKbM2WIl6+nigze LAfvQRqNQLq8WpQWvXHptcYBA0+tRFX/0zZQw606JgtoZaWbObgeKKTWyKU0bAo= =hw25 -----END PGP SIGNATURE----- --bg08WKrSYDhXBjb5--