From patchwork Fri Apr 20 14:52:41 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 133882 Delivered-To: patches@linaro.org Received: by 10.46.66.142 with SMTP id h14csp374916ljf; Fri, 20 Apr 2018 07:52:54 -0700 (PDT) X-Google-Smtp-Source: AIpwx49icYg50baWj+Jm5CLEwq/SjotHZ6MM9X6KdpWaVAUv9mql5ujqXm1Tr6J21j361dJfzKp6 X-Received: by 2002:adf:df07:: with SMTP id y7-v6mr2664031wrl.279.1524235974410; Fri, 20 Apr 2018 07:52:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524235974; cv=none; d=google.com; s=arc-20160816; b=cB9HTA8DA5BT20FUbyBJQ1ARLsK3BgqjqTxqtDors3+ss9L8PQhdgRHABPRcxgSvY9 2hMuV5/Tuph1tpIatzwnckNHYUy5Js8a71UKz31r+D8eWC2ATBXiGl8XvM6SBHYPtFmD E1B3wbg/1gk9WN/HBd/F6Gv3PKxz4Dx9xcAi+o5Sp0/AP5QsKZCGonYpIc/amVUEhHpp W+59Rcvn5Y7cmiZlpe3Sv67rsapOrOwKiH82BRumXSOzURPBqteJ8tR0jNm3qa6ssArL EAQXjGyCne04CBvosUTYu6vp2SLVYozT0X429h0YPP1Vi5B+jzAdcV7wb9FiFWVgMGSa FnOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Bph8DFMPlXKvzHIqMyoBWueTDveSq0k2W/AjsDjZyoQ=; b=T6jPrN0PHrLXOTT0Eoxe9CiXkptPmJSQV+6kGLiN+loUJ5kMyhsK19xNtsn4TQUOEZ kKZ0yt9XEpUSz76OEP129QzYM5zVpC4vNATHHKTHA4GPtv2Ems3p9wAUyX8aFqmweFYt WzIh0u8t3DU/aj7g8ZQduSzJE/cZlLWs1CiMJIhwe+IcuuWico66wj3AKywE0Cp2mayQ RIuUCLy0njSaYJfOYwmxBGqE3/5oJcLo70JeKRyzFxzjYNYei3e/Hhjne8vi4A3CnytH CimYEDZ8bGJC/RQocD+hl9YLyfgWFhWOhhW2ucDptVvpkS+mZrBozb0saULIEqCBiyc9 6n1A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of pm215@archaic.org.uk designates 2001:8b0:1d0::2 as permitted sender) smtp.mailfrom=pm215@archaic.org.uk; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by mx.google.com with ESMTPS id d12-v6si4557034wri.23.2018.04.20.07.52.54 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 20 Apr 2018 07:52:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of pm215@archaic.org.uk designates 2001:8b0:1d0::2 as permitted sender) client-ip=2001:8b0:1d0::2; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of pm215@archaic.org.uk designates 2001:8b0:1d0::2 as permitted sender) smtp.mailfrom=pm215@archaic.org.uk; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from pm215 by orth.archaic.org.uk with local (Exim 4.89) (envelope-from ) id 1f9XPB-0006YB-PX; Fri, 20 Apr 2018 15:52:53 +0100 From: Peter Maydell To: qemu-devel@nongnu.org Cc: patches@linaro.org, "Michael S . Tsirkin" , Paolo Bonzini , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= Subject: [PATCH 05/13] hw/xtensa/xtfpga.c: Don't create "null" chardevs for serial devices Date: Fri, 20 Apr 2018 15:52:41 +0100 Message-Id: <20180420145249.32435-6-peter.maydell@linaro.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180420145249.32435-1-peter.maydell@linaro.org> References: <20180420145249.32435-1-peter.maydell@linaro.org> Following commit 12051d82f004024, UART devices should handle being passed a NULL pointer chardev, so we don't need to create "null" backends in board code. Remove the code that does this and updates serial_hds[]. Signed-off-by: Peter Maydell --- hw/xtensa/xtfpga.c | 4 ---- 1 file changed, 4 deletions(-) -- 2.17.0 Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth diff --git a/hw/xtensa/xtfpga.c b/hw/xtensa/xtfpga.c index 70686a2eb1..9db99e1f7e 100644 --- a/hw/xtensa/xtfpga.c +++ b/hw/xtensa/xtfpga.c @@ -278,10 +278,6 @@ static void xtfpga_init(const XtfpgaBoardDesc *board, MachineState *machine) xtensa_get_extint(env, 1), nd_table); } - if (!serial_hds[0]) { - serial_hds[0] = qemu_chr_new("serial0", "null"); - } - serial_mm_init(system_io, 0x0d050020, 2, xtensa_get_extint(env, 0), 115200, serial_hds[0], DEVICE_NATIVE_ENDIAN);