ugen lockups with apcupsd

Mike Tancsa mike at sentex.net
Mon Apr 18 21:15:28 PDT 2005


At 09:42 PM 18/04/2005, Adam Kropelin wrote:
>Mike Tancsa wrote:
>>Hi,
>>          I have been trying out the apcupsd program with an APC
>>RS-1500 on FreeBSD via the ugen interface.  On my VIA box, the machine 
>>locks up
>>solid within a short period of time after starting the daemon.
>
>This is a known bug and is fixed by a patch I posted to apcupsd-users. The 
>BSD UHCI driver has a tendency to leave transfers on the queue when they 
>complete 'short' (i.e., with fewer bytes than expected). This happens 
>often in apcupsd-3.10.17 due to some poor coding on my part, but can also 
>happen on UPSes having broken firmware that sends fewer bytes than the 
>report descriptor claims. (These UPSes do not deadlock on Linux, so I 
>think there is still a BSD UHCI bug here, but luckily it can be worked 
>around in apcupsd.)

Hi, actually, I was just about to post that I found the patches while 
looking through the mailing archives and it does seem to fix the issue.  I 
will let it run overnight to see if it fixes it long term by doing an 
apcaccess status once per second in a loop.

I guess this is still kind of a bug as a userland app could potentially DoS 
a system no ?  One does not need to be root to open the device and 
presumably a malicious program could recreate the issue no ?

Thanks again for the code and fix!

         ---Mike 



More information about the freebsd-usb mailing list