From patchwork Mon Jun 18 21:04:06 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guenter Roeck X-Patchwork-Id: 10472709 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 28F0E6032A for ; Mon, 18 Jun 2018 21:05:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0F33828A6B for ; Mon, 18 Jun 2018 21:05:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0063B28A7A; Mon, 18 Jun 2018 21:05:15 +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=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, 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 6556A28A6B for ; Mon, 18 Jun 2018 21:05:15 +0000 (UTC) Received: from localhost ([::1]:36894 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fV1Kr-0003Ah-UT for patchwork-qemu-devel@patchwork.kernel.org; Mon, 18 Jun 2018 17:05:13 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56702) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fV1K5-0002fI-Vy for qemu-devel@nongnu.org; Mon, 18 Jun 2018 17:04:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fV1K2-0006Jt-BX for qemu-devel@nongnu.org; Mon, 18 Jun 2018 17:04:25 -0400 Received: from bh-25.webhostbox.net ([208.91.199.152]:39415) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fV1K2-0006Dh-3b for qemu-devel@nongnu.org; Mon, 18 Jun 2018 17:04:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=roeck-us.net; s=default; h=Message-Id:Date:Subject:Cc:To:From:Sender: Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=UvbFu47szarqGkZlgQVGIT0Ys1WTlL09enng2VJgIi0=; b=sV8maEagOuAXphntqxUvRTbYTq v2fSVUJELsKjd+YmqLyTQQrBEt4EsTZQZ70WkISRYSuWDlalrqfm0Vdamd7og+VZv+eIxUVWhVdWr xOJIwKufJsccHTg9Lk78hn82LPsVX1otfOjpJUwM+fqSxNY9kJE8EWJgUwQjMKGH4pvTOlIAEOvzd iw7OYH4Th647pra78wG4WGJqcMJAY0nWjb4kt5vYDmEyiXYJyX5GUOQ/FSGYcsgWp32YspSIXNGl6 BU0VpLZE2PhfSxhtsroXdPUgyG4pg/gxCyarYfxRqT7l9jyYjfRKtN0aT6BtySeYllV2nFGPr7TsY 1p6KM+zQ==; Received: from 108-223-40-66.lightspeed.sntcca.sbcglobal.net ([108.223.40.66]:38754 helo=localhost) by bh-25.webhostbox.net with esmtpa (Exim 4.89) (envelope-from ) id 1fV1Jq-003VPf-CY; Mon, 18 Jun 2018 21:04:10 +0000 From: Guenter Roeck To: Paolo Bonzini Date: Mon, 18 Jun 2018 14:04:06 -0700 Message-Id: <1529355846-25102-1-git-send-email-linux@roeck-us.net> X-Mailer: git-send-email 2.7.4 X-Authenticated_sender: guenter@roeck-us.net X-OutGoing-Spam-Status: No, score=-1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bh-25.webhostbox.net X-AntiAbuse: Original Domain - nongnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - roeck-us.net X-Get-Message-Sender-Via: bh-25.webhostbox.net: authenticated_id: guenter@roeck-us.net X-Authenticated-Sender: bh-25.webhostbox.net: guenter@roeck-us.net X-Source: X-Source-Args: X-Source-Dir: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 208.91.199.152 Subject: [Qemu-devel] [PATCH] bcm2835_aux: Swap RX and TX interrupt assignments 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: qemu-devel@nongnu.org, Guenter Roeck Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP RX and TX interrupt bits were reversed, resulting in an endless sequence of serial interupts in the emulated system and the following repeated error message when booting Linux. serial8250: too much work for irq61 This results in a boot failure most of the time. Qemu command line used to reproduce the problem: qemu-system-aarch64 -M raspi3 -m 1024 \ -kernel arch/arm64/boot/Image \ --append "rdinit=/sbin/init console=ttyS1,115200" -initrd rootfs.cpio \ -dtb arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dtb \ -nographic -monitor null -serial null -serial stdio This is with arm64:defconfig. The root file system was generated using buildroot. Signed-off-by: Guenter Roeck --- hw/char/bcm2835_aux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/char/bcm2835_aux.c b/hw/char/bcm2835_aux.c index 370dc7e..0364596 100644 --- a/hw/char/bcm2835_aux.c +++ b/hw/char/bcm2835_aux.c @@ -39,8 +39,8 @@ #define AUX_MU_BAUD_REG 0x68 /* bits in IER/IIR registers */ -#define TX_INT 0x1 -#define RX_INT 0x2 +#define RX_INT 0x1 +#define TX_INT 0x2 static void bcm2835_aux_update(BCM2835AuxState *s) {