include/linux/regulator/gpio-regulator.h
Source file repositories/reference/linux-study-clean/include/linux/regulator/gpio-regulator.h
File Facts
- System
- Linux kernel
- Corpus path
include/linux/regulator/gpio-regulator.h- Extension
.h- Size
- 2176 bytes
- Lines
- 82
- Domain
- Core OS
- Bucket
- Core Kernel Interface
- Inferred role
- Core OS: implementation source
- Status
- source implementation candidate
Why This File Exists
Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/gpio/consumer.h
Detected Declarations
struct regulator_init_datastruct gpio_regulator_statestruct gpio_regulator_configenum regulator_type
Annotated Snippet
struct gpio_regulator_state {
int value;
int gpios;
};
/**
* struct gpio_regulator_config - config structure
* @supply_name: Name of the regulator supply
* @input_supply: Name of the input regulator supply
* @enabled_at_boot: Whether regulator has been enabled at
* boot or not. 1 = Yes, 0 = No
* This is used to keep the regulator at
* the default state
* @startup_delay: Start-up time in microseconds
* @gflags: Array of GPIO configuration flags for initial
* states
* @ngpios: Number of GPIOs and configurations available
* @states: Array of gpio_regulator_state entries describing
* the gpio state for specific voltages
* @nr_states: Number of states available
* @regulator_type: either REGULATOR_CURRENT or REGULATOR_VOLTAGE
* @init_data: regulator_init_data
*
* This structure contains gpio-voltage regulator configuration
* information that must be passed by platform code to the
* gpio-voltage regulator driver.
*/
struct gpio_regulator_config {
const char *supply_name;
const char *input_supply;
unsigned enabled_at_boot:1;
unsigned startup_delay;
enum gpiod_flags *gflags;
int ngpios;
struct gpio_regulator_state *states;
int nr_states;
enum regulator_type type;
struct regulator_init_data *init_data;
};
#endif
Annotation
- Immediate include surface: `linux/gpio/consumer.h`.
- Detected declarations: `struct regulator_init_data`, `struct gpio_regulator_state`, `struct gpio_regulator_config`, `enum regulator_type`.
- Atlas domain: Core OS / Core Kernel Interface.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.