From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7C35FD216A4 for ; Thu, 4 Dec 2025 15:53:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 401AF10E204; Thu, 4 Dec 2025 15:53:07 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="mQbG3uvv"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.8]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1D43910E204 for ; Thu, 4 Dec 2025 15:53:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1764863586; x=1796399586; h=message-id:date:subject:to:cc:references:from: in-reply-to:mime-version; bh=fxhMbhvktHi8tAOBvJU7F7Pp4c4ctTEqoEAapbERD+s=; b=mQbG3uvv4uEkyLRSepm5oG4GXlD0xurmlcuKqUyXTBPDLg9kI36A6q34 l78NN1DGwaPbzGpJp4XY1bP4P1NsIZxX3jayo+giXMJUrKynxfgvYR0y2 xCovJ2EE2JpHMMtFNHJvuaVg5gnGP4SIplemwNMyG8lX0dUhMPNYY6A2Q RfnxGN1xOAPI8J493l3OtUF4MSrQNjL2dGSiC2RYVgy1q5X4ZxMeJBh7h KsI+PMvGODka6RVoj9NbHHmzcxH0Qg81vlG+HbiVFtu+TzrdtgwEduxRu M9kaT1ExhD1HpuaR0Xxv1mwqlG0+LY3mr1996wtCCjbP8B01R+NVkepTl w==; X-CSE-ConnectionGUID: bCUIEEMjRqqXLfBP95dzXg== X-CSE-MsgGUID: rTaKeMv4TOmGKmAjKv2jqA== X-IronPort-AV: E=McAfee;i="6800,10657,11632"; a="84492345" X-IronPort-AV: E=Sophos;i="6.20,249,1758610800"; d="scan'208,217";a="84492345" Received: from fmviesa010.fm.intel.com ([10.60.135.150]) by fmvoesa102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Dec 2025 07:49:18 -0800 X-CSE-ConnectionGUID: gZHpTeskTCm7UGSZjeOxmg== X-CSE-MsgGUID: JeOFRDrTSxeUaCrbGBpSUQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.20,249,1758610800"; d="scan'208,217";a="195825121" Received: from fmsmsx902.amr.corp.intel.com ([10.18.126.91]) by fmviesa010.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Dec 2025 07:49:17 -0800 Received: from FMSMSX903.amr.corp.intel.com (10.18.126.92) by fmsmsx902.amr.corp.intel.com (10.18.126.91) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Thu, 4 Dec 2025 07:49:17 -0800 Received: from fmsedg903.ED.cps.intel.com (10.1.192.145) by FMSMSX903.amr.corp.intel.com (10.18.126.92) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29 via Frontend Transport; Thu, 4 Dec 2025 07:49:17 -0800 Received: from CH5PR02CU005.outbound.protection.outlook.com (40.107.200.43) by edgegateway.intel.com (192.55.55.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Thu, 4 Dec 2025 07:49:16 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Jy3SjOVg1fIKPU8tnCMm4RMr84nA0jDt8eNX2BxnSvJTYVtE+Eg3pU/9JJ1BJmlBeMvRVSRVpyJjtyvL62qbSktnpfAxs3gB6AviwtS2lN4m7zJ2QgDAp+SxOLFW3A2huR4RudszGU72DXgBR7yF3/JaqtHEucAMAOpj+NsjYwCVutST7jwmme5mcsZuQOws3NxVTNwguwSP2gAID5Kh4+G8kNJfVAGuIs5aNImz9WDpUHuzmAci8hejLvBwudoza1toeS7Lel82YUe0kOHgsyhY3nixJng1RVJxtmfUoOEG3RMwOhccSTPuDXn3pnMVnpLdUavJ16kVA6BvZO59sQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=hEFvXspJnb879OWtBEmN3d31REHNAPdCkQZqsD7p/Jo=; b=k/TusPTihveDV/NPrkoOuy8W6K0kBJLCHflCTjnKelQBQnWPTSq+ZwbbTtyduxlauzW0Y+1Et7vcuqdE01duJlrt/qGUw56xQOnFSl2zYdmczI52RZHWSGZViMXDSYdnx5bItJJS/uhCTUapGubOsc4NXmgTXZ844BqzcPGxscdFleKsLgQK1CM6GazJHWBwAc9fF2rx4xa0px+Ekg1DZvD+1cGVZ7dtmMLOkqcaU8d94t1HB67M56YYD8mtMyHa689gXqiZp9bbZNJHGDTpUl6abLPygicT2aEAFFG+h7sD7R5F6DLIgdqQYBeQysNqFHjvhyuIQ0mCvPg6qB1hiA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from BN9PR11MB5530.namprd11.prod.outlook.com (2603:10b6:408:103::8) by SA2PR11MB5179.namprd11.prod.outlook.com (2603:10b6:806:112::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9388.9; Thu, 4 Dec 2025 15:49:14 +0000 Received: from BN9PR11MB5530.namprd11.prod.outlook.com ([fe80::13bd:eb49:2046:32a9]) by BN9PR11MB5530.namprd11.prod.outlook.com ([fe80::13bd:eb49:2046:32a9%4]) with mapi id 15.20.9388.003; Thu, 4 Dec 2025 15:49:14 +0000 Content-Type: multipart/alternative; boundary="------------X6fh8axO6PErEaV0d0M9gH83" Message-ID: <5835e6ab-95c6-467e-a8b7-ac62610af093@intel.com> Date: Thu, 4 Dec 2025 21:19:03 +0530 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 1/3] drm/xe/soc_remapper: Initialize SoC remapper during Xe probe To: Umesh Nerlige Ramappa , CC: , References: <20251203004800.1993258-5-umesh.nerlige.ramappa@intel.com> <20251203004800.1993258-6-umesh.nerlige.ramappa@intel.com> Content-Language: en-US From: "Nilawar, Badal" In-Reply-To: X-ClientProxiedBy: MA5PR01CA0195.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a01:1b2::6) To BN9PR11MB5530.namprd11.prod.outlook.com (2603:10b6:408:103::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN9PR11MB5530:EE_|SA2PR11MB5179:EE_ X-MS-Office365-Filtering-Correlation-Id: 79eef256-c8bf-4470-b419-08de334cacb1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|376014|366016|8096899003; X-Microsoft-Antispam-Message-Info: =?utf-8?B?bFRlbE1QY3NETEZwZnBDRWNSMTI4VUhpOVJ4bmk0cjBrTE5HZGEwMW9BWnZW?= =?utf-8?B?Ykd5QkhvYmVaNzZpaDdMTjZQUnJsRXpwamlGQU5KbHFRbkxxWkRCMXRKTk04?= =?utf-8?B?QTl0NVordWxtSHhkc3hWdmUrNUx2SER4M05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QezNZNMizzqQHrS5QiFAE4IqAb?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BN9PR11MB5530.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(1800799024)(376014)(366016)(8096899003); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?OHhaelhuTHllcU5HT3NKZlBkZk13cXZ2RFlLYk5NUjgzY3dELysxcUdaRUZu?= =?utf-8?B?QVlsMktzbnI0WUtLRGxpRms3bUhERWhSOU85Y2xSTjNOdE1WZDV6eEY3OFhy?= =?utf-8?B?OG1XOUxkUTZOMXhhL3lpYm1IY0EzcVdGbnRUSHVydjh2aEhDQlphZkRuUDlW?= =?utf-8?B?Ry9oUisvVXJBM1UydnpmQnY4bnoyQ2YvZjBLazNVYkt0Z2JiU0IveDhxeHND?= =?utf-8?B?UElZSlF4VmVaUlp6OWRuRFBocXFSNVJUTGVSZTZxSElSVUV6d2ZXbDh0bVFp?= =?utf-8?B?UjR5aHVWMU9LZHd0NlgyT3cyeC9PN21VMkx5SytqWUh0V0RUdXNaUTZhVjhN?= =?utf-8?B?VDg4a2EzU2NDcHhQbkdPeTVONzk0UE9KeWpzTW1tWWVocFVrWTdwdWsvV3Ns?= =?utf-8?B?akFPZitPZVZOQ2xBelBsUDBvRlZ6UWZjL0paaFUyTks3YS9sZnVkbjZZbm9W?= =?utf-8?B?VXNmMkZCZWMwMkE2VjhzbXpmdXR2Rjd4UFFzVHcvSVhjZjdoYzlwODhia0t2?= =?utf-8?B?Rm1VKzl6d0FkUzNGemRMblpKaE1ianl2blBJYWh1THBMSmVLbUZ2R2JEcjFm?= =?utf-8?B?Z0d6Z1ByeUNZTElJSUNjcjhvdHhLVUtEVWp5NGxSa3NlcnFGUkNiTllSZU1a?= =?utf-8?B?cXZ2NWxPNkJxOXRLUy8zNjB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I3ZFhRVldISks1VW1CaG5sZCtrMzA0MEhvcTY0UnpHTHpjbTBWOUNx?= =?utf-8?B?aWJTMU12NXlLeXRDdU8vcWV0eWpSZ2N5eFpHS1UyLytmR3FUT1RSdUd6ZUc1?= =?utf-8?B?bitSUkUxbzJnN0Q2cnZ3Um1CVUtEMy9DUlZjRU5FNEU4OEM2eWo0UExsS3Zy?= =?utf-8?B?bWhxTXNlR2l0SGtrZXc2eEpSY0FVQjZpZ3pud1ZybUg2Z2FpNVRrb2tOaXJy?= =?utf-8?B?YVhhS0p1SHd4ZTBVcEtuTXpuNk9Hbmp0R2lyMDMvZXhPZzJZOFYwL0pQMzlx?= =?utf-8?B?eFhYUG92WGVlU1lwQjNwSEUyd2tmeTFYblAwZEQySlhnSVV6aW9vMDRUYUF5?= =?utf-8?B?a0tSNXplaDcrSkUvN3JyeUlaT0hsbjMzbTQ4amZSQjZhbUt3dHRCeEVsSWJa?= =?utf-8?B?cUZ6VDdXK3dXR1RIc0JZUDVrdnFNZTg2dFlTdmROVHR5dDV5Y014ZEF4WVM1?= =?utf-8?B?MG4xTytHd2JFd2tQV1RVUkhhNlBZUm9FRldRa3RqZGxvU0M4Z25ib2oyRTNI?= =?utf-8?B?VHdUUUpCSnl5SmIwZjh0NEtSM3VhTWZCNzZCcVpTRGtCcUd6U0pERVZRY0JC?= =?utf-8?B?alE9PQ==?= X-MS-Exchange-CrossTenant-Network-Message-Id: 79eef256-c8bf-4470-b419-08de334cacb1 X-MS-Exchange-CrossTenant-AuthSource: BN9PR11MB5530.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Dec 2025 15:49:14.5096 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: oQT51+NiB7SgQ8Lx9dhtlUYTrnd/+9Nqd8Rw39o7kCIyg9tcllCwM149GS/dL/EBxOLPKaT5iHnWfK5+/FtY6w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA2PR11MB5179 X-OriginatorOrg: intel.com X-BeenThere: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-xe-bounces@lists.freedesktop.org Sender: "Intel-xe" --------------X6fh8axO6PErEaV0d0M9gH83 Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit On 03-12-2025 22:36, Umesh Nerlige Ramappa wrote: > On Tue, Dec 02, 2025 at 04:48:02PM -0800, Umesh Nerlige Ramappa wrote: >> SoC remapper is used to map different HW functions in the SoC to their >> respective drivers. Initialize SoC remapper during driver load. >> >> Signed-off-by: Umesh Nerlige Ramappa >> --- >> v2: (Ashutosh/Lucas) >> - s/remapper/soc_remapper/ >> - return status from init during probe >> - reorder patches 1 and 2 from earlier series >> - fix copyright year >> >> v3: (Michal, Badal) >> - Kernel doc fixes >> - Alphabetical order for headers/objects >> - Add has_soc_remapper >> - Drop unnecessary headers >> --- >> drivers/gpu/drm/xe/Makefile          |  1 + >> drivers/gpu/drm/xe/xe_device.c       |  5 +++++ >> drivers/gpu/drm/xe/xe_device_types.h |  8 ++++++++ >> drivers/gpu/drm/xe/xe_pci.c          |  2 ++ >> drivers/gpu/drm/xe/xe_pci_types.h    |  2 ++ >> drivers/gpu/drm/xe/xe_soc_remapper.c | 24 ++++++++++++++++++++++++ >> drivers/gpu/drm/xe/xe_soc_remapper.h | 13 +++++++++++++ >> 7 files changed, 55 insertions(+) >> create mode 100644 drivers/gpu/drm/xe/xe_soc_remapper.c >> create mode 100644 drivers/gpu/drm/xe/xe_soc_remapper.h >> >> diff --git a/drivers/gpu/drm/xe/Makefile b/drivers/gpu/drm/xe/Makefile >> index 0eadfeda67d9..06c3987afd4c 100644 >> --- a/drivers/gpu/drm/xe/Makefile >> +++ b/drivers/gpu/drm/xe/Makefile >> @@ -115,6 +115,7 @@ xe-y += xe_bb.o \ >>     xe_sa.o \ >>     xe_sched_job.o \ >>     xe_shrinker.o \ >> +    xe_soc_remapper.o \ >>     xe_step.o \ >>     xe_survivability_mode.o \ >>     xe_sync.o \ >> diff --git a/drivers/gpu/drm/xe/xe_device.c >> b/drivers/gpu/drm/xe/xe_device.c >> index 92f883dd8877..b54fc5852fef 100644 >> --- a/drivers/gpu/drm/xe/xe_device.c >> +++ b/drivers/gpu/drm/xe/xe_device.c >> @@ -61,6 +61,7 @@ >> #include "xe_pxp.h" >> #include "xe_query.h" >> #include "xe_shrinker.h" >> +#include "xe_soc_remapper.h" >> #include "xe_survivability_mode.h" >> #include "xe_sriov.h" >> #include "xe_tile.h" >> @@ -906,6 +907,10 @@ int xe_device_probe(struct xe_device *xe) >> >>     xe_nvm_init(xe); >> >> +    err = xe_soc_remapper_init(xe); >> +    if (err) >> +        return err; >> + >>     err = xe_heci_gsc_init(xe); >>     if (err) >>         return err; >> diff --git a/drivers/gpu/drm/xe/xe_device_types.h >> b/drivers/gpu/drm/xe/xe_device_types.h >> index 9a9a8eb84a78..450fe703a3b9 100644 >> --- a/drivers/gpu/drm/xe/xe_device_types.h >> +++ b/drivers/gpu/drm/xe/xe_device_types.h >> @@ -315,6 +315,8 @@ struct xe_device { >>         u8 has_pxp:1; >>         /** @info.has_range_tlb_inval: Has range based TLB >> invalidations */ >>         u8 has_range_tlb_inval:1; >> +        /** @info.has_soc_remapper: Has SoC remapper support */ >> +        u8 has_soc_remapper:1; >>         /** @info.has_sriov: Supports SR-IOV */ >>         u8 has_sriov:1; >>         /** @info.has_usm: Device has unified shared memory support */ >> @@ -555,6 +557,12 @@ struct xe_device { >>         struct mutex lock; >>     } pmt; >> >> +    /** @soc_remapper: SoC remapper object */ >> +    struct { >> +        /** @soc_remapper.lock: Serialize access to SoC Remapper's >> index registers */ >> +        spinlock_t lock; >> +    } soc_remapper; >> + >>     /** >>      * @pm_callback_task: Track the active task that is running in >> either >>      * the runtime_suspend or runtime_resume callbacks. >> diff --git a/drivers/gpu/drm/xe/xe_pci.c b/drivers/gpu/drm/xe/xe_pci.c >> index 75e3588242c7..ec0fed691fa0 100644 >> --- a/drivers/gpu/drm/xe/xe_pci.c >> +++ b/drivers/gpu/drm/xe/xe_pci.c >> @@ -413,6 +413,7 @@ static const struct xe_device_desc cri_desc = { >>     .has_flat_ccs = false, >>     .has_mbx_power_limits = true, >>     .has_mert = true, >> +    .has_soc_remapper = true, > > Needs to be enabled for BMG also, hence the BAT failure. We should use has_soc_remapper not just for protecting spinlock initialization, but also for guarding soc remapper accesses. Since there are two soc remappers—SC and Telemetry—we could update has_soc_remapper to use 2 bits (u8 has_soc_remapper:2), and set only the relevant bits in the platform descriptor. For example: static const struct xe_device_desc bmg_desc = {     .has_soc_remapper = SOC_REMAP_TELEM static const struct xe_device_desc cri_desc = {     .has_soc_remapper = SOC_REMAP_TELEM | SOC_REMAP_SC If we prefer a true/false approach, we should use two separate flags: has_soc_telem_remapper and has_soc_sc_remapper. Thanks, Badal > Umesh --------------X6fh8axO6PErEaV0d0M9gH83 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: 8bit


On 03-12-2025 22:36, Umesh Nerlige Ramappa wrote:
On Tue, Dec 02, 2025 at 04:48:02PM -0800, Umesh Nerlige Ramappa wrote:
SoC remapper is used to map different HW functions in the SoC to their
respective drivers. Initialize SoC remapper during driver load.

Signed-off-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
---
v2: (Ashutosh/Lucas)
- s/remapper/soc_remapper/
- return status from init during probe
- reorder patches 1 and 2 from earlier series
- fix copyright year

v3: (Michal, Badal)
- Kernel doc fixes
- Alphabetical order for headers/objects
- Add has_soc_remapper
- Drop unnecessary headers
---
drivers/gpu/drm/xe/Makefile          |  1 +
drivers/gpu/drm/xe/xe_device.c       |  5 +++++
drivers/gpu/drm/xe/xe_device_types.h |  8 ++++++++
drivers/gpu/drm/xe/xe_pci.c          |  2 ++
drivers/gpu/drm/xe/xe_pci_types.h    |  2 ++
drivers/gpu/drm/xe/xe_soc_remapper.c | 24 ++++++++++++++++++++++++
drivers/gpu/drm/xe/xe_soc_remapper.h | 13 +++++++++++++
7 files changed, 55 insertions(+)
create mode 100644 drivers/gpu/drm/xe/xe_soc_remapper.c
create mode 100644 drivers/gpu/drm/xe/xe_soc_remapper.h

diff --git a/drivers/gpu/drm/xe/Makefile b/drivers/gpu/drm/xe/Makefile
index 0eadfeda67d9..06c3987afd4c 100644
--- a/drivers/gpu/drm/xe/Makefile
+++ b/drivers/gpu/drm/xe/Makefile
@@ -115,6 +115,7 @@ xe-y += xe_bb.o \
    xe_sa.o \
    xe_sched_job.o \
    xe_shrinker.o \
+    xe_soc_remapper.o \
    xe_step.o \
    xe_survivability_mode.o \
    xe_sync.o \
diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c
index 92f883dd8877..b54fc5852fef 100644
--- a/drivers/gpu/drm/xe/xe_device.c
+++ b/drivers/gpu/drm/xe/xe_device.c
@@ -61,6 +61,7 @@
#include "xe_pxp.h"
#include "xe_query.h"
#include "xe_shrinker.h"
+#include "xe_soc_remapper.h"
#include "xe_survivability_mode.h"
#include "xe_sriov.h"
#include "xe_tile.h"
@@ -906,6 +907,10 @@ int xe_device_probe(struct xe_device *xe)

    xe_nvm_init(xe);

+    err = xe_soc_remapper_init(xe);
+    if (err)
+        return err;
+
    err = xe_heci_gsc_init(xe);
    if (err)
        return err;
diff --git a/drivers/gpu/drm/xe/xe_device_types.h b/drivers/gpu/drm/xe/xe_device_types.h
index 9a9a8eb84a78..450fe703a3b9 100644
--- a/drivers/gpu/drm/xe/xe_device_types.h
+++ b/drivers/gpu/drm/xe/xe_device_types.h
@@ -315,6 +315,8 @@ struct xe_device {
        u8 has_pxp:1;
        /** @info.has_range_tlb_inval: Has range based TLB invalidations */
        u8 has_range_tlb_inval:1;
+        /** @info.has_soc_remapper: Has SoC remapper support */
+        u8 has_soc_remapper:1;
        /** @info.has_sriov: Supports SR-IOV */
        u8 has_sriov:1;
        /** @info.has_usm: Device has unified shared memory support */
@@ -555,6 +557,12 @@ struct xe_device {
        struct mutex lock;
    } pmt;

+    /** @soc_remapper: SoC remapper object */
+    struct {
+        /** @soc_remapper.lock: Serialize access to SoC Remapper's index registers */
+        spinlock_t lock;
+    } soc_remapper;
+
    /**
     * @pm_callback_task: Track the active task that is running in either
     * the runtime_suspend or runtime_resume callbacks.
diff --git a/drivers/gpu/drm/xe/xe_pci.c b/drivers/gpu/drm/xe/xe_pci.c
index 75e3588242c7..ec0fed691fa0 100644
--- a/drivers/gpu/drm/xe/xe_pci.c
+++ b/drivers/gpu/drm/xe/xe_pci.c
@@ -413,6 +413,7 @@ static const struct xe_device_desc cri_desc = {
    .has_flat_ccs = false,
    .has_mbx_power_limits = true,
    .has_mert = true,
+    .has_soc_remapper = true,

Needs to be enabled for BMG also, hence the BAT failure. 

We should use has_soc_remapper not just for protecting spinlock initialization, but also for guarding soc remapper accesses.

Since there are two soc remappers—SC and Telemetry—we could update has_soc_remapper to use 2 bits (u8 has_soc_remapper:2), and set only the relevant bits in the platform descriptor. For example:

static const struct xe_device_desc bmg_desc = {
    .has_soc_remapper = SOC_REMAP_TELEM 
    
static const struct xe_device_desc cri_desc = {
    .has_soc_remapper = SOC_REMAP_TELEM | SOC_REMAP_SC 

If we prefer a true/false approach, we should use two separate flags: has_soc_telem_remapper and has_soc_sc_remapper.

Thanks,
Badal

Umesh
--------------X6fh8axO6PErEaV0d0M9gH83--