pinctrl_par...ex_with_args(9)
π pinctrl_parse_index_with_args β from the Kernel API Manual, section 9 π
okay so bestie, buckle up, because we're diving into pinctrl_parse_index_with_args(9) and honestly? she's a little niche but she serves. π
β¨ NAME β¨
pinctrl_parse_index_with_args β literally just "find a node pointed by index in a list". that's the whole gig. main character energy but make it a lookup function. π¦
πΈ SYNOPSIS πΈ
int pinctrl_parse_index_with_args (const struct device_node *np ,
const char *list_name ,
int index ,
struct of_phandle_args *out_args );
yeah she takes four args and returns an int, no cap. π
π§ ARGUMENTS π§
npβ pointer to device node with the property. like, the device node that's holding the thing you want. π«Άlist_nameβ property that contains the list. yes, the actual list. she's aconst char *, be normal about it. β¨indexβ index within the list. you point at which one you want, anintofc. βout_argsβ entries in the list pointed by index. this is where the good stuff gets dropped, astruct of_phandle_args *. π
π₯ DESCRIPTION π₯
so what does she do? she finds the selected element in a pinctrl array. and that array is made of two parts, bestie, keep up:
- an index within the controller
- a number of
u32entries specified for each entry
π¨ important vibe check: the device_node is always for the parent pin controller device. always always. don't come for me on this, it's literally in the source. π
π SEE ALSO π
- the Kernel file
./drivers/pinctrl/devicetree.c(go read her, she's iconic) struct pinctrl_dt_map(9)pinctrl_get_list_and_count(9)pinctrl_count_index_with_args(9)pinctrl_copy_args(9)
and that's the tea, bestie π this whole page lives in ./drivers/pinctrl, dated October 2026 β so yeah, she's from the future, and she ate. πππ¦
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms