Re: USB device reset while printing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 15 Mar 2012, Wolfgang Rosenauer wrote:

> Alan,
> 
> Am 14.03.2012 21:49, schrieb Alan Stern:
> > Okay, I see what the problem is.  Your printer has a mass-storage 
> > interface -- a card reader or something of the sort, right?
> 
> Yes, indeed it has a builtin card reader.
> 
> > Starting in 3.1 the kernel continually polls this mass-storage
> > interface, looking for media-change events (such as insertion of a
> > memory card).  Right at the time you began printing, the mass-storage
> > interface stopped responding to these polls.  After 30 seconds the
> > computer realized something was wrong, so it reset the printer.  This
> > reset interfered with the printing, so the second page never got
> > completed.
> > 
> > If you don't care about that card reader or whatever it is, you can 
> > prevent the kernel from polling it.  The command to use is:
> > 
> > 	echo 0 >/sys/block/sdX/events_poll_msecs
> 
> This fixes my printing issues.
> 
> Thanks for looking into it.

Good, you're welcome.

> I'm wondering why that issue is not more widespread. I would have
> expected that many printers have features like this nowadays (but then
> again the specific behaviour is HP Officejet only).

I don't know the answer.  Maybe other printer models don't have the
builtin card reader.  Or maybe they do, but the card reader continues
to work properly while printing is in progress.

> Is there no other technical solution to address this? Something like "do
> never reset a USB device which is currently in use"?

That would defeat the purpose, wouldn't it?  The reason for resetting a
USB device is because it has stopped working and therefore can't be
used; the reset is necessary to get it going again.

The real problem here is the bug in the printer's card reader.  As far 
as I can see, the only way to avoid problems is to avoid communicating 
with the card reader in the first place.  Unfortunately there's no way 
to reset the card reader without resetting the entire printer.

> Sorry I don't know anything about kernel components and USB stuff just
> thinking out loud that this does not look like a user compatible
> behaviour ;-)

If more printers show up with the same sort of problem, or lots of
people using the same model HP Officejet run across the same thing,
adding a new rule to the udev distribution may be the best answer.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux