[Nut-upsdev] Re: [Nut-upsuser] MGE Nova AVR 600 USB on FreeBSD

Arnaud Quette aquette.dev at gmail.com
Mon Feb 19 15:02:41 CET 2007


2007/2/19, Arjen de Korte <nut+devel at de-korte.org>:
> [ moving over to development list ]
>
> >> Should we make this a default, Arnaud?
> >>
> >> #if SUN_LIBUSB
> >> #define DEFAULT_POLLFREQ        10      /* Polling interval, in seconds
> >> */
> >>                                         /* The driver will do "light */
> >>                                         /* poll" between full polls */
> >> #else
> >> #define DEFAULT_POLLFREQ        30      /* Polling interval, in seconds
> >> */
> >>                                         /* The driver will wait for
> >> Interrupt */
> >>                                         /* and do "light poll" in the
> >> meantime */
> >> #endif
> >
> > I would prefer not to do so, since this interrupt on sun is only a
> > temporary hack, while waiting for the upstream fix.
>
> That only adds bonus points to making this a default when SUN_LIBUSB is
> defined. We have no control over 'pollfreq = <whatever>' once it has been
> added by users, while we can change the defaults (almost) at will. So
> setting a sensible default based on what we find is probably much better
> than telling people to add pollfreq if they run FreeBSD or SUN.

sure, but it shouldn't hurt to have to wait a bit more for seing update, versus
having to reply about "staleness" messages in the log...

> > Moreover, lowering the pollfreq will result in some staleness due to
> > too much polling. So this fix would end up in creating some more
> > problems.
>
> So the question remains, what's sensible? :-)

subjectivity ;-)
maybe 15 sec would be a good compromise between the 2 problems

> > That said, I'm not much opposed to your proposition. We only need a
> > way to remember that when the upstream fix are there, we will need to
> > remove such things... (simply removing the configure part will do by
> > side effect, but leave some dead code)
>
> The latter is something we have to deal with any way. I'm fairly confident
> that we have quite a bit of dead code in the trunk already. I'll see if I
> can cook up a script that verifies that all the #if's and #ifdef's can be
> set by configuration tools. We probably should run this at least before
> new releases, but it wouldn't hurt to do this more often.

part of the QA sub project, it would be good to have a script,
sourcing other scripts, which would do all these kind of checks and
possibly being called by the "make distcheck"...

Arnaud
-- 
Linux / Unix Expert - MGE UPS SYSTEMS - R&D Dpt
Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/
Debian Developer - http://people.debian.org/~aquette/
OpenSource Developer - http://arnaud.quette.free.fr/



More information about the Nut-upsdev mailing list