]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/blame - include/linux/platform_data/voltage-omap.h
UBUNTU: Ubuntu-5.11.0-22.23
[mirror_ubuntu-hirsute-kernel.git] / include / linux / platform_data / voltage-omap.h
CommitLineData
d2912cb1 1/* SPDX-License-Identifier: GPL-2.0-only */
42b43945
TK
2/*
3 * OMAP Voltage Management Routines
4 *
5 * Copyright (C) 2011, Texas Instruments, Inc.
42b43945
TK
6 */
7
8#ifndef __ARCH_ARM_OMAP_VOLTAGE_H
9#define __ARCH_ARM_OMAP_VOLTAGE_H
10
fa60be6e
K
11/**
12 * struct omap_volt_data - Omap voltage specific data.
13 * @voltage_nominal: The possible voltage value in uV
14 * @sr_efuse_offs: The offset of the efuse register(from system
15 * control module base address) from where to read
16 * the n-target value for the smartreflex module.
17 * @sr_errminlimit: Error min limit value for smartreflex. This value
18 * differs at differnet opp and thus is linked
19 * with voltage.
20 * @vp_errorgain: Error gain value for the voltage processor. This
21 * field also differs according to the voltage/opp.
22 */
23struct omap_volt_data {
24 u32 volt_nominal;
25 u32 sr_efuse_offs;
26 u8 sr_errminlimit;
27 u8 vp_errgain;
28};
42b43945
TK
29struct voltagedomain;
30
31struct voltagedomain *voltdm_lookup(const char *name);
32int voltdm_scale(struct voltagedomain *voltdm, unsigned long target_volt);
33unsigned long voltdm_get_voltage(struct voltagedomain *voltdm);
fa60be6e
K
34struct omap_volt_data *omap_voltage_get_voltdata(struct voltagedomain *voltdm,
35 unsigned long volt);
42b43945 36#endif