mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-28 11:18:45 +07:00
0c67f6b297
- Add support for interconnect bandwidth to the OPP core (Georgi Djakov, Saravana Kannan, Sibi Sankar, Viresh Kumar). - Add support for regulator enable/disable to the OPP core (Kamil Konieczny). - Add boost support to the CPPC cpufreq driver (Xiongfeng Wang). - Make the tegra186 cpufreq driver set the CPUFREQ_NEED_INITIAL_FREQ_CHECK flag (Mian Yousaf Kaukab). - Prevent the ACPI power management from using power resources with devices where the list of power resources for power state D0 (full power) is missing (Rafael Wysocki). - Annotate a hibernation-related function with __init (Christophe JAILLET). -----BEGIN PGP SIGNATURE----- iQJGBAABCAAwFiEE4fcc61cGeeHD/fCwgsRv/nhiVHEFAl7g/zESHHJqd0Byand5 c29ja2kubmV0AAoJEILEb/54YlRxZzgP+wTBW/WVLVkrlk2tQhcbbj+y9TNNOfU1 FZ9C56bR+5VJhrrxTxVHeQP7PDCNxqVM57M8Bcnl3I0LFi+OHNAqkN/xW323N7ZA 8OGkFgeqSxgG21691rTEwVnwwhdvQsNw47Fqjbu10PiNFYm6W8YNI5JMQRxfTVHb H8Nt7xcJ5i7wnMRnAyrotnTUYmS3nZ7IwpHFEoM2SwWCqlYr0h9rDqKz3MvbiE59 m0G+4tFUv8egyshzwMD78PeFG+7iZP9s4uovsKujj4UGskmAVn9BGP0vI5AJiS4b 9KdrDNdX5NAEBFn5eDVzZSMzYhRI3pebd306oWUS+A4/rDA+BtC4ECkaWKE6IlX6 pmJuY5w8mZU0geH+W2xJQp6t/f60XJymEYKu88opm69ujgJL8X2PglWNq8tal6iX BfaPNMla+0mNt9L+GzIb6v5f/nbNBQ8qe6vXlQndqcxxerIBPktLTP+j18FzN9N4 4XOyFJYoauvfMidK8+fjGlSGi54GnlseopNcVTD6IRjRkXhYYJE62oTfgoFe1DIs 7pFyEtnTgA0Ma9h1CMs2/UwaL1Xule4HMZzdeAnkelAAivdJI181XU0k3Y6vuNwA 4IXkpMph8utvWX/Dp+OH0a5YGvpEAuihwe8a2Ld/VtOGVINh4hVQucU/yrGN6EIJ Od7S+Zua3bR6 =p5eu -----END PGP SIGNATURE----- Merge tag 'pm-5.8-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Pull more power management updates from Rafael Wysocki: "These are operating performance points (OPP) framework updates mostly, including support for interconnect bandwidth in the OPP core, plus a few cpufreq changes, including boost support in the CPPC cpufreq driver, an ACPI device power management fix and a hibernation code cleanup. Specifics: - Add support for interconnect bandwidth to the OPP core (Georgi Djakov, Saravana Kannan, Sibi Sankar, Viresh Kumar). - Add support for regulator enable/disable to the OPP core (Kamil Konieczny). - Add boost support to the CPPC cpufreq driver (Xiongfeng Wang). - Make the tegra186 cpufreq driver set the CPUFREQ_NEED_INITIAL_FREQ_CHECK flag (Mian Yousaf Kaukab). - Prevent the ACPI power management from using power resources with devices where the list of power resources for power state D0 (full power) is missing (Rafael Wysocki). - Annotate a hibernation-related function with __init (Christophe JAILLET)" * tag 'pm-5.8-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: ACPI: PM: Avoid using power resources if there are none for D0 cpufreq: CPPC: add SW BOOST support cpufreq: change '.set_boost' to act on one policy PM: hibernate: Add __init annotation to swsusp_header_init() opp: Don't parse icc paths unnecessarily opp: Remove bandwidth votes when target_freq is zero opp: core: add regulators enable and disable opp: Reorder the code for !target_freq case opp: Expose bandwidth information via debugfs cpufreq: dt: Add support for interconnect bandwidth scaling opp: Update the bandwidth on OPP frequency changes opp: Add sanity checks in _read_opp_key() opp: Add support for parsing interconnect bandwidth cpufreq: tegra186: add CPUFREQ_NEED_INITIAL_FREQ_CHECK flag OPP: Add helpers for reading the binding properties dt-bindings: opp: Introduce opp-peak-kBps and opp-avg-kBps bindings
96 lines
2.1 KiB
C
96 lines
2.1 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Copyright (c) 2018-2019, Linaro Ltd.
|
|
* Author: Georgi Djakov <georgi.djakov@linaro.org>
|
|
*/
|
|
|
|
#ifndef __LINUX_INTERCONNECT_H
|
|
#define __LINUX_INTERCONNECT_H
|
|
|
|
#include <linux/mutex.h>
|
|
#include <linux/types.h>
|
|
|
|
/* macros for converting to icc units */
|
|
#define Bps_to_icc(x) ((x) / 1000)
|
|
#define kBps_to_icc(x) (x)
|
|
#define MBps_to_icc(x) ((x) * 1000)
|
|
#define GBps_to_icc(x) ((x) * 1000 * 1000)
|
|
#define bps_to_icc(x) (1)
|
|
#define kbps_to_icc(x) ((x) / 8 + ((x) % 8 ? 1 : 0))
|
|
#define Mbps_to_icc(x) ((x) * 1000 / 8)
|
|
#define Gbps_to_icc(x) ((x) * 1000 * 1000 / 8)
|
|
|
|
struct icc_path;
|
|
struct device;
|
|
|
|
#if IS_ENABLED(CONFIG_INTERCONNECT)
|
|
|
|
struct icc_path *icc_get(struct device *dev, const int src_id,
|
|
const int dst_id);
|
|
struct icc_path *of_icc_get(struct device *dev, const char *name);
|
|
struct icc_path *devm_of_icc_get(struct device *dev, const char *name);
|
|
struct icc_path *of_icc_get_by_index(struct device *dev, int idx);
|
|
void icc_put(struct icc_path *path);
|
|
int icc_enable(struct icc_path *path);
|
|
int icc_disable(struct icc_path *path);
|
|
int icc_set_bw(struct icc_path *path, u32 avg_bw, u32 peak_bw);
|
|
void icc_set_tag(struct icc_path *path, u32 tag);
|
|
const char *icc_get_name(struct icc_path *path);
|
|
|
|
#else
|
|
|
|
static inline struct icc_path *icc_get(struct device *dev, const int src_id,
|
|
const int dst_id)
|
|
{
|
|
return NULL;
|
|
}
|
|
|
|
static inline struct icc_path *of_icc_get(struct device *dev,
|
|
const char *name)
|
|
{
|
|
return NULL;
|
|
}
|
|
|
|
static inline struct icc_path *devm_of_icc_get(struct device *dev,
|
|
const char *name)
|
|
{
|
|
return NULL;
|
|
}
|
|
|
|
static inline struct icc_path *of_icc_get_by_index(struct device *dev, int idx)
|
|
{
|
|
return NULL;
|
|
}
|
|
|
|
static inline void icc_put(struct icc_path *path)
|
|
{
|
|
}
|
|
|
|
static inline int icc_enable(struct icc_path *path)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline int icc_disable(struct icc_path *path)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline int icc_set_bw(struct icc_path *path, u32 avg_bw, u32 peak_bw)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline void icc_set_tag(struct icc_path *path, u32 tag)
|
|
{
|
|
}
|
|
|
|
static inline const char *icc_get_name(struct icc_path *path)
|
|
{
|
|
return NULL;
|
|
}
|
|
|
|
#endif /* CONFIG_INTERCONNECT */
|
|
|
|
#endif /* __LINUX_INTERCONNECT_H */
|