From patchwork Mon Sep 14 13:53:04 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 53571 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f197.google.com (mail-lb0-f197.google.com [209.85.217.197]) by patches.linaro.org (Postfix) with ESMTPS id D74B42056A for ; Mon, 14 Sep 2015 13:58:42 +0000 (UTC) Received: by lbbti1 with SMTP id ti1sf45936629lbb.3 for ; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:date :message-id:in-reply-to:references:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=tUSWReocGdQPRAgAhLHEIYz32EspT1xxCByrTbjHN0Q=; b=BFr5hxlrdw6J3cliSrJutsS4q6CdZ1jBTE/VbsdfPDiLKbGbnFlE/FibEIG5zNpsw3 3OfjngnE5x3NLGYhB9HDnEBl7nHh/a9ETjYBr9oaGnwPokYi6GPcAWEj0LaiPmC2b4wx AtBgxn9gn5jhzUoyFugoJ9ExQkXVul/ni5YMckNVdgbYktf0KhpEaLDUEIJ/oIKsy94V ttjxl8okQOe/Fr8hvm4v7zIr4gfa7sGrgK9kW8B9HQ/fOK54apGjfUdr9nOYjLot2WNV n7nqc2v1i79fNw5gse1jltU/0w50iyuXieHGjJ4dQv7ycSqOZ/rZmb/Nhw77AJwIoy2Z hmDw== X-Gm-Message-State: ALoCoQmfYEg/ENAS3X6uaiEsPyxnF1EL13Eyg6hcd9BIxVSEFi0PYuZqx3BXlsmJIEWsj9AGdrFb X-Received: by 10.180.96.226 with SMTP id dv2mr2957057wib.2.1442239121784; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.153.4.11 with SMTP id ca11ls419600lad.38.gmail; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) X-Received: by 10.152.2.200 with SMTP id 8mr14064185law.115.1442239121617; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) Received: from mail-lb0-f170.google.com (mail-lb0-f170.google.com. [209.85.217.170]) by mx.google.com with ESMTPS id k3si9793393laf.118.2015.09.14.06.58.41 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 14 Sep 2015 06:58:41 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.170 as permitted sender) client-ip=209.85.217.170; Received: by lbbmp1 with SMTP id mp1so67872015lbb.1 for ; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) X-Received: by 10.112.151.106 with SMTP id up10mr14266685lbb.106.1442239121479; Mon, 14 Sep 2015 06:58:41 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.59.35 with SMTP id w3csp1215321lbq; Mon, 14 Sep 2015 06:58:40 -0700 (PDT) X-Received: by 10.50.30.133 with SMTP id s5mr942367igh.4.1442239120034; Mon, 14 Sep 2015 06:58:40 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id y9si8145537igl.26.2015.09.14.06.58.39 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 14 Sep 2015 06:58:40 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Received: from localhost ([::1]:41016 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZbUHG-0004L4-MD for patch@linaro.org; Mon, 14 Sep 2015 09:58:38 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54677) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZbUC9-0004dS-Gi for qemu-devel@nongnu.org; Mon, 14 Sep 2015 09:53:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZbUC8-0000Bm-M2 for qemu-devel@nongnu.org; Mon, 14 Sep 2015 09:53:21 -0400 Received: from mnementh.archaic.org.uk ([2001:8b0:1d0::1]:35073) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZbUC8-00005c-GQ for qemu-devel@nongnu.org; Mon, 14 Sep 2015 09:53:20 -0400 Received: from pm215 by mnementh.archaic.org.uk with local (Exim 4.80) (envelope-from ) id 1ZbUC0-0007to-64 for qemu-devel@nongnu.org; Mon, 14 Sep 2015 14:53:12 +0100 From: Peter Maydell To: qemu-devel@nongnu.org Date: Mon, 14 Sep 2015 14:53:04 +0100 Message-Id: <1442238791-30255-18-git-send-email-peter.maydell@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1442238791-30255-1-git-send-email-peter.maydell@linaro.org> References: <1442238791-30255-1-git-send-email-peter.maydell@linaro.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:8b0:1d0::1 Subject: [Qemu-devel] [PULL 17/24] hw/cpu/{a15mpcore, a9mpcore}: Handle missing has_el3 CPU props gracefully 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: peter.maydell@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.170 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 From: "Edgar E. Iglesias" Handle missing CPU support for EL3 gracefully. Signed-off-by: Edgar E. Iglesias Message-id: 1442135278-25281-2-git-send-email-edgar.iglesias@gmail.com Reviewed-by: Peter Maydell Signed-off-by: Peter Maydell --- hw/cpu/a15mpcore.c | 2 +- hw/cpu/a9mpcore.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/cpu/a15mpcore.c b/hw/cpu/a15mpcore.c index 4ef8db1..94e8cc1 100644 --- a/hw/cpu/a15mpcore.c +++ b/hw/cpu/a15mpcore.c @@ -64,7 +64,7 @@ static void a15mp_priv_realize(DeviceState *dev, Error **errp) * either all the CPUs have TZ, or none do. */ cpuobj = OBJECT(qemu_get_cpu(0)); - has_el3 = object_property_find(cpuobj, "has_el3", &error_abort) && + has_el3 = object_property_find(cpuobj, "has_el3", NULL) && object_property_get_bool(cpuobj, "has_el3", &error_abort); qdev_prop_set_bit(gicdev, "has-security-extensions", has_el3); } diff --git a/hw/cpu/a9mpcore.c b/hw/cpu/a9mpcore.c index 7046246..869818c 100644 --- a/hw/cpu/a9mpcore.c +++ b/hw/cpu/a9mpcore.c @@ -69,7 +69,7 @@ static void a9mp_priv_realize(DeviceState *dev, Error **errp) * either all the CPUs have TZ, or none do. */ cpuobj = OBJECT(qemu_get_cpu(0)); - has_el3 = object_property_find(cpuobj, "has_el3", &error_abort) && + has_el3 = object_property_find(cpuobj, "has_el3", NULL) && object_property_get_bool(cpuobj, "has_el3", &error_abort); qdev_prop_set_bit(gicdev, "has-security-extensions", has_el3);