• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2021 Huawei Device Co., Ltd.
3  *
4  * This software is licensed under the terms of the GNU General Public
5  * License version 2, as published by the Free Software Foundation, and
6  * may be copied, distributed, and modified under those terms.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  */
14 
15 #ifndef REGULATOR_ADAPTER_H
16 #define REGULATOR_ADAPTER_H
17 #include "hdf_base.h"
18 
19 #define VOLTAGE_2500_UV 2500
20 #define CURRENT_2500_UA 2500
21 
22 struct LinuxRegulatorInfo {
23     const char *devName; // note:linux kernel constraints:len(devName) + len(supplyName) < REG_STR_SIZE(64)
24     const char *supplyName; // note:linux kernel constraints:len(devName) + len(supplyName) < REG_STR_SIZE(64)
25     struct device *dev;
26     struct regulator *adapterReg;
27 };
28 int32_t LinuxRegulatorSetConsumerDev(struct device *dev);
29 #endif /* REGULATOR_ADAPTER_H */
30