blob: f68bcdeb39c607dbab02edafa5d0259dac09074b [file] [log] [blame]
Jim Wylder460453e2023-03-07 11:27:54 -06001/* SPDX-License-Identifier: GPL-2.0-only */
2/*
3 * SW Support for MAX77779 IF-PMIC
4 *
5 * Copyright 2023 Google, LLC
6 */
7#ifndef MAX77779_PMIC
8#define MAX77779_PMIC
9
10#include <linux/device.h>
Daniel Okazaki0dd15c32023-11-20 23:39:54 +000011
12#include "max77779.h"
13
14struct max77779_pmic_info {
15 struct device *dev;
16 struct regmap *regmap;
Daniel Okazaki199f55a2024-02-14 22:30:34 +000017 struct mutex reg_dump_lock;
Daniel Okazaki0dd15c32023-11-20 23:39:54 +000018#if IS_ENABLED(CONFIG_DEBUG_FS)
19 struct dentry *de;
20 unsigned int addr;
21#endif
22};
Jim Wylder460453e2023-03-07 11:27:54 -060023
Daniel Okazaki0dd15c32023-11-20 23:39:54 +000024bool max77779_pmic_is_readable(struct device *dev, unsigned int reg);
25int max77779_pmic_init(struct max77779_pmic_info *info);
26void max77779_pmic_remove(struct max77779_pmic_info *info);
Jim Wylder460453e2023-03-07 11:27:54 -060027#endif