[Nut-upsdev] megatec and some changes to cmdvartab and new-names.txt

Arjen de Korte nut+devel at de-korte.org
Mon Dec 4 12:37:16 CET 2006


>> 1) The blazer, fentonups, esupssmart, ippon, sms and mustek drivers
>> are now completely covered and all of their functionality should now
>> be present in megatec, and also every model supported by them should
>> now be supported by megatec (with additional funcionality). So, I have
>> changed "driver.list" so that all hardware supported by these drivers
>> is now "megatec or <theotherdriver>".
>>
>> However, I think the other drivers' "ups_banner" function should be
>> changed (now necessarily right now) to indicate that they are due to
>> be removed sometime in the future and megatec should be used instead
>> (if possible). Am I right?
>
> I think that would be the proper way to inform people. Unfortunately many
> startup scripts will just /dev/null any output we generate, so chances are
> that they will never notice until the old drivers are actually removed
> from the tree. If we ever do, it might be a good idea to create softlinks
> to the new megatec driver instead for a couple of versions. You could then
> check for argv[0] to see how the driver was started and display a similar
> warning if an old driver name was used (provided there are no incompatible
> changes).

Adding the following lines to the upsdrv_banner() function in the megatec
driver should do the trick:

if (strcmp(progname, "megatec"))
{
	printf("The '%s' driver is replaced by the 'megatec' driver.\n", progname);
	printf("Please update your 'ups.conf' configuration file.\n\n");
}

If we're certain that the megatec driver is equivalent (or better) than
the existing drivers, we might want to create the softlinks and do this
right away. The old drivers don't seem to have gotten a lot maintenance
lately anyway.

Regards, Arjen




More information about the Nut-upsdev mailing list