Re: [PATCH v5 2/2] usb-serial: Moxa UPORT 12XX/14XX/16XX driver

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

 



Hi Johan

Thanks for the quick response.

> > +static int mxuport_dtr(struct usb_serial_port *port, int on)
> > +{
> > +	struct mxuport_port *mxport = usb_get_serial_port_data(port);
> > +	int err;
> > +
> > +	mutex_lock(&mxport->mutex);
> > +
> > +	if (on)
> > +		mxport->mcr_state |= UART_MCR_DTR;
> > +	else
> > +		mxport->mcr_state &= ~UART_MCR_DTR;
> > +
> > +	err = mxuport_set_mcr(port, mxport->mcr_state);
> > +
> > +	mutex_unlock(&mxport->mutex);
> > +
> > +	return err;
> > +}
> 
> You should probably use SET_DTR (and rename the function
> mxuport_set_dtr).

I considered mxuport_set_dtr(), but it does not really fit with the
usb-serial naming. tty_port_operations has dtr_rts, not set_dtr_rts.
usb_serial_driver also has dtr_rts, not set_dtr_rts.

	  Andrew
--
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