On Thu 2016-11-03 22:00:56, Matt Ranostay wrote: > On Wed, Nov 2, 2016 at 1:22 AM, Pavel Machek <pavel@xxxxxx> wrote: > > Hi! > > > >> >> >> Better then previous one. > >> >> >> > >> >> >> But my version of bq27xxx_battery.c already contains this: > >> >> > > >> >> > This is for allowing udev rule to set the properties as well. > >> >> > otherwise a kinda crude RUN = " echo value > > >> >> > /sys/module/bq27xxx_battery/parameters/poll_interval" is required. > >> >> > >> >> Any thoughts on this? > >> > > >> > I'd say echo value > > >> > /sys/module/bq27xxx_battery/parameters/poll_interval .. is quite > >> > adequate solution...? > >> > > >> > Alternatively, convince us that something else is useful for everyone, > >> > and we can do the right thing (poll more often when battery is nearly > >> > empty), automatically... > >> > >> Ok should have had the patchset set it per device, and not use the > >> global poll_interval. Of need to add some logic to see if uses the > >> global poll_interval or it's own setting. > >> > >> There are times where you could have multiple batteries connected to > >> multiple fuel gauges, and want to up the polling interval on certain > >> ones that are discharging at different rates. > >> > >> But of course I'll let you guys let me know if this seems useful at all. > > > > I agree per-device polling would be cleaner. > > > > Ok I'll work something up for RFC. > > > But unless you have hardware with more than one bq27xxx, I'd avoid the > > work... > > > > Now... its also possible that poll_interval should change itself > > (within kernel) to do the right thing. > > > > True but that is state machine territory, but I'll worry about that later... Do you actually have hardware with more than one bq27xxx? Best regards, Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Attachment:
signature.asc
Description: Digital signature