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 X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_2 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 545B8C73C41 for ; Tue, 9 Jul 2019 13:41:41 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 297DB20861 for ; Tue, 9 Jul 2019 13:41:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726501AbfGINlk (ORCPT ); Tue, 9 Jul 2019 09:41:40 -0400 Received: from mga18.intel.com ([134.134.136.126]:41912 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726345AbfGINlk (ORCPT ); Tue, 9 Jul 2019 09:41:40 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Jul 2019 06:41:39 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.63,470,1557212400"; d="scan'208";a="188829531" Received: from yzhon11-mobl1.ccr.corp.intel.com ([10.249.168.54]) by fmsmga004.fm.intel.com with ESMTP; 09 Jul 2019 06:41:38 -0700 Message-ID: <1562679696.2440.9.camel@intel.com> Subject: Re: [PATCH V2 00/13] intel_rapl: RAPL abstraction and MMIO RAPL support From: Zhang Rui To: "Rafael J. Wysocki" Cc: "Pandruvada, Srinivas" , "linux-pm@vger.kernel.org" , "rjw@rjwysocki.net" Date: Tue, 09 Jul 2019 21:41:36 +0800 In-Reply-To: References: <1562258085-3165-1-git-send-email-rui.zhang@intel.com> <97215b43ce11766f83847531b05def8d94f645f0.camel@intel.com> <1562568815.2810.18.camel@intel.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.18.5.2-0ubuntu3.2 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org On 一, 2019-07-08 at 10:58 +0200, Rafael J. Wysocki wrote: > On Mon, Jul 8, 2019 at 8:53 AM Zhang Rui wrote: > > > > > > On 六, 2019-07-06 at 10:19 +0200, Rafael J. Wysocki wrote: > > > > > > On Fri, Jul 5, 2019 at 4:59 PM Pandruvada, Srinivas > > > wrote: > > > > > > > > > > > > > > > > On Fri, 2019-07-05 at 10:57 +0200, Rafael J. Wysocki wrote: > > > > > > > > > > > > > > > On Thu, Jul 4, 2019 at 6:34 PM Zhang Rui > > > > > > > > > > wrote: > > > > > > > > > > > > > > > > > > > > > > > > Besideis MSR interface, RAPL can also be controlled via the > > > > > > MMIO > > > > > > interface, > > > > > > by accessing the MCHBar registers exposed by the processor > > > > > > thermal > > > > > > device. > > > > > > > > > > > > Currently, we only have RAPL MSR interface in Linux kernel, > > > > > > this > > > > > > brings > > > > > > problems on some platforms that BIOS performs a low power > > > > > > limits > > > > > > via the > > > > > > MMIO interface by default. This results in poor system > > > > > > performance, > > > > > > and there is no way for us to change the MMIO MSR setting > > > > > > in > > > > > > Linux. > > > > > > > > > > > > To fix this, RAPL MMIO interface support is introduced in > > > > > > this > > > > > > patch set. > > > > > > > > > > > > Patch 1/13 to patch 11/13 abstract the RAPL code, and move > > > > > > all > > > > > > the > > > > > > shared > > > > > > code into a separate file, intel_rapl_common.c, so that it > > > > > > can > > > > > > be > > > > > > used > > > > > > by both MSR and MMIO interfaces. > > > > > > Patch 12/13 introduced RAPL support via MMIO registers, > > > > > > exposed > > > > > > by > > > > > > the > > > > > > processor thermal devices. > > > > > > Patch 13/13 fixes a module autoloading issue found later. > > > > > > > > > > > > The patch series has been tested on Dell XPS 9360, a SKL > > > > > > platform. > > > > > > > > > > > > Note that this patch series are based on the -tip tree, > > > > > > which > > > > > > contains the > > > > > > latest RAPL changes for multi-die support. > > > > > > > > > > > > Changes in V2: > > > > > >    - add kerneldoc for struct rapl_if_priv. > > > > > >    - use intel_rapl_msr.c for RAPL MSR I/F driver, instead > > > > > > of > > > > > > intel_rapl.c. > > > > > >    - changelog and coding style update. > > > > > What tree is the series against? > > > > > > > > > > It doesn't apply either on top of my powercap branch or on > > > > > top of > > > > > 5.2-rc7 for me. > > > > This needs linux tip tree. There are some package/die changes > > > > in > > > > tip > > > > tree, which this patch depends on. > > > OK, so the changes in -tip need to go in first. > > > > > exactly. > > BTW, this patch set also conflicts with the RAPL support patches > > for > > icelake platforms. > Do you mean commits > > cc3ae777098b..88679b2587a0 > > in linux-next? > yes. > > > > Thus IMO, having a separate rapl branch, and apply > > the icl rapl patches on top of this patch set will be much easier. > OK, I'll do that if that's preferred. thanks. I think you can apply the ICL RAPL patches by replacing intel_rapl.c with intel_rapl_common.c in the patch files. Or I can resend the ICL RAPL patches rebased on the this patch series. thanks, rui