[not subscribed to either list, cc: me please]
I got these today while trying to print to my HP Deskjet 845c USB printer.
I'm running 2.5.5-dj2. I think the first one came from when I booted,
and the second one came from when I unplugged the USB cable to my
printer and plugged it back in. My motherboard is a K7T Turbo, VIA KT133
chipset (UHCI controller). I'm using the alternate UHCI driver (JE), I
will try recompiling with the normal driver later and see if the problem
still occurs. (this is the first time I've really played around with the
USB drivers!) The ksymoops outputs, my dmesg, and my
/proc/dev/usb/devices are attached.
--
James Curbo <[email protected]> <[email protected]>
Undergraduate Computer Science, Henderson State University
PGP Keys at <http://reddie.henderson.edu/~curboj/>
Public Keys: PGP - 1024/0x76E2061B GNUPG - 1024D/0x3EEA7288
On Tue, Mar 05, 2002 at 12:46:04PM -0600, James Curbo wrote:
> [not subscribed to either list, cc: me please]
>
> I got these today while trying to print to my HP Deskjet 845c USB printer.
> I'm running 2.5.5-dj2.
Can you reproduce these with the 2.4.6-pre2 kernel?
thanks,
greg k-h
On Mar 05, Greg KH wrote:
> Can you reproduce these with the 2.4.6-pre2 kernel?
>
> thanks,
>
> greg k-h
I presume you mean 2.5.6-pre2, as 2.4 is way past that.. I will try it
tonight after I get in from work...
--
James Curbo <[email protected]> <[email protected]>
Undergraduate Computer Science, Henderson State University
PGP Keys at <http://reddie.henderson.edu/~curboj/>
Public Keys: PGP - 1024/0x76E2061B GNUPG - 1024D/0x3EEA7288
On Tue, Mar 05, 2002 at 01:33:17PM -0600, James Curbo wrote:
> On Mar 05, Greg KH wrote:
> > Can you reproduce these with the 2.4.6-pre2 kernel?
> >
> > thanks,
> >
> > greg k-h
>
> I presume you mean 2.5.6-pre2, as 2.4 is way past that.. I will try it
> tonight after I get in from work...
Yes, sorry about that :)
greg k-h
OK, after some compilation problems with 2.5.6-pre2 (ide-scsi wouldn't
compile, then OSS sound had an error too.. both not essential to me), I
got it up, and still got a panic. It's attached. Should I try the other
UHCI driver now?
On Mar 05, Greg KH wrote:
> On Tue, Mar 05, 2002 at 01:33:17PM -0600, James Curbo wrote:
> > On Mar 05, Greg KH wrote:
> > > Can you reproduce these with the 2.4.6-pre2 kernel?
> > >
> > > thanks,
> > >
> > > greg k-h
> >
> > I presume you mean 2.5.6-pre2, as 2.4 is way past that.. I will try it
> > tonight after I get in from work...
>
> Yes, sorry about that :)
>
> greg k-h
--
James Curbo <[email protected]> <[email protected]>
Undergraduate Computer Science, Henderson State University
PGP Keys at <http://reddie.henderson.edu/~curboj/>
Public Keys: PGP - 1024/0x76E2061B GNUPG - 1024D/0x3EEA7288
Ah, I tried it with 2.5.6-pre2 and usb-uhci.. still got a panic, when I
tried to print to the printer (which is what I was doing before too)
Also, got these in my kernel log...
usb-uhci.c: ENXIO 80000200, flags 0, urb c1523ac0, burb c1523a40
usb-uhci.c: ENXIO 80000200, flags 0, urb d7983c40, burb d7983bc0
usb-uhci.c: ENXIO 80000200, flags 0, urb d7983c40, burb d7983bc0
usb-uhci.c: ENXIO 80000280, flags 0, urb d7831540, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d7831540, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d7831540, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2840, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2840, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2840, burb d7983bc0
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2ac0, burb d7983bc0
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2ac0, burb d7983bc0
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2ac0, burb d7983bc0
usb-uhci.c: ENXIO 80000280, flags 0, urb d76b2ac0, burb d7983bc0
Does that mean anything to you guys?
--
James Curbo <[email protected]> <[email protected]>
Undergraduate Computer Science, Henderson State University
PGP Keys at <http://reddie.henderson.edu/~curboj/>
Public Keys: PGP - 1024/0x76E2061B GNUPG - 1024D/0x3EEA7288
On Tue, 5 Mar 2002, James Curbo wrote:
> Ah, I tried it with 2.5.6-pre2 and usb-uhci.. still got a panic, when I
> tried to print to the printer (which is what I was doing before too)
> Also, got these in my kernel log...
>
> usb-uhci.c: ENXIO 80000200, flags 0, urb c1523ac0, burb c1523a40
Apparently there were several reports of such ENXIO errors recently
triggered by a spinlock issue in hid-core.c - IIRC you have an usb-mouse
connected and input loaded as well. If so, this might solve it:
<http://marc.theaimsgroup.com/?l=linux-usb-devel&m=101523276704203&w=2>
Martin
On Tue, Mar 05, 2002 at 11:03:49PM -0600, James Curbo wrote:
> Ah, I tried it with 2.5.6-pre2 and usb-uhci.. still got a panic, when I
> tried to print to the printer (which is what I was doing before too)
> Also, got these in my kernel log...
Crud, missed another driver. Can you please try the patch below and let
me know if it fixes the problem for you?
thanks,
greg k-h
diff -Nru a/drivers/usb/printer.c b/drivers/usb/printer.c
--- a/drivers/usb/printer.c Wed Mar 6 22:46:17 2002
+++ b/drivers/usb/printer.c Wed Mar 6 22:46:17 2002
@@ -91,7 +91,7 @@
struct usb_device *dev; /* USB device */
devfs_handle_t devfs; /* devfs device */
struct semaphore sem; /* locks this struct, especially "dev" */
- struct urb readurb, writeurb; /* The urbs */
+ struct urb *readurb, *writeurb; /* The urbs */
wait_queue_head_t wait; /* Zzzzz ... */
int readcount; /* Counter for reads */
int ifnum; /* Interface number */
@@ -253,15 +253,15 @@
usblp->used = 1;
file->private_data = usblp;
- usblp->writeurb.transfer_buffer_length = 0;
- usblp->writeurb.status = 0;
+ usblp->writeurb->transfer_buffer_length = 0;
+ usblp->writeurb->status = 0;
usblp->wcomplete = 1; /* we begin writeable */
usblp->rcomplete = 0;
if (usblp->bidir) {
usblp->readcount = 0;
- usblp->readurb.dev = usblp->dev;
- if (usb_submit_urb(&usblp->readurb, GFP_KERNEL) < 0) {
+ usblp->readurb->dev = usblp->dev;
+ if (usb_submit_urb(usblp->readurb, GFP_KERNEL) < 0) {
retval = -EIO;
usblp->used = 0;
file->private_data = NULL;
@@ -278,8 +278,10 @@
usblp_table [usblp->minor] = NULL;
info ("usblp%d: removed", usblp->minor);
- kfree (usblp->writeurb.transfer_buffer);
+ kfree (usblp->writeurb->transfer_buffer);
kfree (usblp->device_id_string);
+ usb_free_urb(usblp->writeurb);
+ usb_free_urb(usblp->readurb);
kfree (usblp);
}
@@ -292,8 +294,8 @@
usblp->used = 0;
if (usblp->dev) {
if (usblp->bidir)
- usb_unlink_urb(&usblp->readurb);
- usb_unlink_urb(&usblp->writeurb);
+ usb_unlink_urb(usblp->readurb);
+ usb_unlink_urb(usblp->writeurb);
up(&usblp->sem);
} else /* finish cleanup from disconnect */
usblp_cleanup (usblp);
@@ -306,8 +308,8 @@
{
struct usblp *usblp = file->private_data;
poll_wait(file, &usblp->wait, wait);
- return ((!usblp->bidir || usblp->readurb.status == -EINPROGRESS) ? 0 : POLLIN | POLLRDNORM)
- | (usblp->writeurb.status == -EINPROGRESS ? 0 : POLLOUT | POLLWRNORM);
+ return ((!usblp->bidir || usblp->readurb->status == -EINPROGRESS) ? 0 : POLLIN | POLLRDNORM)
+ | (usblp->writeurb->status == -EINPROGRESS ? 0 : POLLOUT | POLLWRNORM);
}
static int usblp_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg)
@@ -423,12 +425,12 @@
return -ENODEV;
}
- if (usblp->writeurb.status != 0) {
+ if (usblp->writeurb->status != 0) {
if (usblp->quirks & USBLP_QUIRK_BIDIR) {
if (!usblp->wcomplete)
err("usblp%d: error %d writing to printer",
- usblp->minor, usblp->writeurb.status);
- err = usblp->writeurb.status;
+ usblp->minor, usblp->writeurb->status);
+ err = usblp->writeurb->status;
} else
err = usblp_check_status(usblp, err);
up (&usblp->sem);
@@ -440,23 +442,23 @@
continue;
}
- writecount += usblp->writeurb.transfer_buffer_length;
- usblp->writeurb.transfer_buffer_length = 0;
+ writecount += usblp->writeurb->transfer_buffer_length;
+ usblp->writeurb->transfer_buffer_length = 0;
if (writecount == count) {
up (&usblp->sem);
break;
}
- usblp->writeurb.transfer_buffer_length = (count - writecount) < USBLP_BUF_SIZE ?
- (count - writecount) : USBLP_BUF_SIZE;
+ usblp->writeurb->transfer_buffer_length = (count - writecount) < USBLP_BUF_SIZE ?
+ (count - writecount) : USBLP_BUF_SIZE;
- if (copy_from_user(usblp->writeurb.transfer_buffer, buffer + writecount,
- usblp->writeurb.transfer_buffer_length)) return -EFAULT;
+ if (copy_from_user(usblp->writeurb->transfer_buffer, buffer + writecount,
+ usblp->writeurb->transfer_buffer_length)) return -EFAULT;
- usblp->writeurb.dev = usblp->dev;
+ usblp->writeurb->dev = usblp->dev;
usblp->wcomplete = 0;
- if (usb_submit_urb(&usblp->writeurb, GFP_KERNEL)) {
+ if (usb_submit_urb(usblp->writeurb, GFP_KERNEL)) {
count = -EIO;
up (&usblp->sem);
break;
@@ -516,29 +518,29 @@
goto done;
}
- if (usblp->readurb.status) {
+ if (usblp->readurb->status) {
err("usblp%d: error %d reading from printer",
- usblp->minor, usblp->readurb.status);
- usblp->readurb.dev = usblp->dev;
+ usblp->minor, usblp->readurb->status);
+ usblp->readurb->dev = usblp->dev;
usblp->readcount = 0;
- usb_submit_urb(&usblp->readurb, GFP_KERNEL);
+ usb_submit_urb(usblp->readurb, GFP_KERNEL);
count = -EIO;
goto done;
}
- count = count < usblp->readurb.actual_length - usblp->readcount ?
- count : usblp->readurb.actual_length - usblp->readcount;
+ count = count < usblp->readurb->actual_length - usblp->readcount ?
+ count : usblp->readurb->actual_length - usblp->readcount;
- if (copy_to_user(buffer, usblp->readurb.transfer_buffer + usblp->readcount, count)) {
+ if (copy_to_user(buffer, usblp->readurb->transfer_buffer + usblp->readcount, count)) {
count = -EFAULT;
goto done;
}
- if ((usblp->readcount += count) == usblp->readurb.actual_length) {
+ if ((usblp->readcount += count) == usblp->readurb->actual_length) {
usblp->readcount = 0;
- usblp->readurb.dev = usblp->dev;
+ usblp->readurb->dev = usblp->dev;
usblp->rcomplete = 0;
- if (usb_submit_urb(&usblp->readurb, GFP_KERNEL)) {
+ if (usb_submit_urb(usblp->readurb, GFP_KERNEL)) {
count = -EIO;
goto done;
}
@@ -668,24 +670,42 @@
init_waitqueue_head(&usblp->wait);
+ usblp->writeurb = usb_alloc_urb(0, GFP_KERNEL);
+ if (!usblp->writeurb) {
+ err("out of memory");
+ kfree(usblp);
+ return NULL;
+ }
+ usblp->readurb = usb_alloc_urb(0, GFP_KERNEL);
+ if (!usblp->readurb) {
+ err("out of memory");
+ usb_free_urb(usblp->writeurb);
+ kfree(usblp);
+ return NULL;
+ }
+
if (!(buf = kmalloc(USBLP_BUF_SIZE * (bidir ? 2 : 1), GFP_KERNEL))) {
err("out of memory");
+ usb_free_urb(usblp->writeurb);
+ usb_free_urb(usblp->readurb);
kfree(usblp);
return NULL;
}
if (!(usblp->device_id_string = kmalloc(DEVICE_ID_SIZE, GFP_KERNEL))) {
err("out of memory");
+ usb_free_urb(usblp->writeurb);
+ usb_free_urb(usblp->readurb);
kfree(usblp);
kfree(buf);
return NULL;
}
- FILL_BULK_URB(&usblp->writeurb, dev, usb_sndbulkpipe(dev, epwrite->bEndpointAddress),
+ FILL_BULK_URB(usblp->writeurb, dev, usb_sndbulkpipe(dev, epwrite->bEndpointAddress),
buf, 0, usblp_bulk_write, usblp);
if (bidir)
- FILL_BULK_URB(&usblp->readurb, dev, usb_rcvbulkpipe(dev, epread->bEndpointAddress),
+ FILL_BULK_URB(usblp->readurb, dev, usb_rcvbulkpipe(dev, epread->bEndpointAddress),
buf + USBLP_BUF_SIZE, USBLP_BUF_SIZE, usblp_bulk_read, usblp);
/* Get the device_id string if possible. FIXME: Could make this kmalloc(length). */
@@ -737,9 +757,9 @@
lock_kernel();
usblp->dev = NULL;
- usb_unlink_urb(&usblp->writeurb);
+ usb_unlink_urb(usblp->writeurb);
if (usblp->bidir)
- usb_unlink_urb(&usblp->readurb);
+ usb_unlink_urb(usblp->readurb);
if (!usblp->used)
usblp_cleanup (usblp);
OK, I applied the patch; I don't get the panic anymore. I'm still
getting kernel messages like this:
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4840, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4840, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4840, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c59c0, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c59c0, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c59c0, burb d79b1d40
usbfs: USBDEVFS_CONTROL failed dev 2 rqt 128 rq 6 len 18 ret -6
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c5b40, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c5b40, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c5b40, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d74c5b40, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4640, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4640, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4640, burb d79b1d40
usb-uhci.c: ENXIO 80000280, flags 0, urb d76c4640, burb d79b1d40
Also, while now I don't get the panic when I try to print, it still
doesn't print.. CUPS says "USB port busy, retrying in 30 seconds"
Unfortunately I can't remember what kernel version I was using when it
worked last.
On Mar 06, Greg KH wrote:
> Crud, missed another driver. Can you please try the patch below and let
> me know if it fixes the problem for you?
>
> thanks,
>
> greg k-h
--
James Curbo <[email protected]> <[email protected]>
Undergraduate Computer Science, Henderson State University
PGP Keys at <http://reddie.henderson.edu/~curboj/>
Public Keys: PGP - 1024/0x76E2061B GNUPG - 1024D/0x3EEA7288