From nobody Sun Apr 6 22:18:24 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; 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; dmarc=pass(p=quarantine dis=none) header.from=kernel.org ARC-Seal: i=1; a=rsa-sha256; t=1736945521; cv=none; d=zohomail.com; s=zohoarc; b=aVBDmA7o92Yp9SFk+yQ1/VvJsixpq+VP6t+9sNiHztvZ80qNe/evY2qdOTGPNU/3n3rhiOsSob89Kby0+laQQFQUOy/YRhPRHMl1xc4Mm/uD4CQR0VEBmPri5hP1g0VOz8arcAbh1x+Kb+BtvWJPpH5oo+t35IVH1Zz1vMY5+wk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1736945521; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=lR3fVOY3g4ehb77yW3uS7yXNPGV/+fMXvzpHnEiTBAI=; b=h8pkZ1OCiOZ4usuczZE6nnKk2iD4fNBlnnMRxoOxpRloUWCf55txJ8WIYEEWT0fTqrtPFnnT77sNnFvhmmLNhcftSDiTLKdorWQtbrdVzhR8KA+hJGyh9/eA+WUccIcun5HO+5Pi2+nEOR4SXT1/egsdyJhAPajF3O6wXX5L6BM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; 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; dmarc=pass header.from= (p=quarantine dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1736945520997708.1007510515036; Wed, 15 Jan 2025 04:52:00 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tY2rZ-0007g3-4H; Wed, 15 Jan 2025 07:51:13 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tY2rL-0007c9-Gd; Wed, 15 Jan 2025 07:50:59 -0500 Received: from nyc.source.kernel.org ([2604:1380:45d1:ec00::3]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tY2rH-0006q7-VI; Wed, 15 Jan 2025 07:50:58 -0500 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by nyc.source.kernel.org (Postfix) with ESMTP id 60E66A41F41; Wed, 15 Jan 2025 12:48:53 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 16535C4AF0B; Wed, 15 Jan 2025 12:50:41 +0000 (UTC) Received: from mchehab by mail.kernel.org with local (Exim 4.98) (envelope-from ) id 1tY2r1-00000004yFP-0BOq; Wed, 15 Jan 2025 13:50:39 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1736945441; bh=XnsenWzyXY6TfpyfSZrWfMTz6cEF8BKuThN2HBT4U7c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Rc3MLYn7bWabo8awSEWLAPflf7nisnpJTnjC10QI6d2VvJiu3yLsmqQ3ZzIT2uqqR lXXUYFUdoro4NThFOD9pdrCGlexDP7tVkOh4xzIk64Qz8xw027kDCL2x0mXsC/MFCu Aue8TtWOBIH8/+z3/NGE6hDiQIJ/7LvFXgJlbd9qfQyafolDAuLCP9ZEWUFWMPPWpc gb4SAfmtBMvRXkoIsHG9ucEpWlyOF/HV/MmTiyqWgofYypvSoXHINxAmVfDq5+mM7J Wzeq57I4ULhx17+1L3S4/11+DsaTEoetqCAjoSVhOEnaZP8sZzN9hzHQA3em0oxpwI 0kI7zh+Rxn/lA== From: Mauro Carvalho Chehab To: Igor Mammedov , "Michael S . Tsirkin" Cc: Jonathan Cameron , Shiju Jose , qemu-arm@nongnu.org, qemu-devel@nongnu.org, Mauro Carvalho Chehab , Ani Sinha , Dongjiu Geng , linux-kernel@vger.kernel.org Subject: [PATCH v7 01/16] acpi/ghes: get rid of ACPI_HEST_SRC_ID_RESERVED Date: Wed, 15 Jan 2025 13:50:17 +0100 Message-ID: <9012bf4c9630adf15a22af3c88fda8270916887b.1736945236.git.mchehab+huawei@kernel.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: References: 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=2604:1380:45d1:ec00::3; envelope-from=mchehab+huawei@kernel.org; helo=nyc.source.kernel.org X-Spam_score_int: -44 X-Spam_score: -4.5 X-Spam_bar: ---- X-Spam_report: (-4.5 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.141, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, 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.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @kernel.org) X-ZM-MESSAGEID: 1736945521531019000 Content-Type: text/plain; charset="utf-8" This is just duplicating ACPI_GHES_ERROR_SOURCE_COUNT, which has a better name. So, drop the duplication. Signed-off-by: Mauro Carvalho Chehab Reviewed-by: Igor Mammedov Reviewed-by: Jonathan Cameron --- hw/acpi/ghes.c | 7 ++----- include/hw/acpi/ghes.h | 3 ++- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/hw/acpi/ghes.c b/hw/acpi/ghes.c index e9511d9b8f71..dc217694deb9 100644 --- a/hw/acpi/ghes.c +++ b/hw/acpi/ghes.c @@ -34,9 +34,6 @@ /* The max size in bytes for one error block */ #define ACPI_GHES_MAX_RAW_DATA_LENGTH (1 * KiB) =20 -/* Now only support ARMv8 SEA notification type error source */ -#define ACPI_GHES_ERROR_SOURCE_COUNT 1 - /* Generic Hardware Error Source version 2 */ #define ACPI_GHES_SOURCE_GENERIC_ERROR_V2 10 =20 @@ -396,7 +393,7 @@ int acpi_ghes_record_errors(uint8_t source_id, uint64_t= physical_address) AcpiGedState *acpi_ged_state; AcpiGhesState *ags; =20 - assert(source_id < ACPI_HEST_SRC_ID_RESERVED); + assert(source_id < ACPI_GHES_ERROR_SOURCE_COUNT); =20 acpi_ged_state =3D ACPI_GED(object_resolve_path_type("", TYPE_ACPI_GED, NULL)); @@ -407,7 +404,7 @@ int acpi_ghes_record_errors(uint8_t source_id, uint64_t= physical_address) =20 if (physical_address) { =20 - if (source_id < ACPI_HEST_SRC_ID_RESERVED) { + if (source_id < ACPI_GHES_ERROR_SOURCE_COUNT) { start_addr +=3D source_id * sizeof(uint64_t); } =20 diff --git a/include/hw/acpi/ghes.h b/include/hw/acpi/ghes.h index 674f6958e905..59e3b8fb24b9 100644 --- a/include/hw/acpi/ghes.h +++ b/include/hw/acpi/ghes.h @@ -59,7 +59,8 @@ enum AcpiGhesNotifyType { enum { ACPI_HEST_SRC_ID_SEA =3D 0, /* future ids go here */ - ACPI_HEST_SRC_ID_RESERVED, + + ACPI_GHES_ERROR_SOURCE_COUNT }; =20 typedef struct AcpiGhesState { --=20 2.47.1