zynq_gpio_get_bank_pin(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… zynq_gpio_get_bank_pin(9) β€” a Kernel API Manual moment

okay so bestie, welcome to the Kernel API Manual ✨ this one's a little helper function in the kernel, and honestly? she's serving utility. her whole job is telling you which bank a GPIO pin lives in, and what its pin number is inside that bank. no cap, that's it. πŸŽ€


✨ NAME ✨

zynq_gpio_get_bank_pin β€” get the bank number and pin number within that bank for a given pin in the GPIO device πŸ¦‹

like, you hand her a pin, she tells you where it actually lives. it's giving "let me look that up for you bestie" energy.


✨ SYNOPSIS ✨

void zynq_gpio_get_bank_pin (unsigned int pin_num , unsigned int
*bank_num , unsigned int *bank_pin_num , struct zynq_gpio *gpio );

note the void β€” she does not return a value to you, she writes into your pointers instead. classic. πŸ™ˆ


✨ ARGUMENTS ✨

  • pin_num β€” the gpio pin number within the device 🌸 this is the one you're asking about, your main character input.
  • bank_num β€” an output parameter used to return the bank number of the gpio pin πŸ’– you pass the address, she fills it in. that's the whole vibe.
  • bank_pin_num β€” an output parameter used to return pin number within a bank for the given gpio pin πŸŽ€ so like, the local coordinates. the within-bank address. iykyk.
  • gpio β€” gpio device data structure 🧚 the device she's looking at, struct zynq_gpio * style.
lowkey important: bank_num and bank_pin_num are output parameters fr fr β€” she's not reading them, she's writing to them. give her real pointers or it's not gonna be a good time. πŸ’€

✨ DESCRIPTION ✨

Returns the bank number and pin offset within the bank. 🫢

that's the entire plot. one pin in, two numbers out. she's not doing anything fancy, she's just doing it correctly, and honestly? iconic. πŸ‘‘


✨ SEE ALSO ✨

so if you're going down the rabbit hole (and you should be, bestie), the kernel file is ./drivers/gpio/gpio-zynq.c ⭐ and here's the whole friend group:


and that's the whole page, bestie!! πŸŽ€βœ¨πŸ’– this lil cutie lives in ./drivers/gpio, dated October 2026, and she's out here slaying the zynq_gpio_get_bank_pin(9) lifestyle. go read some GPIO code, ily, bye πŸ«ΆπŸ’œ

πŸ“¦ where this page comes from