drivers/gpio/gpio-mpc5200.c
Source file repositories/reference/linux-study-clean/drivers/gpio/gpio-mpc5200.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpio/gpio-mpc5200.c- Extension
.c- Size
- 9077 bytes
- Lines
- 377
- Domain
- Driver Families
- Bucket
- drivers/gpio
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/of.hlinux/kernel.hlinux/slab.hlinux/gpio/driver.hlinux/io.hlinux/platform_device.hlinux/module.hasm/mpc52xx.hsysdev/fsl_soc.h
Detected Declarations
struct mpc52xx_gpiochipfunction mpc52xx_wkup_gpio_getfunction __mpc52xx_wkup_gpio_setfunction mpc52xx_wkup_gpio_setfunction mpc52xx_wkup_gpio_dir_infunction mpc52xx_wkup_gpio_dir_outfunction mpc52xx_wkup_gpiochip_probefunction mpc52xx_simple_gpio_getfunction __mpc52xx_simple_gpio_setfunction mpc52xx_simple_gpio_setfunction mpc52xx_simple_gpio_dir_infunction mpc52xx_simple_gpio_dir_outfunction mpc52xx_simple_gpiochip_probefunction mpc52xx_gpio_initfunction mpc52xx_gpio_exitmodule init mpc52xx_gpio_init
Annotated Snippet
subsys_initcall(mpc52xx_gpio_init);
static void __exit mpc52xx_gpio_exit(void)
{
platform_unregister_drivers(drivers, ARRAY_SIZE(drivers));
}
module_exit(mpc52xx_gpio_exit);
MODULE_DESCRIPTION("Freescale MPC52xx gpio driver");
MODULE_AUTHOR("Sascha Hauer <s.hauer@pengutronix.de");
MODULE_LICENSE("GPL v2");
Annotation
- Immediate include surface: `linux/of.h`, `linux/kernel.h`, `linux/slab.h`, `linux/gpio/driver.h`, `linux/io.h`, `linux/platform_device.h`, `linux/module.h`, `asm/mpc52xx.h`.
- Detected declarations: `struct mpc52xx_gpiochip`, `function mpc52xx_wkup_gpio_get`, `function __mpc52xx_wkup_gpio_set`, `function mpc52xx_wkup_gpio_set`, `function mpc52xx_wkup_gpio_dir_in`, `function mpc52xx_wkup_gpio_dir_out`, `function mpc52xx_wkup_gpiochip_probe`, `function mpc52xx_simple_gpio_get`, `function __mpc52xx_simple_gpio_set`, `function mpc52xx_simple_gpio_set`.
- Atlas domain: Driver Families / drivers/gpio.
- Implementation status: integration implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
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.