/** * struct pmc_reg_map - Structure used to define parameter unique to a PCH family * @pfear_sts: Maps name of IP block to PPFEAR* bit * @mphy_sts: Maps name of MPHY lane to MPHY status lane status bit * @pll_sts: Maps name of PLL to corresponding bit status * @slps0_dbg_maps: Array of SLP_S0_DBG* registers containing debug info * @ltr_show_sts: Maps PCH IP Names to their MMIO register offsets * @s0ix_blocker_maps: Maps name of IP block to S0ix blocker counter * @slp_s0_offset: PWRMBASE offset to read SLP_S0 residency * @ltr_ignore_offset: PWRMBASE offset to read/write LTR ignore bit * @regmap_length: Length of memory to map from PWRMBASE address to access * @ppfear0_offset: PWRMBASE offset to read PPFEAR* * @ppfear_buckets: Number of 8 bits blocks to read all IP blocks from * PPFEAR * @pm_cfg_offset: PWRMBASE offset to PM_CFG register * @pm_read_disable_bit: Bit index to read PMC_READ_DISABLE * @slps0_dbg_offset: PWRMBASE offset to SLP_S0_DEBUG_REG* * @s0ix_blocker_offset PWRMBASE offset to S0ix blocker counter * * Each PCH has unique set of register offsets and bit indexes. This structure * captures them to have a common implementation.
*/ struct pmc_reg_map { conststruct pmc_bit_map **pfear_sts; conststruct pmc_bit_map *mphy_sts; conststruct pmc_bit_map *pll_sts; conststruct pmc_bit_map **slps0_dbg_maps; conststruct pmc_bit_map *ltr_show_sts; conststruct pmc_bit_map *msr_sts; conststruct pmc_bit_map **lpm_sts; conststruct pmc_bit_map **s0ix_blocker_maps; const u32 slp_s0_offset; constint slp_s0_res_counter_step; const u32 ltr_ignore_offset; constint regmap_length; const u32 ppfear0_offset; constint ppfear_buckets; const u32 pm_cfg_offset; constint pm_read_disable_bit; const u32 slps0_dbg_offset; const u32 ltr_ignore_max; const u32 pm_vric1_offset; const u32 s0ix_blocker_offset; /* Low Power Mode registers */ constint lpm_num_maps; constint lpm_num_modes; constint lpm_res_counter_step_x2; const u32 lpm_sts_latch_en_offset; const u32 lpm_en_offset; const u32 lpm_priority_offset; const u32 lpm_residency_offset; const u32 lpm_status_offset; const u32 lpm_live_status_offset; const u32 etr3_offset; const u8 *lpm_reg_index; const u32 pson_residency_offset; const u32 pson_residency_counter_step;
};
/** * struct pmc_info - Structure to keep pmc info * @devid: device id of the pmc device * @map: pointer to a pmc_reg_map struct that contains platform * specific attributes
*/ struct pmc_info {
u32 guid;
u16 devid; conststruct pmc_reg_map *map;
};
/** * struct pmc - pmc private info structure * @base_addr: contains pmc base address * @regbase: pointer to io-remapped memory location * @map: pointer to pmc_reg_map struct that contains platform * specific attributes * @lpm_req_regs: List of substate requirements * @ltr_ign: Holds LTR ignore data while suspended * * pmc contains info about one power management controller device.
*/ struct pmc {
u64 base_addr; void __iomem *regbase; conststruct pmc_reg_map *map;
u32 *lpm_req_regs;
u32 ltr_ign;
};
/** * struct pmc_dev - pmc device structure * @devs: pointer to an array of pmc pointers * @pdev: pointer to platform_device struct * @crystal_freq: crystal frequency from cpuid * @dbgfs_dir: path to debugfs interface * @pmc_xram_read_bit: flag to indicate whether PMC XRAM shadow registers * used to read MPHY PG and PLL status are available * @mutex_lock: mutex to complete one transcation * @pkgc_res_cnt: Array of PKGC residency counters * @num_of_pkgc: Number of PKGC * @s0ix_counter: S0ix residency (step adjusted) * @num_lpm_modes: Count of enabled modes * @lpm_en_modes: Array of enabled modes from lowest to highest priority * @suspend: Function to perform platform specific suspend * @resume: Function to perform platform specific resume * * pmc_dev contains info about power management controller device.
*/ struct pmc_dev { struct pmc *pmcs[MAX_NUM_PMC]; struct dentry *dbgfs_dir; struct platform_device *pdev; unsignedint crystal_freq; int pmc_xram_read_bit; struct mutex lock; /* generic mutex lock for PMC Core */
u64 s0ix_counter; int num_lpm_modes; int lpm_en_modes[LPM_MAX_NUM_MODES]; void (*suspend)(struct pmc_dev *pmcdev); int (*resume)(struct pmc_dev *pmcdev);
/** * struct pmc_dev_info - Structure to keep PMC device info * @pci_func: Function number of the primary PMC * @dmu_guid: Die Management Unit GUID * @regmap_list: Pointer to a list of pmc_info structure that could be * available for the platform. When set, this field implies * SSRAM support. * @map: Pointer to a pmc_reg_map struct that contains platform * specific attributes of the primary PMC * @suspend: Function to perform platform specific suspend * @resume: Function to perform platform specific resume * @init: Function to perform platform specific init action
*/ struct pmc_dev_info {
u8 pci_func;
u32 dmu_guid; struct pmc_info *regmap_list; conststruct pmc_reg_map *map; void (*suspend)(struct pmc_dev *pmcdev); int (*resume)(struct pmc_dev *pmcdev); int (*init)(struct pmc_dev *pmcdev, struct pmc_dev_info *pmc_dev_info);
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.