regulator: max77802: Add header for operating modes

Add a header file for the max77802 constants that could be shared between
the regulator driver and Device Tree source files. Also, remove standby
and off opmodes since only normal and low power are valid operating modes.

Signed-off-by: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Javier Martinez Canillas 2014-10-16 18:48:50 +02:00 committed by Mark Brown
parent 0505be7149
commit 5356e0da49
3 changed files with 19 additions and 7 deletions

View File

@ -33,6 +33,7 @@
#include <linux/regulator/of_regulator.h>
#include <linux/mfd/max77686.h>
#include <linux/mfd/max77686-private.h>
#include <dt-bindings/regulator/maxim,max77802.h>
/* Default ramp delay in case it is not manually set */
#define MAX77802_RAMP_DELAY 100000 /* uV/us */

View File

@ -0,0 +1,18 @@
/*
* Copyright (C) 2014 Google, Inc
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* Device Tree binding constants for the Maxim 77802 PMIC regulators
*/
#ifndef _DT_BINDINGS_REGULATOR_MAXIM_MAX77802_H
#define _DT_BINDINGS_REGULATOR_MAXIM_MAX77802_H
/* Regulator operating modes */
#define MAX77802_OPMODE_LP 1
#define MAX77802_OPMODE_NORMAL 3
#endif /* _DT_BINDINGS_REGULATOR_MAXIM_MAX77802_H */

View File

@ -131,13 +131,6 @@ enum max77686_opmode {
MAX77686_OPMODE_STANDBY,
};
enum max77802_opmode {
MAX77802_OPMODE_OFF,
MAX77802_OPMODE_STANDBY,
MAX77802_OPMODE_LP,
MAX77802_OPMODE_NORMAL,
};
struct max77686_opmode_data {
int id;
int mode;