From patchwork Wed Dec 5 06:53:44 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Crosthwaite X-Patchwork-Id: 203793 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 77FCD2C00BF for ; Wed, 5 Dec 2012 17:54:30 +1100 (EST) Received: from localhost ([::1]:44826 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg8sG-0007BG-M1 for incoming@patchwork.ozlabs.org; Wed, 05 Dec 2012 01:54:28 -0500 Received: from eggs.gnu.org ([208.118.235.92]:33807) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg8rw-0006am-Rb for qemu-devel@nongnu.org; Wed, 05 Dec 2012 01:54:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Tg8rv-0002uz-QS for qemu-devel@nongnu.org; Wed, 05 Dec 2012 01:54:08 -0500 Received: from mail-pb0-f45.google.com ([209.85.160.45]:46999) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Tg8rv-0002uq-Jy for qemu-devel@nongnu.org; Wed, 05 Dec 2012 01:54:07 -0500 Received: by mail-pb0-f45.google.com with SMTP id mc8so3212793pbc.4 for ; Tue, 04 Dec 2012 22:54:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:in-reply-to:references:x-gm-message-state; bh=Qc0dqOtUHuYU8yEiWQ2KQwTmWzrON9CCGuTPyFly3FM=; b=H+SVorx2HRXOpS+WjUJlVHmZ38Sx8teeNp+bka1rqBBudN8en6u00BO0yWfnCYOGpR gbPJg3WuePDJvceaqZs0f2i3Oj8bVCinTR15E1W3JwLLvPRvOF3mQjNw/k9iBYAokrWH O0YhcC4kTxHhp3Ar62FNpMhS37X6VbtbP+OMq1g0oAsruIiygX+3kvQR/8jdDbyiA1C5 KUMQeCpXtBhT67CAQ+q/cX0xG2nK0ox+OfkyTSo+dZgDhfJdPOvku+ywDaabjfbroltb MldKuBZLj3yL8sNfgPNcYOywa6aRETKO+ttEytJgFVaI07U1l6V/9uU26Iiv8nhaRdd5 ccCQ== Received: by 10.68.189.163 with SMTP id gj3mr46160063pbc.110.1354690446853; Tue, 04 Dec 2012 22:54:06 -0800 (PST) Received: from localhost ([124.148.20.9]) by mx.google.com with ESMTPS id bd2sm2187165pab.36.2012.12.04.22.54.04 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 04 Dec 2012 22:54:06 -0800 (PST) From: Peter Crosthwaite To: qemu-devel@nongnu.org Date: Wed, 5 Dec 2012 16:53:44 +1000 Message-Id: <6d7d82a2f960a77a0ccc2cd8049c60ae64b80195.1354690179.git.peter.crosthwaite@xilinx.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: References: In-Reply-To: References: X-Gm-Message-State: ALoCoQlULL8Vv+vhq8A2bok+66LAKrWQgOXDfq0iaaa4t/PHlqMtlTxCutr11GOwkd/78MfZWSLZ X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.160.45 Cc: edgar.iglesias@gmail.com, Peter Crosthwaite , peter.maydell@linaro.org Subject: [Qemu-devel] [PATCH v1 3/3] xilinx_uartlite: Accept input after rx FIFO pop 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 The device return false from the can receive function when the FIFO is full. This mean the device should check for buffered input whenever a byte is popped from the FIFO. Reported-by: Jason Wu Signed-off-by: Peter Crosthwaite --- hw/xilinx_uartlite.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/hw/xilinx_uartlite.c b/hw/xilinx_uartlite.c index f890f23..02c5850 100644 --- a/hw/xilinx_uartlite.c +++ b/hw/xilinx_uartlite.c @@ -97,6 +97,7 @@ uart_read(void *opaque, hwaddr addr, unsigned int size) s->rx_fifo_len--; uart_update_status(s); uart_update_irq(s); + qemu_chr_accept_input(s->chr); break; default: