linux/include/linux/mfd/wm831x/pmu.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 * include/linux/mfd/wm831x/pmu.h -- PMU for WM831x
 *
 * Copyright 2009 Wolfson Microelectronics PLC.
 *
 * Author: Mark Brown <[email protected]>
 */

#ifndef __MFD_WM831X_PMU_H__
#define __MFD_WM831X_PMU_H__

/*
 * R16387 (0x4003) - Power State
 */
#define WM831X_CHIP_ON
#define WM831X_CHIP_ON_MASK
#define WM831X_CHIP_ON_SHIFT
#define WM831X_CHIP_ON_WIDTH
#define WM831X_CHIP_SLP
#define WM831X_CHIP_SLP_MASK
#define WM831X_CHIP_SLP_SHIFT
#define WM831X_CHIP_SLP_WIDTH
#define WM831X_REF_LP
#define WM831X_REF_LP_MASK
#define WM831X_REF_LP_SHIFT
#define WM831X_REF_LP_WIDTH
#define WM831X_PWRSTATE_DLY_MASK
#define WM831X_PWRSTATE_DLY_SHIFT
#define WM831X_PWRSTATE_DLY_WIDTH
#define WM831X_SWRST_DLY
#define WM831X_SWRST_DLY_MASK
#define WM831X_SWRST_DLY_SHIFT
#define WM831X_SWRST_DLY_WIDTH
#define WM831X_USB100MA_STARTUP_MASK
#define WM831X_USB100MA_STARTUP_SHIFT
#define WM831X_USB100MA_STARTUP_WIDTH
#define WM831X_USB_CURR_STS
#define WM831X_USB_CURR_STS_MASK
#define WM831X_USB_CURR_STS_SHIFT
#define WM831X_USB_CURR_STS_WIDTH
#define WM831X_USB_ILIM_MASK
#define WM831X_USB_ILIM_SHIFT
#define WM831X_USB_ILIM_WIDTH

/*
 * R16397 (0x400D) - System Status
 */
#define WM831X_THW_STS
#define WM831X_THW_STS_MASK
#define WM831X_THW_STS_SHIFT
#define WM831X_THW_STS_WIDTH
#define WM831X_PWR_SRC_BATT
#define WM831X_PWR_SRC_BATT_MASK
#define WM831X_PWR_SRC_BATT_SHIFT
#define WM831X_PWR_SRC_BATT_WIDTH
#define WM831X_PWR_WALL
#define WM831X_PWR_WALL_MASK
#define WM831X_PWR_WALL_SHIFT
#define WM831X_PWR_WALL_WIDTH
#define WM831X_PWR_USB
#define WM831X_PWR_USB_MASK
#define WM831X_PWR_USB_SHIFT
#define WM831X_PWR_USB_WIDTH
#define WM831X_MAIN_STATE_MASK
#define WM831X_MAIN_STATE_SHIFT
#define WM831X_MAIN_STATE_WIDTH

/*
 * R16456 (0x4048) - Charger Control 1
 */
#define WM831X_CHG_ENA
#define WM831X_CHG_ENA_MASK
#define WM831X_CHG_ENA_SHIFT
#define WM831X_CHG_ENA_WIDTH
#define WM831X_CHG_FRC
#define WM831X_CHG_FRC_MASK
#define WM831X_CHG_FRC_SHIFT
#define WM831X_CHG_FRC_WIDTH
#define WM831X_CHG_ITERM_MASK
#define WM831X_CHG_ITERM_SHIFT
#define WM831X_CHG_ITERM_WIDTH
#define WM831X_CHG_FAST
#define WM831X_CHG_FAST_MASK
#define WM831X_CHG_FAST_SHIFT
#define WM831X_CHG_FAST_WIDTH
#define WM831X_CHG_IMON_ENA
#define WM831X_CHG_IMON_ENA_MASK
#define WM831X_CHG_IMON_ENA_SHIFT
#define WM831X_CHG_IMON_ENA_WIDTH
#define WM831X_CHG_CHIP_TEMP_MON
#define WM831X_CHG_CHIP_TEMP_MON_MASK
#define WM831X_CHG_CHIP_TEMP_MON_SHIFT
#define WM831X_CHG_CHIP_TEMP_MON_WIDTH

/*
 * R16457 (0x4049) - Charger Control 2
 */
#define WM831X_CHG_OFF_MSK
#define WM831X_CHG_OFF_MSK_MASK
#define WM831X_CHG_OFF_MSK_SHIFT
#define WM831X_CHG_OFF_MSK_WIDTH
#define WM831X_CHG_TIME_MASK
#define WM831X_CHG_TIME_SHIFT
#define WM831X_CHG_TIME_WIDTH
#define WM831X_CHG_TRKL_ILIM_MASK
#define WM831X_CHG_TRKL_ILIM_SHIFT
#define WM831X_CHG_TRKL_ILIM_WIDTH
#define WM831X_CHG_VSEL_MASK
#define WM831X_CHG_VSEL_SHIFT
#define WM831X_CHG_VSEL_WIDTH
#define WM831X_CHG_FAST_ILIM_MASK
#define WM831X_CHG_FAST_ILIM_SHIFT
#define WM831X_CHG_FAST_ILIM_WIDTH

/*
 * R16458 (0x404A) - Charger Status
 */
#define WM831X_BATT_OV_STS
#define WM831X_BATT_OV_STS_MASK
#define WM831X_BATT_OV_STS_SHIFT
#define WM831X_BATT_OV_STS_WIDTH
#define WM831X_CHG_STATE_MASK
#define WM831X_CHG_STATE_SHIFT
#define WM831X_CHG_STATE_WIDTH
#define WM831X_BATT_HOT_STS
#define WM831X_BATT_HOT_STS_MASK
#define WM831X_BATT_HOT_STS_SHIFT
#define WM831X_BATT_HOT_STS_WIDTH
#define WM831X_BATT_COLD_STS
#define WM831X_BATT_COLD_STS_MASK
#define WM831X_BATT_COLD_STS_SHIFT
#define WM831X_BATT_COLD_STS_WIDTH
#define WM831X_CHG_TOPOFF
#define WM831X_CHG_TOPOFF_MASK
#define WM831X_CHG_TOPOFF_SHIFT
#define WM831X_CHG_TOPOFF_WIDTH
#define WM831X_CHG_ACTIVE
#define WM831X_CHG_ACTIVE_MASK
#define WM831X_CHG_ACTIVE_SHIFT
#define WM831X_CHG_ACTIVE_WIDTH
#define WM831X_CHG_TIME_ELAPSED_MASK
#define WM831X_CHG_TIME_ELAPSED_SHIFT
#define WM831X_CHG_TIME_ELAPSED_WIDTH

#define WM831X_CHG_STATE_OFF
#define WM831X_CHG_STATE_TRICKLE
#define WM831X_CHG_STATE_FAST
#define WM831X_CHG_STATE_TRICKLE_OT
#define WM831X_CHG_STATE_FAST_OT
#define WM831X_CHG_STATE_DEFECTIVE

/*
 * R16459 (0x404B) - Backup Charger Control
 */
#define WM831X_BKUP_CHG_ENA
#define WM831X_BKUP_CHG_ENA_MASK
#define WM831X_BKUP_CHG_ENA_SHIFT
#define WM831X_BKUP_CHG_ENA_WIDTH
#define WM831X_BKUP_CHG_STS
#define WM831X_BKUP_CHG_STS_MASK
#define WM831X_BKUP_CHG_STS_SHIFT
#define WM831X_BKUP_CHG_STS_WIDTH
#define WM831X_BKUP_CHG_MODE
#define WM831X_BKUP_CHG_MODE_MASK
#define WM831X_BKUP_CHG_MODE_SHIFT
#define WM831X_BKUP_CHG_MODE_WIDTH
#define WM831X_BKUP_BATT_DET_ENA
#define WM831X_BKUP_BATT_DET_ENA_MASK
#define WM831X_BKUP_BATT_DET_ENA_SHIFT
#define WM831X_BKUP_BATT_DET_ENA_WIDTH
#define WM831X_BKUP_BATT_STS
#define WM831X_BKUP_BATT_STS_MASK
#define WM831X_BKUP_BATT_STS_SHIFT
#define WM831X_BKUP_BATT_STS_WIDTH
#define WM831X_BKUP_CHG_VLIM
#define WM831X_BKUP_CHG_VLIM_MASK
#define WM831X_BKUP_CHG_VLIM_SHIFT
#define WM831X_BKUP_CHG_VLIM_WIDTH
#define WM831X_BKUP_CHG_ILIM_MASK
#define WM831X_BKUP_CHG_ILIM_SHIFT
#define WM831X_BKUP_CHG_ILIM_WIDTH

#endif