From patchwork Thu Jul 25 15:18:21 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Hajnoczi X-Patchwork-Id: 261776 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 1ECEB2C0090 for ; Fri, 26 Jul 2013 01:30:38 +1000 (EST) Received: from localhost ([::1]:59483 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V2NNY-0001Cj-96 for incoming@patchwork.ozlabs.org; Thu, 25 Jul 2013 11:22:56 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54792) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V2NL9-0006Aq-BT for qemu-devel@nongnu.org; Thu, 25 Jul 2013 11:20:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V2NKz-0004LK-2D for qemu-devel@nongnu.org; Thu, 25 Jul 2013 11:20:27 -0400 Received: from mx1.redhat.com ([209.132.183.28]:64449) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V2NKy-0004L1-Rx for qemu-devel@nongnu.org; Thu, 25 Jul 2013 11:20:17 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r6PFIxG3020735 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 25 Jul 2013 11:18:59 -0400 Received: from localhost (ovpn-112-33.ams2.redhat.com [10.36.112.33]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r6PFIwn9025308; Thu, 25 Jul 2013 11:18:59 -0400 From: Stefan Hajnoczi To: Date: Thu, 25 Jul 2013 17:18:21 +0200 Message-Id: <1374765505-14356-15-git-send-email-stefanha@redhat.com> In-Reply-To: <1374765505-14356-1-git-send-email-stefanha@redhat.com> References: <1374765505-14356-1-git-send-email-stefanha@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.24 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Kevin Wolf , Ping Fan Liu , alex@alex.org.uk, Michael Roth , Stefan Hajnoczi , Paolo Bonzini Subject: [Qemu-devel] [PATCH v6 14/18] block/ssh: drop return_true() X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org .io_flush() is no longer called so drop return_true(). Signed-off-by: Stefan Hajnoczi Reviewed-by: Wenchao Xia --- block/ssh.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/block/ssh.c b/block/ssh.c index d7e7bf8..e149da9 100644 --- a/block/ssh.c +++ b/block/ssh.c @@ -740,14 +740,6 @@ static void restart_coroutine(void *opaque) qemu_coroutine_enter(co, NULL); } -/* Always true because when we have called set_fd_handler there is - * always a request being processed. - */ -static int return_true(void *opaque) -{ - return 1; -} - static coroutine_fn void set_fd_handler(BDRVSSHState *s) { int r; @@ -766,7 +758,7 @@ static coroutine_fn void set_fd_handler(BDRVSSHState *s) DPRINTF("s->sock=%d rd_handler=%p wr_handler=%p", s->sock, rd_handler, wr_handler); - qemu_aio_set_fd_handler(s->sock, rd_handler, wr_handler, return_true, co); + qemu_aio_set_fd_handler(s->sock, rd_handler, wr_handler, NULL, co); } static coroutine_fn void clear_fd_handler(BDRVSSHState *s)