On Wed, Jul 30, 2025 at 2:49 PM Andy Shevchenko <andy.shevchenko@xxxxxxxxx> wrote: > On Wed, Jul 30, 2025 at 11:54 AM Bartosz Golaszewski <brgl@xxxxxxxx> wrote: > > On Thu, Jul 24, 2025 at 2:22 PM Andy Shevchenko > > <andy.shevchenko@xxxxxxxxx> wrote: > > > > > > > struct pinfunction { > > > > const char *name; > > > > const char * const *groups; > > > > size_t ngroups; > > > > + unsigned long flags; > > > > > > Not sure we need this. If the function is GPIO, pin control already > > > knows about this. The pin muxing has gpio request / release callbacks > > > that change the state. Why do we need an additional flag(s)? > > > > I'm not following, how does the pin controller know that the function > > is GPIO exactly, other than by the bit set in this field? > > AFAICS the gpio_owner != NULL means that. No need to have a duplicate > of this information. To be clear, the pin control and muxing core knows about this, if the certain pin control driver needs that information it can request this from the core or do some other shortcuts (as it knows the state as well in the HW). So, I do not see any need for this flag. But again, maybe I'm missing the subtle corner case? -- With Best Regards, Andy Shevchenko