~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/linux/intel_tpmi.h

Version: ~ [ linux-6.11.5 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.58 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.114 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.169 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.228 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.284 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.322 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /* SPDX-License-Identifier: GPL-2.0-only */
  2 /*
  3  * intel_tpmi.h: Intel TPMI core external interface
  4  */
  5 
  6 #ifndef _INTEL_TPMI_H_
  7 #define _INTEL_TPMI_H_
  8 
  9 #include <linux/bitfield.h>
 10 
 11 #define TPMI_VERSION_INVALID    0xff
 12 #define TPMI_MINOR_VERSION(val) FIELD_GET(GENMASK(4, 0), val)
 13 #define TPMI_MAJOR_VERSION(val) FIELD_GET(GENMASK(7, 5), val)
 14 
 15 /*
 16  * List of supported TMPI IDs.
 17  * Some TMPI IDs are not used by Linux, so the numbers are not consecutive.
 18  */
 19 enum intel_tpmi_id {
 20         TPMI_ID_RAPL = 0,       /* Running Average Power Limit */
 21         TPMI_ID_PEM = 1,        /* Power and Perf excursion Monitor */
 22         TPMI_ID_UNCORE = 2,     /* Uncore Frequency Scaling */
 23         TPMI_ID_SST = 5,        /* Speed Select Technology */
 24         TPMI_ID_PLR = 0xc,      /* Performance Limit Reasons */
 25         TPMI_CONTROL_ID = 0x80, /* Special ID for getting feature status */
 26         TPMI_INFO_ID = 0x81,    /* Special ID for PCI BDF and Package ID information */
 27 };
 28 
 29 /**
 30  * struct intel_tpmi_plat_info - Platform information for a TPMI device instance
 31  * @cdie_mask:       Mask of all compute dies in the partition
 32  * @package_id:      CPU Package id
 33  * @partition:       Package partition id when multiple VSEC PCI devices per package
 34  * @segment:         PCI segment ID
 35  * @bus_number:      PCI bus number
 36  * @device_number:   PCI device number
 37  * @function_number: PCI function number
 38  *
 39  * Structure to store platform data for a TPMI device instance. This
 40  * struct is used to return data via tpmi_get_platform_data().
 41  */
 42 struct intel_tpmi_plat_info {
 43         u16 cdie_mask;
 44         u8 package_id;
 45         u8 partition;
 46         u8 segment;
 47         u8 bus_number;
 48         u8 device_number;
 49         u8 function_number;
 50 };
 51 
 52 struct intel_tpmi_plat_info *tpmi_get_platform_data(struct auxiliary_device *auxdev);
 53 struct resource *tpmi_get_resource_at_index(struct auxiliary_device *auxdev, int index);
 54 int tpmi_get_resource_count(struct auxiliary_device *auxdev);
 55 int tpmi_get_feature_status(struct auxiliary_device *auxdev, int feature_id, bool *read_blocked,
 56                             bool *write_blocked);
 57 struct dentry *tpmi_get_debugfs_dir(struct auxiliary_device *auxdev);
 58 #endif
 59 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php