From nobody Tue May 14 22:58:33 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.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=1601041247; cv=none; d=zohomail.com; s=zohoarc; b=AFVC2f/uRjfRyZ91xfBoZvaQi98gYbXRucFEDUe00S079tKDa+hfFUwe7mK09ABai7Zh2+pYJz48pYsoAnmASa752dys0EcE21yvGakaOKFHabGyDT4DRBPpkGl3XaLsAouAPcJcrqP3F1LyP3onYA784rSKfkNXrxrSkY84BfM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1601041247; h=Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=LEapBT5lGA8vRx16w4G1jp1xfCgBRVKisEf5jOFHwNk=; b=GP1gBkC9xzVIdhazcKiAgpaZnt2JQV0Qd/YUXhLbTxLo35Ok9ROpDUd7c6UdrH7ddWgnZRgCHzHlHcoOvntisvGGL/viau10eOg0IA1HpAXzNhO0I4S/bJ7z12xAUgvUjuteWikMfIa2NnVcF7CUqza28OiDvL/svtd/RH5iCec= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.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 1601041247665738.2368221528103; Fri, 25 Sep 2020 06:40:47 -0700 (PDT) Received: from localhost ([::1]:45674 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kLnxu-0002nS-AR for importer@patchew.org; Fri, 25 Sep 2020 09:40:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60396) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kLnwc-0001vu-6Y for qemu-devel@nongnu.org; Fri, 25 Sep 2020 09:39:26 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:55765) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kLnwa-0007h9-8F for qemu-devel@nongnu.org; Fri, 25 Sep 2020 09:39:25 -0400 Received: by mail-wm1-x341.google.com with SMTP id d4so3058069wmd.5 for ; Fri, 25 Sep 2020 06:39:23 -0700 (PDT) Received: from localhost.localdomain ([2a02:8010:64d6::1d89]) by smtp.gmail.com with ESMTPSA id d19sm2860921wmd.0.2020.09.25.06.39.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Sep 2020 06:39:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nuviainc-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LEapBT5lGA8vRx16w4G1jp1xfCgBRVKisEf5jOFHwNk=; b=RLWl3FczdndaCQi72oSqFi7gKVxG4d3TI/DKrEKNspCwS/LDF2qLUaQAh01iiQWhGh BILQvgjftHjqR/mDwjXlzkV/x8Pvzas7ezgn4nUIuOHMKfYLkGXxxY0p3JiIkc7MMMcg 3g5Sswy1YvQW9yTzjOySfBDpOTAtYBYAU1JN89EWMc1ZHQtO2xTuT0EZNY/S/fVIb8i0 LXzDj98UbrEOlFIetefcIgJj0dcJawaTGUG0NorQtP4Vd32nex3bq+N+hXob4Twfrcm4 3gcnPr9EqSEjlXNIU6voD7sBqKBeN8rNo8SgCzk4B8lDwich5zKdlEbUCisF38N9LJf9 bWuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LEapBT5lGA8vRx16w4G1jp1xfCgBRVKisEf5jOFHwNk=; b=gnATZRcAO8NaCey+T73z3s/1OqWWYdDi/n54/DwFohSNF9NbD+eOVbA9raE9727hSa QpZxKUMoVhkr+UiS90yzx9CR7KIvc3y4A2YqnSRqgSyJuRHFK4FLyFLS2c/zO8T8y/F2 JL+YDW71/azktcMrupq2hgnSsaV2lBZgoT7Yf5pT/O3Q7IdHYyN1ed4wn6NPd3YK1RmN IHbNjhrQXn9+JW0tr9Z4EsGwjFapPBWFYA+A7kZI2+Y53gw5l68pX2Bi0GJyZp+0uOaK 6kspCGneliDs2BY1wA009j8Jv9GN+xd5wzSA1oAM9Lw455cDFUW+li7ofNvk+mCXMimY +xZw== X-Gm-Message-State: AOAM530z3Z72xPYtUeuBQUejzuXEew8NJjEAR1KEkkrQcX1H724K0TuG j5qJcICrHTYOZXt2YGx3r27VyQ== X-Google-Smtp-Source: ABdhPJz+0ee5DDPSTzodMmcCR3wUh/2zd8CCBLSRxEum+RTwgUd1LwyUPP5xLa+oiu9cGyVAIsNpEw== X-Received: by 2002:a1c:9d43:: with SMTP id g64mr3536112wme.16.1601041162147; Fri, 25 Sep 2020 06:39:22 -0700 (PDT) From: Graeme Gregory To: qemu-arm@nongnu.org Subject: [PATCH] hw/arm/sbsa-ref : Fix SMMUv3 Initialisation Date: Fri, 25 Sep 2020 14:39:02 +0100 Message-Id: <20200925133902.28349-1-graeme@nuviainc.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.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; Received-SPF: pass client-ip=2a00:1450:4864:20::341; envelope-from=graeme@nuviainc.com; helo=mail-wm1-x341.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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: Graeme Gregory , peter.maydell@linaro.org, jamie@nuviainc.com, rad@semihalf.com, qemu-devel@nongnu.org, leif@nuviainc.com, philmd@redhat.com 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" SMMUv3 has an error in previous patch where a i was transposed to a 1 meaning interrupts would not have been correctly assigned to the SMMUv3 instance. The code also contained an error in that the IRQs were never allocated in the irqmap. Fixes: 48ba18e6d3f3 ("hw/arm/sbsa-ref: Simplify by moving the gic in the ma= chine state") Signed-off-by: Graeme Gregory Reviewed-by: Eric Auger --- hw/arm/sbsa-ref.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/arm/sbsa-ref.c b/hw/arm/sbsa-ref.c index 257ada9425..9109fb58be 100644 --- a/hw/arm/sbsa-ref.c +++ b/hw/arm/sbsa-ref.c @@ -138,6 +138,7 @@ static const int sbsa_ref_irqmap[] =3D { [SBSA_SECURE_UART_MM] =3D 9, [SBSA_AHCI] =3D 10, [SBSA_EHCI] =3D 11, + [SBSA_SMMU] =3D 12, /* ... to 15 */ }; =20 static uint64_t sbsa_ref_cpu_mp_affinity(SBSAMachineState *sms, int idx) @@ -530,7 +531,7 @@ static void create_smmu(const SBSAMachineState *sms, PC= IBus *bus) sysbus_mmio_map(SYS_BUS_DEVICE(dev), 0, base); for (i =3D 0; i < NUM_SMMU_IRQS; i++) { sysbus_connect_irq(SYS_BUS_DEVICE(dev), i, - qdev_get_gpio_in(sms->gic, irq + 1)); + qdev_get_gpio_in(sms->gic, irq + i)); } } =20 --=20 2.25.1