From patchwork Sat Jun 4 21:33:18 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marc-Andr=C3=A9_Lureau?= X-Patchwork-Id: 9154973 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3ECAD60574 for ; Sat, 4 Jun 2016 21:38:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3085327F2B for ; Sat, 4 Jun 2016 21:38:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2536728327; Sat, 4 Jun 2016 21:38:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C18A927F2B for ; Sat, 4 Jun 2016 21:38:35 +0000 (UTC) Received: from localhost ([::1]:34216 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b9JH8-0001fz-Qw for patchwork-qemu-devel@patchwork.kernel.org; Sat, 04 Jun 2016 17:38:34 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44793) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b9JCd-0006Ag-2l for qemu-devel@nongnu.org; Sat, 04 Jun 2016 17:33:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b9JCX-0005sa-3a for qemu-devel@nongnu.org; Sat, 04 Jun 2016 17:33:54 -0400 Received: from mail-wm0-x244.google.com ([2a00:1450:400c:c09::244]:33048) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b9JCW-0005rz-TM for qemu-devel@nongnu.org; Sat, 04 Jun 2016 17:33:49 -0400 Received: by mail-wm0-x244.google.com with SMTP id a136so7294913wme.0 for ; Sat, 04 Jun 2016 14:33:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7gPhZA7x8nvVDsVH54bpdfljovd/9lPQhjAFJesax5E=; b=wLDjwdgACeC+kXE5adOo42E8AiJy/ZyrfjiZoKLA37HduabVSTOqmRI3BSbMO2jwlC y4CMxhT8nZv0+n0IJ7o1BnXNaVs/uTD5A9zujo74iklwmx0hjGvVHaLm23W5wBaV6o1z IHtQnWttPNgbrbpVF/bgPYoEdjtKt79r1u6Su/p1jh5gfmoI8Hch1c4T/bx0DQzFNTii muNb8KTW7xshBmpE8DdDmUNScWutQzM5kUbs0d6Os3tg8rFiMIUAz4f95s8rfbO6uPO1 yqkZL/iwJr4SZ0CXSEo7bvsRAeCabG6uSExfYGA0NVlFLIdI4PGK2LWvZcufpco+RUpX cypw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=7gPhZA7x8nvVDsVH54bpdfljovd/9lPQhjAFJesax5E=; b=MYE5IVh/gvSzz+Xv9yasl09kDFqYLTNK1cN5G0z/5z6f66qbq90cqPHNDe882FSgp6 nvLjZiHUz3ZGrzcGXEbQj+E8wVTDPR0FLRYnF3rtp5j9Hfhs/goObqyHq1jBJXF0QXbN oJ5EA1Tcrz3rUeHhfZBWCYPmvC/+4E2tOX1NoL+vBLa0YGR208j33umhcLCjYnGu2qud swXR3huUgas/uy4Ui6dZxMPPxOoVw/Vohcf/4+HGDgbZ/JtDCz9Ias5Sd7mAfVtinTDw 1AYnmPcTTqeLabnJ66LuUE/nqnAeBSSkepnxb02MrRUNhnA1/XuQ2+9X38/BiUUBImCd UCpQ== X-Gm-Message-State: ALyK8tJe0NFzhyonnEKTS3b2PR2Z7V/IpKka6tZ7rU9tRMROTwONIt530AVzFwOtGkDR3w== X-Received: by 10.194.201.162 with SMTP id kb2mr9894364wjc.55.1465076028334; Sat, 04 Jun 2016 14:33:48 -0700 (PDT) Received: from localhost (APoitiers-110-1-1-235.w193-248.abo.wanadoo.fr. [193.248.103.235]) by smtp.gmail.com with ESMTPSA id y1sm12351693wjl.31.2016.06.04.14.33.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 04 Jun 2016 14:33:47 -0700 (PDT) From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Date: Sat, 4 Jun 2016 23:33:18 +0200 Message-Id: <1465076003-26291-10-git-send-email-marcandre.lureau@redhat.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1465076003-26291-1-git-send-email-marcandre.lureau@redhat.com> References: <1465076003-26291-1-git-send-email-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::244 Subject: [Qemu-devel] [RFC 09/14] qemu-char: use READ_RETRIES X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , kraxel@redhat.com Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Marc-André Lureau The define was introduced with qemu_chr_fe_read_all() in 7b0bfdf52d, however never used. Signed-off-by: Marc-André Lureau --- qemu-char.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qemu-char.c b/qemu-char.c index caa737d..efa1e2a 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -325,13 +325,13 @@ int qemu_chr_fe_write_all(CharDriverState *s, const uint8_t *buf, int len) int qemu_chr_fe_read_all(CharDriverState *s, uint8_t *buf, int len) { - int offset = 0, counter = 10; + int offset = 0, counter = READ_RETRIES; int res; if (!s->chr_sync_read) { return 0; } - + if (s->replay && replay_mode == REPLAY_MODE_PLAY) { return replay_char_read_all_load(buf); }