From nobody Sat Feb 7 06:49:14 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1573242618; cv=none; d=zoho.com; s=zohoarc; b=VG3SPpap+We/SB8ldotS8OCh4Er9OA4rmgy4MpVZV/d4gBdaMl0QOZOVZf2EovdzlZ3gyc0F5IAvgKSbgGQwWIeD8s/d/n2XwoDS/kRv2vGxj7oz7OoSE9dvrmrjTeL0r+9h5Luwm8p0srYDxm48DL1lrKJc6zuGRW23gY9Vor0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1573242618; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=5agNHd9M2bORCVbIGO//JZMZDNyfUZl1bBgI5l6KvTQ=; b=DqhssldEQ7ShaXDgFU4FmHPsEO5j6g9gLl8ppEe53MAq9QjGMLoPf81u0dpEMCBBSxc5FQsJqqA/IEjZOwakEKXWssU+JCbJRnaYaYYe7GalOBmIEpABQCSaIYLNZfkcofSPwoC7K/0A344jGxUoG6TmpmpicbKU1g5H6jJyPIs= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1573242618803423.82574253359326; Fri, 8 Nov 2019 11:50:18 -0800 (PST) Received: from localhost ([::1]:59606 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iTAGr-0001XY-5R for importer@patchew.org; Fri, 08 Nov 2019 14:50:13 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35805) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iTAFC-00009k-5G for qemu-devel@nongnu.org; Fri, 08 Nov 2019 14:48:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iTAFB-000642-6b for qemu-devel@nongnu.org; Fri, 08 Nov 2019 14:48:30 -0500 Received: from mail-pf1-x443.google.com ([2607:f8b0:4864:20::443]:33716) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iTAFB-00063b-0n for qemu-devel@nongnu.org; Fri, 08 Nov 2019 14:48:29 -0500 Received: by mail-pf1-x443.google.com with SMTP id c184so5346683pfb.0 for ; Fri, 08 Nov 2019 11:48:28 -0800 (PST) Received: from localhost ([12.206.222.5]) by smtp.gmail.com with ESMTPSA id r68sm7456977pfr.78.2019.11.08.11.48.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Nov 2019 11:48:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dabbelt-com.20150623.gappssmtp.com; s=20150623; h=subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding:cc:from:to; bh=5agNHd9M2bORCVbIGO//JZMZDNyfUZl1bBgI5l6KvTQ=; b=Phez6cVAOAk6qvA3brvUjT0QhoQeK19ixiY6E8EHjShNInxaUAUxVga9N8f+ahKnB4 eZUDjKYVzlgD4hVBUQBW42rgQ7tfX2VLAWVm8gj+M3+9lUr0X+auUBHf+nwNOZKFOr2S TNBLth0FYYYnT5toF+rM/dDsjb5kJdepUsN8lZYHCtXWxWd2+NdyZuPc5/OviT1lWMn/ 0xEge9o7YRi/M7szla8/Qh/VvkaEOAtMewPqwyx/83iGRbuxImvjt8/edortm2heLP43 +MtOo6YPuRppc53pDpXMd+SglAST0/IGjZOOpkTNbFhfdI3uSJ+p/w+9/75c2wDvA/Lx MRJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:cc:from:to; bh=5agNHd9M2bORCVbIGO//JZMZDNyfUZl1bBgI5l6KvTQ=; b=nTP3caUhiUVmZyMp7K+jdF3HPiF/Eo0h0uZXgodVLQagrsMzznYQQNJQHWQb6+8Vfg ySaCuDev69e3r962iK2xmM2jDEJvCMEnOOSkF5Yv/Dv9FH+HylCU1jdM7wTrGab73EvN A9luJr3HqxA7Z5Gs1rrPShrjTuhwqwhCRhmSFfMKJEYBK0zmIK3Bc8UCW7AFq5jYi+q0 drqAQUsMA2HwtYj430TwS5fYgM6Gs1MxTeayx2KfWmoxCOkdTLPVmFYwyr9UNsk8vewp Vq6WOaTxyrjn6uB+wyFmL+AWV6rh48tIwuyozw5irCuhNy8JNL/OjZWv9TU5EX2+wsv3 nJag== X-Gm-Message-State: APjAAAVLzhGZtt0aipbx15mM3493Du4o7CHzAb9PUT7ECwj2/H2FQfJ1 +Sx8xItxTX039MXCv6A1gK0A+w== X-Google-Smtp-Source: APXvYqx89ckaICmNEcPymnIaPzw/La0DkOPJLAUZIE+RBy/lpguEOtXGyUt3wXoJKDiajjs6+Ikk0A== X-Received: by 2002:a63:7887:: with SMTP id t129mr13976804pgc.144.1573242507720; Fri, 08 Nov 2019 11:48:27 -0800 (PST) Subject: [PATCH v2 2/3] ARM/virt: Use fdt_setprop_strings() Date: Fri, 8 Nov 2019 11:47:57 -0800 Message-Id: <20191108194758.17813-3-palmer@dabbelt.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20191108194758.17813-1-palmer@dabbelt.com> References: <20191108194758.17813-1-palmer@dabbelt.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Palmer Dabbelt To: Peter Maydell , Alistair Francis , qemu-devel@nongnu.org, david@gibson.dropbear.id.au X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::443 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Palmer Dabbelt , qemu-riscv@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" This new helper function encodes the idiom used by the ARM virt board to set a string array. I don't currently have a working ARM userspace, so I h= aven't tested this, but I made the helper function because I wanted to use it for the RISC-V virt board where I have tested it. Signed-off-by: Palmer Dabbelt --- hw/arm/virt.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/arm/virt.c b/hw/arm/virt.c index d4bedc2607..4dc00f54d5 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -304,9 +304,8 @@ static void fdt_add_timer_nodes(const VirtMachineState = *vms) =20 armcpu =3D ARM_CPU(qemu_get_cpu(0)); if (arm_feature(&armcpu->env, ARM_FEATURE_V8)) { - const char compat[] =3D "arm,armv8-timer\0arm,armv7-timer"; - qemu_fdt_setprop(vms->fdt, "/timer", "compatible", - compat, sizeof(compat)); + qemu_fdt_setprop_strings(vms->fdt, "/timer", "compatible", + "arm,armv8-timer\0arm,armv7-timer\0"); } else { qemu_fdt_setprop_string(vms->fdt, "/timer", "compatible", "arm,armv7-timer"); --=20 2.21.0