Re: [PATCH v2 5/9] gpio: sysfs: rename the data variable in gpiod_(un)export()

From: Bartosz Golaszewski
Date: Mon Jun 30 2025 - 05:03:31 EST


On Mon, Jun 30, 2025 at 10:57 AM Bartosz Golaszewski <brgl@xxxxxxxx> wrote:
>
> On Fri, Jun 27, 2025 at 5:43 PM Andy Shevchenko
> <andriy.shevchenko@xxxxxxxxx> wrote:
> >
> > On Mon, Jun 23, 2025 at 10:59:53AM +0200, Bartosz Golaszewski wrote:
> > >
> > > In preparation for future commits which will make use of descriptor AND
> > > GPIO-device data in the same functions rename the former from data to
> > > desc_data separately which will make future changes smaller and easier
> > > to read.
> >
> > ...
> >
> > > + attrs = desc_data->attrs;
> > > + desc_data->attr_group.is_visible = gpio_is_visible;
> > > + attrs[GPIO_SYSFS_LINE_ATTR_DIRECTION] = &desc_data->dir_attr.attr;
> > > + attrs[GPIO_SYSFS_LINE_ATTR_VALUE] = &desc_data->val_attr.attr;
> > > + attrs[GPIO_SYSFS_LINE_ATTR_EDGE] = &desc_data->edge_attr.attr;
> > > attrs[GPIO_SYSFS_LINE_ATTR_ACTIVE_LOW] =
> > > - &data->active_low_attr.attr;
> > > + &desc_data->active_low_attr.attr;
> >
> > These were added in the previous patch and immediately got rewritten?!
> > Sounds like a wrong patch order.
> >
>
> Yeah, bad rebase. Thanks for catching it.
>
> Bart

Ah, no actually I got misled by the indentation difference. It was
supposed to be like this but maybe it is better to change places of
those two patches.

Bart