public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Cc: Hans de Goede <hdegoede@redhat.com>,
	markgross@kernel.org,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	platform-driver-x86@vger.kernel.org,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 4/6] platform/x86/intel/tpmi: Move TPMI ID definitions
Date: Thu, 30 Nov 2023 14:01:00 +0200 (EET)	[thread overview]
Message-ID: <35f3ae1d-d714-69c2-6447-eba312c712c1@linux.intel.com> (raw)
In-Reply-To: <20231128185605.3027653-5-srinivas.pandruvada@linux.intel.com>

[-- Attachment #1: Type: text/plain, Size: 2471 bytes --]

On Tue, 28 Nov 2023, Srinivas Pandruvada wrote:

> Move TPMI ID definitions to common include file. In this way other
> feature drivers don't have to redefine.
> 
> Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> ---
>  drivers/platform/x86/intel/tpmi.c | 13 -------------
>  include/linux/intel_tpmi.h        | 13 +++++++++++++
>  2 files changed, 13 insertions(+), 13 deletions(-)
> 
> diff --git a/drivers/platform/x86/intel/tpmi.c b/drivers/platform/x86/intel/tpmi.c
> index 44773c210324..14575da91d2c 100644
> --- a/drivers/platform/x86/intel/tpmi.c
> +++ b/drivers/platform/x86/intel/tpmi.c
> @@ -176,19 +176,6 @@ struct tpmi_feature_state {
>  	u32 locked:1;
>  } __packed;
>  
> -/*
> - * List of supported TMPI IDs.
> - * Some TMPI IDs are not used by Linux, so the numbers are not consecutive.
> - */
> -enum intel_tpmi_id {
> -	TPMI_ID_RAPL = 0, /* Running Average Power Limit */
> -	TPMI_ID_PEM = 1, /* Power and Perf excursion Monitor */
> -	TPMI_ID_UNCORE = 2, /* Uncore Frequency Scaling */
> -	TPMI_ID_SST = 5, /* Speed Select Technology */
> -	TPMI_CONTROL_ID = 0x80, /* Special ID for getting feature status */
> -	TPMI_INFO_ID = 0x81, /* Special ID for PCI BDF and Package ID information */
> -};
> -
>  /*
>   * The size from hardware is in u32 units. This size is from a trusted hardware,
>   * but better to verify for pre silicon platforms. Set size to 0, when invalid.
> diff --git a/include/linux/intel_tpmi.h b/include/linux/intel_tpmi.h
> index a240e15ef77f..6c31768cdb83 100644
> --- a/include/linux/intel_tpmi.h
> +++ b/include/linux/intel_tpmi.h
> @@ -12,6 +12,19 @@
>  #define TPMI_MINOR_VERSION(val)	FIELD_GET(GENMASK(4, 0), val)
>  #define TPMI_MAJOR_VERSION(val)	FIELD_GET(GENMASK(7, 5), val)
>  
> +/*
> + * List of supported TMPI IDs.
> + * Some TMPI IDs are not used by Linux, so the numbers are not consecutive.
> + */
> +enum intel_tpmi_id {
> +	TPMI_ID_RAPL = 0, /* Running Average Power Limit */
> +	TPMI_ID_PEM = 1, /* Power and Perf excursion Monitor */
> +	TPMI_ID_UNCORE = 2, /* Uncore Frequency Scaling */
> +	TPMI_ID_SST = 5, /* Speed Select Technology */
> +	TPMI_CONTROL_ID = 0x80, /* Special ID for getting feature status */
> +	TPMI_INFO_ID = 0x81, /* Special ID for PCI BDF and Package ID information */
> +};

While at it, could you align the comments to start at the same column so 
it would slightly less messy to read.

Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

-- 
 i.

  reply	other threads:[~2023-11-30 12:01 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-28 18:55 [PATCH 0/6] TPMI update for new defines and permissions Srinivas Pandruvada
2023-11-28 18:56 ` [PATCH 1/6] platform/x86/intel/tpmi: Add additional TPMI header fields Srinivas Pandruvada
2023-11-30 12:33   ` Ilpo Järvinen
2023-11-30 14:10     ` srinivas pandruvada
2023-11-28 18:56 ` [PATCH 2/6] platform/x86/intel/tpmi: Don't create devices for disabled features Srinivas Pandruvada
2023-11-30 12:26   ` Ilpo Järvinen
2023-11-30 14:29     ` srinivas pandruvada
2023-11-30 14:33       ` Ilpo Järvinen
2023-11-30 14:38         ` Andy Shevchenko
2023-11-30 15:00           ` srinivas pandruvada
2023-11-30 21:15             ` srinivas pandruvada
2023-11-28 18:56 ` [PATCH 3/6] platform/x86/intel/tpmi: Modify external interface to get read/write state Srinivas Pandruvada
2023-11-30 12:08   ` Ilpo Järvinen
2023-11-28 18:56 ` [PATCH 4/6] platform/x86/intel/tpmi: Move TPMI ID definitions Srinivas Pandruvada
2023-11-30 12:01   ` Ilpo Järvinen [this message]
2023-11-28 18:56 ` [PATCH 5/6] platform/x86: ISST: Process read/write blocked feature status Srinivas Pandruvada
2023-11-30 12:20   ` Ilpo Järvinen
2023-11-30 14:30     ` srinivas pandruvada
2023-11-28 18:56 ` [PATCH 6/6] platform/x86/intel-uncore-freq: " Srinivas Pandruvada
2023-11-30 12:24   ` Ilpo Järvinen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=35f3ae1d-d714-69c2-6447-eba312c712c1@linux.intel.com \
    --to=ilpo.jarvinen@linux.intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=hdegoede@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=markgross@kernel.org \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=srinivas.pandruvada@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox