On Sun, May 26, 2013 at 06:04:24PM +0200, Johan Hovold wrote:
> On Sun, May 26, 2013 at 01:00:51PM +0200, Andrew Lunn wrote:
> > +/*
> > + * mxuport_write_room
> > + *
> > + * Return how much space is available in the buffer.
> > + */
> > +static int mxuport_write_room(struct tty_struct *tty)
> > +{
> > +   struct usb_serial_port *port = tty->driver_data;
> > +   unsigned long flags;
> > +   int room;
> > +
> > +   spin_lock_irqsave(&port->lock, flags);
> > +   room = kfifo_avail(&port->write_fifo);
> > +   spin_unlock_irqrestore(&port->lock, flags);
> > +
> > +   dev_dbg(&port->dev, "%s - returns %d\n", __func__, room);
> > +   return room;
> > +}

....
 
> It seems it could be possible to reuse the generic write implementations
> of all functions but prepare_write_buffer above rather than the modified
> copies.

Hi Johan

If there a reason why usb_serial_generic_write_room() is not exported
as a GPL symbol. It looks like i should be able to use it once i sort
my 'fake' ports/endpoints out.

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

Reply via email to