Re: [PATCH v2 00/10] sysfs: constify struct bin_attribute (Part 1)

2024-11-03 Thread Krzysztof Wilczyński
n_attribute' itself. > > The techniques employed by this series can later be reused for the > same change for other sysfs attributes. > > This series is intended to be merged through the driver core tree. This is very nice. Thank you! For PCI changes: Acked-by: Krzysztof Wil

Re: [PATCH v2 02/10] sysfs: introduce callback attribute_group::bin_size

2024-11-06 Thread Krzysztof Wilczyński
Hello, > Several drivers need to dynamically calculate the size of an binary > attribute. Currently this is done by assigning attr->size from the > is_bin_visible() callback. > > This has drawbacks: > * It is not documented. > * A single attribute can be instantiated multiple times, overwriting t

Re: [PATCH v2 02/10] sysfs: introduce callback attribute_group::bin_size

2024-11-07 Thread Krzysztof Wilczyński
Hello, [...] > > There exist the sysfs_update_groups(), but the BAR resource sysfs objects > > are currently, at least not yet, added to any attribute group. > > then maybe they should be added to one :) Yeah. There is work in progress that will take care of some of this. Krzysztof