From patchwork Mon Apr 10 18:32:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Souza, Jose" X-Patchwork-Id: 13206598 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 2144FC77B71 for ; Mon, 10 Apr 2023 18:32:32 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BBB5610E226; Mon, 10 Apr 2023 18:32:29 +0000 (UTC) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1E20710E117; Mon, 10 Apr 2023 18:32:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1681151546; x=1712687546; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=jr21YHmGpKB6Of6v+UPnY1Z78p9e25JmF85u+zYeZxM=; b=elngIcuVq/wkyfMQKY0Cs8ueHtWyK/YCBVgTumydPy5c3G8UPFgdAcM6 8Pm4WbrIu/bmb2Nu1y49AaTclU7Vk1Ru0Sz7bU/yliEEYvaBlhUk9lqg2 ObfKR0ek928bEsJVp0Qp+eLdH8VelAjqtz8XdCCLQ0POC+VGjRBVhKCyd NvxedHzVdKdHNzlwZq+eegDu+eWCWlxKkHC57seQzXpl/H4oUfi3mBfLp 8NIOvVFqERt44TbjqgE9oTzNOf8TzXDsJL2U87Zy7NaQAGMIMz85nSbwc pK9f+glWAe4usu+YyFRe3vD4gUE5jFVkbjO/ErxiACQ7d+VcjJu81LenW A==; X-IronPort-AV: E=McAfee;i="6600,9927,10676"; a="408563409" X-IronPort-AV: E=Sophos;i="5.98,333,1673942400"; d="scan'208";a="408563409" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Apr 2023 11:32:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10676"; a="681800967" X-IronPort-AV: E=Sophos;i="5.98,333,1673942400"; d="scan'208";a="681800967" Received: from josouza-mobl2.fso.intel.com ([10.230.18.148]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Apr 2023 11:32:24 -0700 From: =?utf-8?q?Jos=C3=A9_Roberto_de_Souza?= To: intel-xe@lists.freedesktop.org Date: Mon, 10 Apr 2023 11:32:15 -0700 Message-Id: <20230410183219.191543-2-jose.souza@intel.com> X-Mailer: git-send-email 2.40.0 In-Reply-To: <20230410183219.191543-1-jose.souza@intel.com> References: <20230410183219.191543-1-jose.souza@intel.com> MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH v3 2/6] drm/i915: Only initialize dlk phy lock in display 12 and newer X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: intel-gfx@lists.freedesktop.org, Rodrigo Vivi Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" This spin lock will not be used in older display versions, so no need to initialize it. Cc: intel-gfx@lists.freedesktop.org Cc: intel-xe@lists.freedesktop.org Reviewed-by: Rodrigo Vivi Signed-off-by: José Roberto de Souza --- drivers/gpu/drm/i915/display/intel_dkl_phy.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_dkl_phy.c b/drivers/gpu/drm/i915/display/intel_dkl_phy.c index 5bce7b5b27bc7..1c5d410b74e5d 100644 --- a/drivers/gpu/drm/i915/display/intel_dkl_phy.c +++ b/drivers/gpu/drm/i915/display/intel_dkl_phy.c @@ -108,5 +108,6 @@ intel_dkl_phy_posting_read(struct drm_i915_private *i915, struct intel_dkl_phy_r void intel_dkl_phy_init(struct drm_i915_private *i915) { - spin_lock_init(&i915->display.dkl.phy_lock); + if (DISPLAY_VER(i915) >= 12) + spin_lock_init(&i915->display.dkl.phy_lock); }