From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52607) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gHU8V-0003ny-CK for qemu-devel@nongnu.org; Tue, 30 Oct 2018 09:32:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gHU8T-0004ta-Tc for qemu-devel@nongnu.org; Tue, 30 Oct 2018 09:32:47 -0400 Received: from mail-oi1-x244.google.com ([2607:f8b0:4864:20::244]:40086) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gHU8T-0003vf-N0 for qemu-devel@nongnu.org; Tue, 30 Oct 2018 09:32:45 -0400 Received: by mail-oi1-x244.google.com with SMTP id u130-v6so5628289oie.7 for ; Tue, 30 Oct 2018 06:32:06 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20181022173559.17111-5-edgar.iglesias@gmail.com> References: <20181022173559.17111-1-edgar.iglesias@gmail.com> <20181022173559.17111-5-edgar.iglesias@gmail.com> From: Peter Maydell Date: Tue, 30 Oct 2018 13:31:44 +0000 Message-ID: Content-Type: text/plain; charset="UTF-8" Subject: Re: [Qemu-devel] [PATCH v4 4/4] hw/arm: versal: Add a virtual Xilinx Versal board List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Edgar E. Iglesias" Cc: QEMU Developers , qemu-arm , Richard Henderson , KONRAD Frederic , Alistair Francis , =?UTF-8?Q?Philippe_Mathieu=2DDaud=C3=A9?= , Francisco Iglesias , figlesia@xilinx.com, Stefano Stabellini , Sai Pavan Boddu , Edgar Iglesias On 22 October 2018 at 18:35, Edgar E. Iglesias wrote: > From: "Edgar E. Iglesias" > > Add a virtual Xilinx Versal board. > > This board is based on the Xilinx Versal SoC. The exact > details of what peripherals are attached to this board > will remain in control of QEMU. QEMU will generate an > FDT on the fly for Linux and other software to auto-discover > peripherals. > > Signed-off-by: Edgar E. Iglesias > +static void fdt_add_fixed_link_nodes(VersalVirt *s, char *gemname, > + uint32_t phandle) > +{ > + char *name = g_strdup_printf("%s/fixed-link", gemname); > + > + qemu_fdt_add_subnode(s->fdt, name); > + qemu_fdt_setprop_cell(s->fdt, name, "phandle", phandle); > + qemu_fdt_setprop_cells(s->fdt, name, "full-duplex"); Hi. This fails to compile in a non-debug build: In file included from /home/peter.maydell/qemu/hw/arm/xlnx-versal-virt.c:16:0: /home/peter.maydell/qemu/hw/arm/xlnx-versal-virt.c: In function 'fdt_add_fixed_link_nodes': /home/peter.maydell/qemu/include/sysemu/device_tree.h:110:23: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits] for (i = 0; i < ARRAY_SIZE(qdt_tmp); i++) { \ ^ /home/peter.maydell/qemu/hw/arm/xlnx-versal-virt.c:191:5: note: in expansion of macro 'qemu_fdt_setprop_cells' qemu_fdt_setprop_cells(s->fdt, name, "full-duplex"); ^ because qemu_fdt_setprop_cells() requires you to provide at least one cell value for the property being set. What was the intention here ? > + qemu_fdt_setprop_cell(s->fdt, name, "speed", 1000); > + g_free(name); > +} In the meantime, I'm dropping the versal patches from target-arm.next. thanks -- PMM