From patchwork Wed Apr 5 07:14:28 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Riana Tauro X-Patchwork-Id: 13201227 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 0BA19C76188 for ; Wed, 5 Apr 2023 07:14:41 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7B6D610E84C; Wed, 5 Apr 2023 07:14:38 +0000 (UTC) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4397F10E30F for ; Wed, 5 Apr 2023 07:14:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1680678874; x=1712214874; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=H0W/50PTyMQDD4rS/NAMkNzkMYX8H0KCq3EsWsL7pGQ=; b=fgNu3t3BRv+GawY5VImQNT7RXgtlnBeSMNqyQoQQUf43KPh+wFnLRfsA ko3KtoA5S3lMAxWq5lCdVUiD1c4PCGBCanFlxL9rVLJA+wfZNOH9wWEFU bcl50UtMwOzYcfA93pw9RqxnmILvFDADv0ha/FV0Q1ZbI1JvfnnthaPFh tY/HI41Oj/jc3hMGXtUru1WYSTzVcHkOyiCRUesXMZl/pJDHHzXgW8ZBw QRhEW7awyyzfTS+wHrG63EYEoNht0Y37m48TtbnoRfgsI5+ri9ieVpgww c5ntzWtBEoPOgkPucx1H/ZoR7Gd7CJ4QCzNPSXjt5teBV+ABENvaAaSsf g==; X-IronPort-AV: E=McAfee;i="6600,9927,10670"; a="370211190" X-IronPort-AV: E=Sophos;i="5.98,319,1673942400"; d="scan'208";a="370211190" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Apr 2023 00:14:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10670"; a="636797363" X-IronPort-AV: E=Sophos;i="5.98,319,1673942400"; d="scan'208";a="636797363" Received: from rtauro-desk.iind.intel.com ([10.190.239.41]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Apr 2023 00:14:24 -0700 From: Riana Tauro To: intel-gfx@lists.freedesktop.org Date: Wed, 5 Apr 2023 12:44:28 +0530 Message-Id: <20230405071432.3582592-1-riana.tauro@intel.com> X-Mailer: git-send-email 2.40.0 MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH v10 0/4] Add hwmon support for dgfx selftests 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: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" Rename librapl library to libpower. Add hwmon support in libpower for dgfx. Use libpower in selftests. Rev2 : Update commit message Rev3 : Remove redundant code Rev4 : Add hwmon per-gt support Rev5 : No functional changes. Change author for last patch Rev6 : re-order libpower library patch add check for single gt in hwmon function Rev7 : Same as Rev 5 with a single gt check in hwmon function Rev8 : Skip power comparison in live_rc6_manual for discrete graphics Rev9 : Update commit message Rev10: No functional changes Fix a spelling Riana Tauro (3): drm/i915/selftests: Rename librapl library to libpower drm/i915/hwmon: Add helper function to obtain energy values drm/i915/selftests: skip comparison of power for discrete graphics Tilak Tangudu (1): drm/i915/selftests: Add hwmon support in libpower for dgfx drivers/gpu/drm/i915/Makefile | 2 +- drivers/gpu/drm/i915/gt/selftest_rc6.c | 22 ++++++++++----- drivers/gpu/drm/i915/gt/selftest_rps.c | 26 ++++++++--------- drivers/gpu/drm/i915/gt/selftest_slpc.c | 4 +-- drivers/gpu/drm/i915/i915_hwmon.c | 28 +++++++++++++++++++ drivers/gpu/drm/i915/i915_hwmon.h | 3 ++ drivers/gpu/drm/i915/selftests/libpower.c | 33 ++++++++++++++++++++++ drivers/gpu/drm/i915/selftests/libpower.h | 19 +++++++++++++ drivers/gpu/drm/i915/selftests/librapl.c | 34 ----------------------- drivers/gpu/drm/i915/selftests/librapl.h | 17 ------------ 10 files changed, 114 insertions(+), 74 deletions(-) create mode 100644 drivers/gpu/drm/i915/selftests/libpower.c create mode 100644 drivers/gpu/drm/i915/selftests/libpower.h delete mode 100644 drivers/gpu/drm/i915/selftests/librapl.c delete mode 100644 drivers/gpu/drm/i915/selftests/librapl.h