Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Fields
regulator_ops Struct Reference

#include <driver.h>

Data Fields

int(* list_voltage )(struct regulator_dev *, unsigned selector)
 
int(* set_voltage )(struct regulator_dev *, int min_uV, int max_uV, unsigned *selector)
 
int(* map_voltage )(struct regulator_dev *, int min_uV, int max_uV)
 
int(* set_voltage_sel )(struct regulator_dev *, unsigned selector)
 
int(* get_voltage )(struct regulator_dev *)
 
int(* get_voltage_sel )(struct regulator_dev *)
 
int(* set_current_limit )(struct regulator_dev *, int min_uA, int max_uA)
 
int(* get_current_limit )(struct regulator_dev *)
 
int(* enable )(struct regulator_dev *)
 
int(* disable )(struct regulator_dev *)
 
int(* is_enabled )(struct regulator_dev *)
 
int(* set_mode )(struct regulator_dev *, unsigned int mode)
 
unsigned int(* get_mode )(struct regulator_dev *)
 
int(* enable_time )(struct regulator_dev *)
 
int(* set_ramp_delay )(struct regulator_dev *, int ramp_delay)
 
int(* set_voltage_time_sel )(struct regulator_dev *, unsigned int old_selector, unsigned int new_selector)
 
int(* get_status )(struct regulator_dev *)
 
unsigned int(* get_optimum_mode )(struct regulator_dev *, int input_uV, int output_uV, int load_uA)
 
int(* set_bypass )(struct regulator_dev *dev, bool enable)
 
int(* get_bypass )(struct regulator_dev *dev, bool *enable)
 
int(* set_suspend_voltage )(struct regulator_dev *, int uV)
 
int(* set_suspend_enable )(struct regulator_dev *)
 
int(* set_suspend_disable )(struct regulator_dev *)
 
int(* set_suspend_mode )(struct regulator_dev *, unsigned int mode)
 

Detailed Description

struct regulator_ops - regulator operations.

: Configure the regulator as enabled. : Configure the regulator as disabled. : Return 1 if the regulator is enabled, 0 if not. May also return negative errno.

: Set the voltage for the regulator within the range specified. The driver should select the voltage closest to min_uV. : Set the voltage for the regulator using the specified selector. : Convert a voltage into a selector : Return the currently configured voltage for the regulator. : Return the currently configured voltage selector for the regulator. : Return one of the supported voltages, in microvolts; zero if the selector indicates a voltage that is unusable on this system; or negative errno. Selectors range from zero to one less than regulator_desc.n_voltages. Voltages may be reported in any order.

: Configure a limit for a current-limited regulator. The driver should select the current closest to max_uA. : Get the configured limit for a current-limited regulator.

: Set the configured operating mode for the regulator. : Get the configured operating mode for the regulator. : Return actual (not as-configured) status of regulator, as a REGULATOR_STATUS value (or negative errno) : Get the most efficient operating mode for the regulator when running with the specified parameters.

: Set the regulator in bypass mode. : Get the regulator bypass mode state.

: Time taken for the regulator voltage output voltage to stabilise after being enabled, in microseconds. : Set the ramp delay for the regulator. The driver should select ramp delay equal to or less than(closest) ramp_delay. : Time taken for the regulator voltage output voltage to stabilise after being set to a new value, in microseconds. The function provides the from and to voltage selector, the function should return the worst case.

: Set the voltage for the regulator when the system is suspended. : Mark the regulator as enabled when the system is suspended. : Mark the regulator as disabled when the system is suspended. : Set the operating mode for the regulator when the system is suspended.

This struct describes regulator operations which can be implemented by regulator chip drivers.

Definition at line 97 of file driver.h.

Field Documentation

int(* disable)(struct regulator_dev *)

Definition at line 117 of file driver.h.

int(* enable)(struct regulator_dev *)

Definition at line 116 of file driver.h.

int(* enable_time)(struct regulator_dev *)

Definition at line 125 of file driver.h.

int(* get_bypass)(struct regulator_dev *dev, bool *enable)

Definition at line 144 of file driver.h.

int(* get_current_limit)(struct regulator_dev *)

Definition at line 113 of file driver.h.

unsigned int(* get_mode)(struct regulator_dev *)

Definition at line 122 of file driver.h.

unsigned int(* get_optimum_mode)(struct regulator_dev *, int input_uV, int output_uV, int load_uA)

Definition at line 139 of file driver.h.

int(* get_status)(struct regulator_dev *)

Definition at line 136 of file driver.h.

int(* get_voltage)(struct regulator_dev *)

Definition at line 107 of file driver.h.

int(* get_voltage_sel)(struct regulator_dev *)

Definition at line 108 of file driver.h.

int(* is_enabled)(struct regulator_dev *)

Definition at line 118 of file driver.h.

int(* list_voltage)(struct regulator_dev *, unsigned selector)

Definition at line 100 of file driver.h.

int(* map_voltage)(struct regulator_dev *, int min_uV, int max_uV)

Definition at line 105 of file driver.h.

int(* set_bypass)(struct regulator_dev *dev, bool enable)

Definition at line 143 of file driver.h.

int(* set_current_limit)(struct regulator_dev *, int min_uA, int max_uA)

Definition at line 111 of file driver.h.

int(* set_mode)(struct regulator_dev *, unsigned int mode)

Definition at line 121 of file driver.h.

int(* set_ramp_delay)(struct regulator_dev *, int ramp_delay)

Definition at line 126 of file driver.h.

int(* set_suspend_disable)(struct regulator_dev *)

Definition at line 154 of file driver.h.

int(* set_suspend_enable)(struct regulator_dev *)

Definition at line 153 of file driver.h.

int(* set_suspend_mode)(struct regulator_dev *, unsigned int mode)

Definition at line 157 of file driver.h.

int(* set_suspend_voltage)(struct regulator_dev *, int uV)

Definition at line 150 of file driver.h.

int(* set_voltage)(struct regulator_dev *, int min_uV, int max_uV, unsigned *selector)

Definition at line 103 of file driver.h.

int(* set_voltage_sel)(struct regulator_dev *, unsigned selector)

Definition at line 106 of file driver.h.

int(* set_voltage_time_sel)(struct regulator_dev *, unsigned int old_selector, unsigned int new_selector)

Definition at line 127 of file driver.h.


The documentation for this struct was generated from the following file: