Giant on serial devices in USB2?

Andrew Thompson thompsa at FreeBSD.org
Tue Dec 23 12:29:42 PST 2008


On Tue, Dec 23, 2008 at 07:56:21PM +0100, Hans Petter Selasky wrote:
> On Tuesday 23 December 2008, Ed Schouten wrote:
> > Hello HPS, others,
> >
> > I was just running a grep on the USB2 code and saw the following:
> >
> > $ grep -r Giant sys/dev/usb2/serial | wc -l
> >       70
> >
> > WHat's the exact reason USB2 still uses Giant on TTY related drivers?
> > Couldn't it just use the per-TTY mutex? If not, maybe it should create a
> > custom system-wide mutex, instead of using Giant?
> >
> > Yours,
> 
> Hi,
> 
> I don't have all those USB devices at hand, so I simply cannot test if the 
> driver still works without Giant.
> 
> BTW: It should be trivial to remove Giant from the drivers. I think Andrew 
> Thompson has already done some drivers Giant-free.

Its just a mechanical change, it works fine for the couple of driver I
have converted.

Andrew


More information about the freebsd-usb mailing list