regulator: Add snapshot of qpnp-labibb regulator driver

Add snapshot of QPNP LABIBB regulator driver that supports controlling
the display bias voltage rails on QTI PMICs that powers up LCD or
AMOLED panels.

This snapshot is taken as of msm-4.14
commit 9bb584ae3a9d ("msm/sde/rotator: Add rev checks for sdmmagpie").

This change also splits some functions to fix cyclomatic complexity
warnings.

Change-Id: Iad4f4721f07ed796f71f8975878f8dcbbb216bc1
Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
This commit is contained in:
Subbaraman Narayanamurthy 2018-10-31 19:11:25 -07:00
parent b78e7a0918
commit ee1e5e1083
4 changed files with 4523 additions and 0 deletions

View file

@ -724,6 +724,17 @@ config REGULATOR_QCOM_SPMI
Qualcomm SPMI PMICs as a module. The module will be named
"qcom_spmi-regulator".
config REGULATOR_QPNP_LABIBB
tristate "Qualcomm Technologies, Inc. QPNP LAB/IBB regulator support"
depends on SPMI
help
This driver supports voltage regulators in Qualcomm Technologies, Inc.
PMIC chips which comply with QPNP LAB/IBB regulators. QPNP LAB and IBB
are SPMI based PMIC implementations. LAB regulator can be used as a
regular positive boost regulator. IBB can be used as a regular
negative boost regulator. LAB/IBB regulators can also be used
together for LCD or AMOLED on QTI PMICs like PMI8998.
config REGULATOR_QPNP_LCDB
tristate "Qualcomm Technologies, Inc. QPNP LCDB support"
depends on SPMI

View file

@ -82,6 +82,7 @@ obj-$(CONFIG_REGULATOR_QCOM_RPM) += qcom_rpm-regulator.o
obj-$(CONFIG_REGULATOR_QCOM_RPMH) += qcom-rpmh-regulator.o
obj-$(CONFIG_REGULATOR_QCOM_SMD_RPM) += qcom_smd-regulator.o
obj-$(CONFIG_REGULATOR_QCOM_SPMI) += qcom_spmi-regulator.o
obj-$(CONFIG_REGULATOR_QPNP_LABIBB) += qpnp-labibb-regulator.o
obj-$(CONFIG_REGULATOR_QPNP_LCDB) += qpnp-lcdb-regulator.o
obj-$(CONFIG_REGULATOR_PALMAS) += palmas-regulator.o
obj-$(CONFIG_REGULATOR_PFUZE100) += pfuze100-regulator.o

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,28 @@
/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (c) 2017 The Linux Foundation. All rights reserved.
*/
#ifndef _QPNP_LABIBB_REGULATOR_H
#define _QPNP_LABIBB_REGULATOR_H
enum labibb_notify_event {
LAB_VREG_OK = 1,
LAB_VREG_NOT_OK,
};
#ifdef CONFIG_REGULATOR_QPNP_LABIBB
int qpnp_labibb_notifier_register(struct notifier_block *nb);
int qpnp_labibb_notifier_unregister(struct notifier_block *nb);
#else
static inline int qpnp_labibb_notifier_register(struct notifier_block *nb)
{
return 0;
}
static inline int qpnp_labibb_notifier_unregister(struct notifier_block *nb)
{
return 0;
}
#endif
#endif