drivers/pinctrl/microchip/pinctrl-pic64gx-gpio2.c
Source file repositories/reference/linux-study-clean/drivers/pinctrl/microchip/pinctrl-pic64gx-gpio2.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/pinctrl/microchip/pinctrl-pic64gx-gpio2.c- Extension
.c- Size
- 9358 bytes
- Lines
- 357
- Domain
- Driver Families
- Bucket
- drivers/pinctrl
- Inferred role
- Driver Families: implementation source
- Status
- source 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.
- 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/bitfield.hlinux/module.hlinux/mfd/syscon.hlinux/mod_devicetable.hlinux/of.hlinux/platform_device.hlinux/regmap.hlinux/seq_file.hlinux/pinctrl/pinconf-generic.hlinux/pinctrl/pinconf.hlinux/pinctrl/pinctrl.hlinux/pinctrl/pinmux.h../pinctrl-utils.h
Detected Declarations
struct pic64gx_gpio2_pinctrlstruct pic64gx_gpio2_pin_groupstruct pic64gx_gpio2_functionfunction pic64gx_gpio2_pin_dbg_showfunction pic64gx_gpio2_groups_countfunction pic64gx_gpio2_group_pinsfunction pic64gx_gpio2_pinmux_get_funcs_countfunction pic64gx_gpio2_pinmux_get_groupsfunction pic64gx_gpio2_pinmux_set_muxfunction pic64gx_gpio2_probe
Annotated Snippet
struct pic64gx_gpio2_pinctrl {
struct pinctrl_dev *pctrl;
struct device *dev;
struct regmap *regmap;
struct pinctrl_desc desc;
};
struct pic64gx_gpio2_pin_group {
const char *name;
const unsigned int *pins;
const unsigned int num_pins;
u32 mask;
u32 setting;
};
struct pic64gx_gpio2_function {
const char *name;
const char * const *groups;
const unsigned int num_groups;
};
static const struct pinctrl_pin_desc pic64gx_gpio2_pins[] = {
PINCTRL_PIN(0, "E14"),
PINCTRL_PIN(1, "E15"),
PINCTRL_PIN(2, "F16"),
PINCTRL_PIN(3, "F17"),
PINCTRL_PIN(4, "D19"),
PINCTRL_PIN(5, "B18"),
PINCTRL_PIN(6, "B10"),
PINCTRL_PIN(7, "C14"),
PINCTRL_PIN(8, "E18"),
PINCTRL_PIN(9, "D18"),
PINCTRL_PIN(10, "E19"),
PINCTRL_PIN(11, "C7"),
PINCTRL_PIN(12, "D6"),
PINCTRL_PIN(13, "D7"),
PINCTRL_PIN(14, "C9"),
PINCTRL_PIN(15, "C10"),
PINCTRL_PIN(16, "A5"),
PINCTRL_PIN(17, "A6"),
PINCTRL_PIN(18, "D8"),
PINCTRL_PIN(19, "D9"),
PINCTRL_PIN(20, "B8"),
PINCTRL_PIN(21, "A8"),
PINCTRL_PIN(22, "C12"),
PINCTRL_PIN(23, "B12"),
PINCTRL_PIN(24, "A11"),
PINCTRL_PIN(25, "A10"),
PINCTRL_PIN(26, "D11"),
PINCTRL_PIN(27, "C11"),
PINCTRL_PIN(28, "B9"),
};
static const unsigned int pic64gx_gpio2_mdio0_pins[] = {
0, 1
};
static const unsigned int pic64gx_gpio2_mdio1_pins[] = {
2, 3
};
static const unsigned int pic64gx_gpio2_spi0_pins[] = {
4, 5, 10, 11
};
static const unsigned int pic64gx_gpio2_can0_pins[] = {
6, 24, 28
};
static const unsigned int pic64gx_gpio2_pcie_pins[] = {
7, 8, 9
};
static const unsigned int pic64gx_gpio2_qspi_pins[] = {
12, 13, 14, 15, 16, 17
};
static const unsigned int pic64gx_gpio2_uart3_pins[] = {
18, 19
};
static const unsigned int pic64gx_gpio2_uart4_pins[] = {
20, 21
};
static const unsigned int pic64gx_gpio2_can1_pins[] = {
22, 23, 25
};
static const unsigned int pic64gx_gpio2_uart2_pins[] = {
Annotation
- Immediate include surface: `linux/bitfield.h`, `linux/module.h`, `linux/mfd/syscon.h`, `linux/mod_devicetable.h`, `linux/of.h`, `linux/platform_device.h`, `linux/regmap.h`, `linux/seq_file.h`.
- Detected declarations: `struct pic64gx_gpio2_pinctrl`, `struct pic64gx_gpio2_pin_group`, `struct pic64gx_gpio2_function`, `function pic64gx_gpio2_pin_dbg_show`, `function pic64gx_gpio2_groups_count`, `function pic64gx_gpio2_group_pins`, `function pic64gx_gpio2_pinmux_get_funcs_count`, `function pic64gx_gpio2_pinmux_get_groups`, `function pic64gx_gpio2_pinmux_set_mux`, `function pic64gx_gpio2_probe`.
- Atlas domain: Driver Families / drivers/pinctrl.
- 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.