From patchwork Wed May 24 23:03:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vinod Govindapillai X-Patchwork-Id: 13254604 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 6E689C77B7C for ; Wed, 24 May 2023 23:04:04 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 17AAA10E69A; Wed, 24 May 2023 23:04:04 +0000 (UTC) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1B3E810E69A for ; Wed, 24 May 2023 23:04:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1684969442; x=1716505442; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=AcIyqkHVz4zokfE5vNssx5hY+o1qM+tx15Eb2iD3vbE=; b=aTCJwFnHePwEXBdu/FlAQSGA6XzEE0jYRF3gS9qCJ3tk8Z8O6gMJ5TgY +VevP8QBcLkehsph4DIA/Flmv9vE9lJ1m65hho0fpFKoo9Ez6ugFlFvU6 w7lQJWZ5MtE3PeAMnfvIeujPjxL7oBuEMegBvH5qtl1d59Hyf+W+GL7tt +L9C84uLGlToYIPt6KoMuhDjPn/S5huuxJ146nu9CVj6Q4qK/wfUOMwl1 nWNfLPbpvXRkzeEHz+cGerVl509f3CAfrh9ttJiAJhnsSW0WXO9ZQtNwJ DYt8jaZl1FaFcER7Wpq1Q5n+yhUy5/RPNO1NT+xJVIye4kCdmsFVHapTv w==; X-IronPort-AV: E=McAfee;i="6600,9927,10720"; a="338289486" X-IronPort-AV: E=Sophos;i="6.00,190,1681196400"; d="scan'208";a="338289486" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 May 2023 16:04:01 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10720"; a="951218349" X-IronPort-AV: E=Sophos;i="6.00,190,1681196400"; d="scan'208";a="951218349" Received: from peteratz-mobl.ger.corp.intel.com (HELO vgovind2-mobl3.intel.com) ([10.252.55.65]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 May 2023 16:03:58 -0700 From: Vinod Govindapillai To: intel-gfx@lists.freedesktop.org Date: Thu, 25 May 2023 02:03:35 +0300 Message-Id: <20230524230342.411273-1-vinod.govindapillai@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Subject: [Intel-gfx] [PATCH v8 0/7] mtl: add support for pmdemand 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: ville.syrjala@intel.com Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" pmdemand support patches for MTL SAGV configuration support for MTL v2: added one missing patch in the previous version v3: chekcpatch warning fixes update index handling for the icl/tgl QGV point handling program pmdemand code simplified v4: update to debufs and pipe values pmdemand regiters removed the macro usage in update_pmdemand_values V5: Addressing comments from Gustavo and Jani And some other fixes for issues from CI v6: Addressing some comments from Gustavo Updates to pmdemand state struct, active phys calculations Got rid of suppress warning patch from v5 v7: Rebased and updates to max ddiclk and active phys calculations v8: updates to active phys calcuations Mika Kahola (1): drm/i915/mtl: Add support for PM DEMAND Vinod Govindapillai (6): drm/i915: fix the derating percentage for MTL drm/i915: update the QGV point frequency calculations drm/i915: store the peak bw per QGV point drm/i915: extract intel_bw_check_qgv_points() drm/i915: modify max_bw to return index to intel_bw_info drm/i915/mtl: find the best QGV point for the SAGV configuration drivers/gpu/drm/i915/Makefile | 1 + drivers/gpu/drm/i915/display/intel_bw.c | 353 +++++++---- drivers/gpu/drm/i915/display/intel_bw.h | 6 + drivers/gpu/drm/i915/display/intel_display.c | 14 + .../gpu/drm/i915/display/intel_display_core.h | 11 + .../drm/i915/display/intel_display_driver.c | 7 + .../gpu/drm/i915/display/intel_display_irq.c | 23 +- .../drm/i915/display/intel_display_power.c | 8 + drivers/gpu/drm/i915/display/intel_pmdemand.c | 560 ++++++++++++++++++ drivers/gpu/drm/i915/display/intel_pmdemand.h | 24 + drivers/gpu/drm/i915/i915_reg.h | 36 +- 11 files changed, 922 insertions(+), 121 deletions(-) create mode 100644 drivers/gpu/drm/i915/display/intel_pmdemand.c create mode 100644 drivers/gpu/drm/i915/display/intel_pmdemand.h