Hello all,<div><br></div><div>While repeatedly setting up the system for tests figured out the problem in other OS subsystem driver. Problem solved with the script. Thanks again for your time </div><div><br><div class="gmail_quote">
On Fri, Nov 9, 2012 at 6:13 PM, Arnaud Quette <span dir="ltr"><<a href="mailto:aquette.dev@gmail.com" target="_blank">aquette.dev@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br><br><div class="gmail_quote"><div><div class="h5">2012/11/1 Jevgeni Jurtsenko <span dir="ltr"><<a href="mailto:jevgenious@gmail.com" target="_blank">jevgenious@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div>Hello all,</div><div><br></div><div> Sorry for delay. I've been away for a while. Back to testing. I've tried regular version 2.6.5-1 and patched. Main thing is that both versions work until I reboot the OS, after that starting the nut fails with messages below. To make it run again I've to re-plug the usb cable. Hard-resetting the ups doesn't help either. Considering the fact to remotely monitor the devices it is quite inconvenient. Suppose there is I power fault and ups is drained out of power then the system won't come back online after power is restored. I've tried searching for a working way to model the "usb cable re-plug" on OS level with no luck.  Any help would be appreciated.  </div>


<div><br></div><div><div>Linux raspberrypi 3.2.27+ #160 PREEMPT Mon Sep 17 23:18:42 BST 2012 armv6l GNU/Linux</div></div><div><br></div><div><b>Version 2.6.5-1</b></div><div>USB communication subdriver 0.21</div><div>   0.000000     debug level is '5'</div>


<div>   0.008920     entering nutusb_open()</div><div>   0.013091     device 004 opened successfully</div><div>   0.015893     Can't claim POWERWARE USB interface: could not claim interface 0: Device or resource busy</div>


<div>   0.018484     Can't reset POWERWARE USB endpoint: could not clear/halt ep 129: Device or resource busy</div><div>   0.020807     device 004 opened successfully</div><div>   0.021753     Can't claim POWERWARE USB interface: could not claim interface 0: Device or resource busy</div>


<div>   0.022617     Can't reset POWERWARE USB endpoint: could not clear/halt ep 129: Device or resource busy</div><div>   0.023750     device 004 opened successfully</div><div>   0.024928     Can't claim POWERWARE USB interface: could not claim interface 0: Device or resource busy</div>


<div>   0.026070     Can't reset POWERWARE USB endpoint: could not clear/halt ep 129: Device or resource busy</div><div>   0.029099     device 004 opened successfully</div><div>   0.029412     Can't claim POWERWARE USB interface: could not claim interface 0: Device or resource busy</div>


<div>   0.029714     Can't reset POWERWARE USB endpoint: could not clear/halt ep 129: Device or resource busy</div><div>   0.030193     send_to_all: SETINFO device.type "ups"</div><div>   0.031387     send_to_all: SETINFO driver.version "2.6.4"</div>


<div>   0.031855     send_to_all: SETINFO driver.version.internal "0.26"</div><div>   0.032720     send_to_all: SETINFO <a href="http://driver.name" target="_blank">driver.name</a> "bcmxcp_usb"</div><div>

   0.033757     send_read_command: (4 bytes) => ab 01 31 23</div>
<div>   0.034906     entering get_answer(31)</div><div>   0.035409     get_answer: (0 bytes) =></div><div>   0.036298     send_read_command: (4 bytes) => ab 01 31 23</div><div>   0.039485     entering get_answer(31)</div>


<div>   0.040038     get_answer: (0 bytes) =></div><div>   0.040289     send_read_command: (4 bytes) => ab 01 31 23</div><div>   0.041718     entering get_answer(31)</div><div>   0.042514     get_answer: (0 bytes) =></div>


<div>   0.043435     send_read_command: (4 bytes) => ab 01 31 23</div><div>   0.045095     entering get_answer(31)</div><div>   0.045885     get_answer: (0 bytes) =></div><div>   0.046158     send_read_command: (4 bytes) => ab 01 31 23</div>


<div>   0.050026     entering get_answer(31)</div><div>   0.050552     get_answer: (0 bytes) =></div><div>   0.050785     Communications with UPS lost: Error executing command</div><div>   0.051043     Could not communicate with the ups: Device or resource busy</div>


<div>   0.051271     CLOSING</div><div><br></div><div><b>Patched version</b></div><div>2.225863     => usb_interrupt_read -16</div><div>   2.226680     => packet_loop (0, 0)</div><div>   2.227534     => bytes_read (0)</div>


<div>   2.227857     => usb_interrupt_read -16</div><div>   2.228667     => packet_loop (0, 0)</div><div>   2.229701     => bytes_read (0)</div><div>   2.230028     => usb_interrupt_read -16</div><div>   2.230809     => packet_loop (0, 0)</div>


<div>   2.233160     => bytes_read (0)</div><div>   2.234230     => usb_interrupt_read -16</div><div>   2.234546     => packet_loop (0, 0)</div><div>   2.234763     => bytes_read (0)</div><div>   2.235573     => usb_interrupt_read -16</div>


<div>   2.236373     => packet_loop (0, 0)</div><div>   2.237285     => bytes_read (0)</div><div>   2.237620     => usb_interrupt_read -16</div><div>   2.238418     => packet_loop (0, 0)</div><div>   2.239706     => bytes_read (0)</div>

</blockquote></div></div><div><br>strange that a reboot causes this kind of issues!<br>is this stable (i.e, reproduced upon each reboot)?<br><br>I would need the following, after a reboot (i.e, reproducing the above issue):<br>
- lsusb -v -d0x0592:0x0002<br>
- grep usb /var/log/syslog<br>- full trace, debug level 5, of the patched driver<br>- ps -efl | grep bcm<br><br>@Greg & Massimo: do you have the same behavior?<br><br></div></div>cheers,<br>Arnaud<span class="HOEnZb"><font color="#888888"><br>
-- <br>Network UPS Tools (NUT) Project Leader - <a href="http://www.networkupstools.org" target="_blank">http://www.networkupstools.org</a><br>
Debian Developer - <a href="http://www.debian.org" target="_blank">http://www.debian.org</a><br>Free Software Developer - <a href="http://arnaud.quette.fr" target="_blank">http://arnaud.quette.fr</a><br><br>
</font></span></blockquote></div><br></div>