On Wed, Jul 27, 2022 at 06:08:09PM +0800, Kent Gibson wrote: > > > > + > > > > + /// Get the edge event buffer size for the request config. > > > > + pub fn get_event_buffer_size(&self) -> u32 { > > > > + unsafe { bindings::gpiod_request_config_get_event_buffer_size(self.config) as u32 } > > > > + } > > > > > > You might want to note that this just reads the value from the config. > > > The actual value used by the kernel is not made available to user space. > > > > Do you want me to add these two comments for the above two routines ? > > > > Not add verbatim. Maybe work them in. > Probably should look at revising the C API comments and then just mirror that. > Just to be clear, I don't think we want to get into the details as to how the kernel interprets that setting, so that is just informational for you in case you find the kernel doesn't buffer exactly the number you expected. The description for the set covers the case where you might get less than you expected. But in some cases you may get more. The key difference is that the C API description says: @return Edge event buffer size setting from the request config. ^^^^^^^ which indicates you are getting the setting value back, not whatever the buffer size in the kernel actually is. That is missing from the one-liner description, which is all you copied. So if you are going to condense it to one line then add "setting" in there. Cheers, Kent.