Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp1496352rdb; Wed, 20 Sep 2023 10:39:42 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEqrVYNTJcXMmv9RHCoKBmBV83RIsJTj3/IEcXNJO/cY5Vb+aDd5nN1lxVU6RH6b12aa/Hs X-Received: by 2002:a17:90a:ec14:b0:273:f087:1c8f with SMTP id l20-20020a17090aec1400b00273f0871c8fmr3224040pjy.11.1695231581953; Wed, 20 Sep 2023 10:39:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695231581; cv=none; d=google.com; s=arc-20160816; b=fW8AC3PNQBo+aympmz9sEZrtMQ8bMPoR7t1YmKhC1aS1kDJcmTZNF+tYWyskY911rX arYsXk9VHcP+oTJlbHnntPQJtBKt9CI/PneaNxDWLmP0wE2DpEAl7cvUtTlX4rhq91Hb rpfTxU28bSsr4q2870ULCRw4ewWdcUhC9UCX1ZMdmnIWKoihHe0DNWyLT0aXUXVYCrue 06zxm3SfJNIw6+DPsBnku1oFvnC/65IrsA9qTGdi5BDQnWdeRkjS+BhJpqHYF1AqgF/F xCGgQeats3jq7oUFtHQ+VviqfDd6+jF1dYHgObSJq2SVUjG6icxtD4ZoFbI0EVGWlI1q YAYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=k/F7hVkSYzebNL/teXYlKtx0nCEUtMx2QKdqIwG8yj0=; fh=7xjKU1xkhmTazBlAQtMk+Chl7JSt/CUyagAgyiLWmTI=; b=tuAWjY2t2CCNy1on3tT2VjOP3MfcF33/IRu4cjziorYDUcE5pzmCFZK8LjafRqEjsP YJuSWjRI8v06Bqd+r+w/YtJDltqsfIBm2yldebxB3XlQTHfFO2mjtndw4BrCsFyj467g ilNSsZuo1kqHczeBzgW1UsoWuAFp/a4Hoy9PMSs+mhOl5i1x8NCwala6woVRa14ia0Fx DYdv1yDRe4gxzQiadCATTKKG/MmrGHMUNWmuoPF/BoChyzqxo8uSZ7KWRaKAcdBpDIj5 eyTqFmwlzZwE4XOJ7tqubEv8tUfwigLQK1y0B5psk3fwMwCH91bRwJU5MdzTXxhHj3Z2 r6MA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=O00riDg6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id s9-20020a17090a760900b00268414272d1si1947397pjk.156.2023.09.20.10.39.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 10:39:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=O00riDg6; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 7BD9A80FD3B8; Wed, 20 Sep 2023 02:46:42 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234192AbjITJq2 (ORCPT + 99 others); Wed, 20 Sep 2023 05:46:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57634 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234194AbjITJqX (ORCPT ); Wed, 20 Sep 2023 05:46:23 -0400 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 28795A3 for ; Wed, 20 Sep 2023 02:46:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1695203177; x=1726739177; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=vsLtXtSanSZeuBUFQNJW8XjWVTq6jvuJBVMdYVQoGRQ=; b=O00riDg64QlNZLLzhTlGn0YK6Glcv/C76lMmU1hdStiddwSI2DFOLYeX QthowD6brulNdXUBKs/U/eB+SD/hdHPJGnqm/QnGaTxD+T+djqSsduOTA lMd6YLgRWBAzEGtPesOfhKEBXI3syENfYkgMsXBffRGnZlKCyQsN6q9Ve Mc8sCFE3u0cQBkJ1en6idhfLyOVVOHHNvsBkSSmyGh4p/Cm6GC48mVfrI 2z2CoMDeh6iTfNcIQz1QO0HVP0+8COvwAZrZPHlKhPx/Xw7mxs9GhqaYv d6bC74/hIV7av+uj3Kn6WVO7vP2XORIQzqy3aQAGw1g9C2UUz5zaSm5W6 Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10838"; a="370491727" X-IronPort-AV: E=Sophos;i="6.02,161,1688454000"; d="scan'208";a="370491727" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Sep 2023 02:46:16 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10838"; a="861911782" X-IronPort-AV: E=Sophos;i="6.02,161,1688454000"; d="scan'208";a="861911782" Received: from sannilnx-dsk.jer.intel.com ([10.12.231.107]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Sep 2023 02:46:14 -0700 From: Alexander Usyskin To: Greg Kroah-Hartman , Lucas De Marchi , Daniele Ceraolo Spurio , Rodrigo Vivi Cc: Tomas Winkler , Alexander Usyskin , Vitaly Lubart , intel-xe@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH v4 2/4] drm/xe/gsc: add has_heci_gscfi indication to device Date: Wed, 20 Sep 2023 12:41:49 +0300 Message-Id: <20230920094151.1593505-3-alexander.usyskin@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230920094151.1593505-1-alexander.usyskin@intel.com> References: <20230920094151.1593505-1-alexander.usyskin@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Wed, 20 Sep 2023 02:46:43 -0700 (PDT) From: Vitaly Lubart Mark support of MEI-GSC interaction per device. Add has_heci_gscfi indication to xe_device and xe_pci structures. Mark DG1 and DG2 devices as supported. Reviewed-by: Rodrigo Vivi Signed-off-by: Vitaly Lubart Signed-off-by: Alexander Usyskin --- drivers/gpu/drm/xe/xe_device_types.h | 3 +++ drivers/gpu/drm/xe/xe_pci.c | 9 +++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/xe/xe_device_types.h b/drivers/gpu/drm/xe/xe_device_types.h index a82f28c6a3a0..696416afa7d1 100644 --- a/drivers/gpu/drm/xe/xe_device_types.h +++ b/drivers/gpu/drm/xe/xe_device_types.h @@ -33,6 +33,7 @@ struct xe_ggtt; #define GRAPHICS_VERx100(xe) ((xe)->info.graphics_verx100) #define MEDIA_VERx100(xe) ((xe)->info.media_verx100) #define IS_DGFX(xe) ((xe)->info.is_dgfx) +#define HAS_HECI_GSCFI(xe) ((xe)->info.has_heci_gscfi) #define XE_VRAM_FLAGS_NEED64K BIT(0) @@ -238,6 +239,8 @@ struct xe_device { u8 has_link_copy_engine:1; /** @enable_display: display enabled */ u8 enable_display:1; + /** @has_heci_gscfi: device has heci gscfi */ + u8 has_heci_gscfi:1; #if IS_ENABLED(CONFIG_DRM_XE_DISPLAY) const struct intel_display_device_info *display; diff --git a/drivers/gpu/drm/xe/xe_pci.c b/drivers/gpu/drm/xe/xe_pci.c index dc233a1226bd..145eaa430d74 100644 --- a/drivers/gpu/drm/xe/xe_pci.c +++ b/drivers/gpu/drm/xe/xe_pci.c @@ -57,6 +57,7 @@ struct xe_device_desc { u8 require_force_probe:1; u8 is_dgfx:1; u8 has_display:1; + u8 has_heci_gscfi:1; u8 has_llc:1; }; @@ -265,6 +266,7 @@ static const struct xe_device_desc dg1_desc = { PLATFORM(XE_DG1), .has_display = true, .require_force_probe = true, + .has_heci_gscfi = 1, }; static const u16 dg2_g10_ids[] = { XE_DG2_G10_IDS(NOP), XE_ATS_M150_IDS(NOP), 0 }; @@ -274,6 +276,7 @@ static const u16 dg2_g12_ids[] = { XE_DG2_G12_IDS(NOP), 0 }; #define DG2_FEATURES \ DGFX_FEATURES, \ PLATFORM(XE_DG2), \ + .has_heci_gscfi = 1, \ .subplatforms = (const struct xe_subplatform_desc[]) { \ { XE_SUBPLATFORM_DG2_G10, "G10", dg2_g10_ids }, \ { XE_SUBPLATFORM_DG2_G11, "G11", dg2_g11_ids }, \ @@ -562,6 +565,7 @@ static int xe_info_init(struct xe_device *xe, return -ENODEV; xe->info.is_dgfx = desc->is_dgfx; + xe->info.has_heci_gscfi = desc->has_heci_gscfi; xe->info.graphics_name = graphics_desc->name; xe->info.media_name = media_desc ? media_desc->name : "none"; xe->info.has_llc = desc->has_llc; @@ -703,7 +707,7 @@ static int xe_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) xe_display_info_init(xe); - drm_dbg(&xe->drm, "%s %s %04x:%04x dgfx:%d gfx:%s (%d.%02d) media:%s (%d.%02d) display:%s dma_m_s:%d tc:%d", + drm_dbg(&xe->drm, "%s %s %04x:%04x dgfx:%d gfx:%s (%d.%02d) media:%s (%d.%02d) display:%s dma_m_s:%d tc:%d gscfi:%d", desc->platform_name, subplatform_desc ? subplatform_desc->name : "", xe->info.devid, xe->info.revid, @@ -715,7 +719,8 @@ static int xe_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) xe->info.media_verx100 / 100, xe->info.media_verx100 % 100, str_yes_no(xe->info.enable_display), - xe->info.dma_mask_size, xe->info.tile_count); + xe->info.dma_mask_size, xe->info.tile_count, + xe->info.has_heci_gscfi); drm_dbg(&xe->drm, "Stepping = (G:%s, M:%s, D:%s, B:%s)\n", xe_step_name(xe->info.step.graphics), -- 2.34.1