Bug 117025 - multimedia/pwcbsd: Pwcbsd-1.4.0 + New USBStack not working
Summary: multimedia/pwcbsd: Pwcbsd-1.4.0 + New USBStack not working
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: FreeBSD Ports Bugs (Mailing List)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-10-08 18:00 UTC by ganael.laplanche
Modified: 2008-04-28 10:54 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ganael.laplanche 2007-10-08 18:00:11 UTC
Hi,

(Not sure if it is USB or PwcBSD related)

I've just installed the new USB Stack and recompiled PwcBSD. My webcam (Philips SPC900NC) does not work anymore, here are the logs shown in /var/log/messages :

When I plug the webcam :

Oct  8 18:41:45 home kernel: usbd_fill_iface_data: invalid wMaxPacketSize, addr=125!
Oct  8 18:41:45 home kernel: pwc0: Philips product 0x0329, rev 1.10/0.03, addr 125
Oct  8 18:41:45 home kernel: pwc0: Philips SPC900NC USB webcam
Oct  8 18:41:46 home kernel: pwc0: This camera is equipped with a Sony CCD sensor + TDA8787 (32)

When I start pwcview, a small green screen appears and then disappears. Here are the logs :

Oct  8 18:51:54 home kernel: pwc decode_size = 3.
Oct  8 18:51:54 home kernel: pwc Using alternate setting 2.
Oct  8 18:51:54 home kernel: pwc frame_size=57600, vframes=5, vsize=3, vsnapshot=0, vbandlength=960
Oct  8 18:51:54 home kernel: usbd_transfer_done: short transfer actlen(0) < len(7680)
Oct  8 18:51:55 home last message repeated 20 times
Oct  8 18:51:55 home kernel: pwc0: Too many ISOC errors, bailing out.

Feel free to ask for any further details...

Fix: 

No fix known.
How-To-Repeat: Install the new stack from : http://www.turbocat.net/~hselasky/usb4bsd and update pwcBSD from /usr/ports/multimedia/pwcbsd.
Comment 1 raaf 2007-10-09 18:47:29 UTC
Hello,

The pwcbsd port has just been updated to 1.4.1 which fixes a
similar problem the driver has with uhci controllers on current.

Can you check if this new version fixes your problem with the
HPS stack?
Comment 2 ganael.laplanche 2007-10-09 19:43:57 UTC
On Tue, 09 Oct 2007 19:47:29 +0200, Raaf wrote
> Hello,
> 
> The pwcbsd port has just been updated to 1.4.1 which fixes a
> similar problem the driver has with uhci controllers on current.
> 
> Can you check if this new version fixes your problem with the
> HPS stack?

Hi, 

Thanks for your anwser !

Well, same message while plugging the cam :

Oct  9 20:38:11 home kernel: usbd_fill_iface_data: invalid wMaxPacketSize, addr=125!
[...]

But now, I can start pwcview and see myself (is /that/ me ?). Unfortunately, I
cannot set fps (-f option). Any attempt leads to this message :

% pwcview -f 25                                                                
                                                                      
Failed to set webcam to: 320x240 (sif) at 25 fps (Resource deadlock avoided)

in /var/log/messages :
Oct  9 20:42:05 home kernel: pwc0: Failed to set alternate interface to: 6 (11)

Strange :/

Ganaël LAPLANCHE
ganael.laplanche@martymac.com
http://www.martymac.com
Comment 3 raaf 2007-10-10 04:32:06 UTC
Ganael LAPLANCHE wrote:
> On Tue, 09 Oct 2007 19:47:29 +0200, Raaf wrote
>> Hello,
>>
>> The pwcbsd port has just been updated to 1.4.1 which fixes a
>> similar problem the driver has with uhci controllers on current.
>>
>> Can you check if this new version fixes your problem with the
>> HPS stack?
> 
> Hi, 
> 
> Thanks for your anwser !
> 
> Well, same message while plugging the cam :
> 
> Oct  9 20:38:11 home kernel: usbd_fill_iface_data: invalid wMaxPacketSize, addr=125!
> [...]
> 
> But now, I can start pwcview and see myself (is /that/ me ?). Unfortunately, I
> cannot set fps (-f option). Any attempt leads to this message :
> 
> % pwcview -f 25                                                                
>                                                                       
> Failed to set webcam to: 320x240 (sif) at 25 fps (Resource deadlock avoided)
> 
> in /var/log/messages :
> Oct  9 20:42:05 home kernel: pwc0: Failed to set alternate interface to: 6 (11)
> 

11 is the error code returned by the call to usbd_set_interface().

With the FreeBSD USB stack 11 means USBD_NO_POWER. I don't know if
it's the same with the HPS stack.

Anyway, since the pwcbsd driver was designed for the official
FreeBSD USB stack and not for the HPS USB stack, i can not really
help you with it.

In fact i'm surprised that you somehow managed to get the pwcbsd
driver to compile and run with the HPS stack.
Comment 4 ganael.laplanche 2007-10-10 07:56:10 UTC
> In fact i'm surprised that you somehow managed to get the pwcbsd
> driver to compile and run with the HPS stack.

No special magic here :) I just installed the new stack and portupgrade'ed
pwcbsd ; everything went fine during compilation...

Ganaël LAPLANCHE
ganael.laplanche@martymac.com
http://www.martymac.com
Comment 5 hselasky 2007-10-10 18:47:51 UTC
Hi Ganael Laplanche !

The error codes that my USB stack return are not the same as the ones you find 
in the official USB stack on FreeBSD. You will have to 
check "/sys/dev/usb/usb_subr.h" to find out what this actually means. See 
the "USBD_STATUS" define.

I suspect that you downloaded and installed one of the tarballs. The tarballs 
have not been updated for a while hence so much is going on in the USB 
project.

If you had installed from the SVN repo, which is much more up to date, I don't 
think that Pwcbsd will compile any more, due to USB API changes.

Once the USB stack has settled, I will gladly assist anyone that needs help 
upgrading their USB drivers.

--HPS
Comment 6 Remko Lodder freebsd_committer 2007-10-10 19:28:18 UTC
Class Changed
From-To: sw-bug->Change-Request

After discussing this with HPS, this is found to be a change-request 
which should have the goal go upgrade pwcbsd, reflect that into the 
ticket. 


Comment 7 Remko Lodder freebsd_committer 2007-10-10 19:28:18 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-ports-bugs

After discussing this with HPS, this is found to be a change-request 
which should have the goal go upgrade pwcbsd, reflect that into the 
ticket.
Comment 8 ganael.laplanche 2007-10-11 07:50:21 UTC
On Wed, 10 Oct 2007 19:47:51 +0200, Hans Petter Selasky wrote
> Hi Ganael Laplanche !
> 
> I suspect that you downloaded and installed one of the tarballs. The 
> tarballs have not been updated for a while hence so much is going on 
> in the USB project.

Yeah, you're right, I have downloaded the v1.6.1 snapshot.

> If you had installed from the SVN repo, which is much more up to date, 
> I don't think that Pwcbsd will compile any more, due to USB API changes.

I'll try SVN version.

(this PR may be suspended by now. I'll submit a followup ASAP to tell how
compilation went).

Thanks a lot for your help !
Best regards,

Ganaël LAPLANCHE
ganael.laplanche@martymac.com
http://www.martymac.com
Comment 9 Martin Wilke freebsd_committer 2008-04-28 10:54:49 UTC
State Changed
From-To: open->closed

close by submitter request.