Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1314505rdb; Mon, 19 Feb 2024 10:59:30 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXJeMgh7o+tfq8Y8k+NTIXBXljxu0sx052SNtqpr6MOBUY7jGbAhQHXwKaTWq/omD4yVzN2ocN5CNvGadNfzwXDvpXHtZX5k+Ahn1iw6g== X-Google-Smtp-Source: AGHT+IG9jM5Np0dbT+SUslkn0RGsp+RprfP030Zaa+PVoTCShQNUIlMaQiHTktibloO4nzV4Ym0s X-Received: by 2002:a05:6808:124d:b0:3c0:335c:e8c5 with SMTP id o13-20020a056808124d00b003c0335ce8c5mr16885770oiv.33.1708369170586; Mon, 19 Feb 2024 10:59:30 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708369170; cv=pass; d=google.com; s=arc-20160816; b=c6WsWYwQT1nzZ6HrUKCGjUBAGlw7rnd/DORbYdH6PbnZaWRaFq9MN4JIPXEQH3N8Zr QD4HQvN1ajc02wS/WsZCYVkx9qdS7+rgiXrykONuNqAqpw8MNi5fU2AbBQEC2Z+hsrgt LczfWXnAEDPF52pOomrEQJL+NySq1KjMip7YUB2XkqRrfStojpaH1X+dAyWhxZJaves1 bAYWi0oOMfMrQmXosRq3P7rYDJe8eXEUqIIJoboK939cLqb8zzHnb5D4gmZ5Jp8hIN8t dHRzBx+ZmtD7gAGauKUCydbeH28kPKZ/RPN66V+3vHrY8GEny+MsnWmXQBOUWvhEGhb5 jY3g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=O6mYbl34iGDajSSuwNwYK5N248BsKIXOEJAXAf9uLUE=; fh=fgV4Kp0ZgGkINw9PbGnSyYl5n9Uaijr/GJFF1V5tx/4=; b=oQ97gvKJvLddnRhZw6l1E9sNtZWiBnwEqM1dghK5TbS36szZb8DUwigcJPmsZ4wNOW NtZUje9hof2TtH8XHouoxxpZxiRNODmAJb/gDGD0zwCydM2zWPlbcZiH9PWVAMU6nva7 pgzqbnVWuqbQcyLO6dILeTjMJrkhbNeq8QIpAiYrfDpuXW2ZomBOiALTY2SixF3CHprq UvvtBRGl5xne5ejnG+SwNWIJ4I6aiptEGGKXJnmL2mdmHDxvKrZZVQ4yYQF5tUWQwYyr xKmAjn89IQwe+q6gTOTPEx+L4QEIwdWGeOAOJF60ee967l4q1XXaoSu17kdzFD5KEtoQ JL2A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=erdwcROx; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-71849-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-71849-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id e1-20020a056a0000c100b006e2ff5d32e3si4340595pfj.372.2024.02.19.10.59.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 10:59:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-71849-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=erdwcROx; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-71849-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-71849-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 4886C284250 for ; Mon, 19 Feb 2024 18:59:30 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C73084F21A; Mon, 19 Feb 2024 18:58:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="erdwcROx" Received: from out-176.mta0.migadu.com (out-176.mta0.migadu.com [91.218.175.176]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4C878487A3 for ; Mon, 19 Feb 2024 18:58:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.176 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708369111; cv=none; b=HKqRKFi4IOuQVELcYHEoNJpne7FRovAFyhU6SmgYicZ04pFNPRAl4iGBADCweW48c5ZYfcmtGDZMGgU+fUJJBpYh/35TdHHO+BenfFq66v6RLCkpR89Dl7N6vKckt/N6NzI28qELWsBKvMcQLwHB2/g5UU31apiJecUYa8pBbRA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708369111; c=relaxed/simple; bh=AVsdCCM8FvfXsv0NexSqvyqeP7RkJJs+vf3bnHoUDbA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=AEQqmj4F2Xja86x2jUzuRUZuLloyU+bBvIKgZUjQUP5MmkqFAtBI6Tnx7gVDP5i1RdnF7Lv8ZqEXV9wL+KUVqve3pDHLAZ4V9IchL+05SGssmolAJVchs0IYuAWTBHDkLZWTCqQf4gyJbns2rvh5Gl6VgLj5PhWKmuAg55cMnPc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=erdwcROx; arc=none smtp.client-ip=91.218.175.176 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1708369107; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=O6mYbl34iGDajSSuwNwYK5N248BsKIXOEJAXAf9uLUE=; b=erdwcROxjTVj9GYsF9NxwZtHNpUShYCx45EDDOMeS+jAJihxWdrPa0U1lhk/4/FnuC7+2g 6JUYy8lf8giYc6dFvutLvzVCiE2tKOwcceN27OylehFuPrm9rlUze2Uoy930paO+8vWiFX OVADPtybepCZRTctZIlkmbbnW0WSTKY= From: Oliver Upton To: Thomas Gleixner Cc: Marc Zyngier , Zenghui Yu , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kvmarm@lists.linux.dev, Jing Zhang , Oliver Upton Subject: [PATCH 3/3] irqchip/gic-v3-its: Print the vPE table installed in redistributor Date: Mon, 19 Feb 2024 18:58:08 +0000 Message-ID: <20240219185809.286724-4-oliver.upton@linux.dev> In-Reply-To: <20240219185809.286724-1-oliver.upton@linux.dev> References: <20240219185809.286724-1-oliver.upton@linux.dev> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT Hindsight is 20/20 of course, but the recent vPE table programming bug could've been root caused a bit more quickly if we print the table getting installed at every redistributor. Promote to pr_info() and add some additional context, such as the provenance of the installed vPE table. Signed-off-by: Oliver Upton --- drivers/irqchip/irq-gic-v3-its.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c index 63d1743f08cc..c3ef9665a2ad 100644 --- a/drivers/irqchip/irq-gic-v3-its.c +++ b/drivers/irqchip/irq-gic-v3-its.c @@ -2835,7 +2835,8 @@ static int allocate_vpe_l1_table(void) u64 val, gpsz, npg, pa; unsigned int psz = SZ_64K; unsigned int np, epp, esz; - struct page *page; + struct page *page = NULL; + bool from_its = false; if (!gic_rdists->has_rvpeid) return 0; @@ -2865,8 +2866,10 @@ static int allocate_vpe_l1_table(void) return -ENOMEM; val = inherit_vpe_l1_table_from_its(); - if (val & GICR_VPROPBASER_4_1_VALID) + if (val & GICR_VPROPBASER_4_1_VALID) { + from_its = true; goto out; + } /* First probe the page size */ val = FIELD_PREP(GICR_VPROPBASER_4_1_PAGE_SIZE, GIC_PAGE_SIZE_64K); @@ -2945,9 +2948,12 @@ static int allocate_vpe_l1_table(void) gicr_write_vpropbaser(val, vlpi_base + GICR_VPROPBASER); cpumask_set_cpu(smp_processor_id(), gic_data_rdist()->vpe_table_mask); - pr_debug("CPU%d: VPROPBASER = %llx %*pbl\n", - smp_processor_id(), val, - cpumask_pr_args(gic_data_rdist()->vpe_table_mask)); + pr_info("CPU%d: Using %s vPE table @%llx (%s)\n", + smp_processor_id(), + (val & GICR_VPROPBASER_4_1_INDIRECT) ? "indirect" : "direct", + val & GICR_VPROPBASER_4_1_ADDR, + (page) ? "allocated" : + ((from_its) ? "inherited from ITS" : "inherited from RD")); return 0; } -- 2.44.0.rc0.258.g7320e95886-goog