On Tue, Feb 17, 2015 at 10:45:11PM -0500, Nicolas PLANEL wrote: > From 467794e88dc08f61e1068c510c97baa9a12b841d Mon Sep 17 00:00:00 2001 > From: Nicolas PLANEL <nicolas.planel@xxxxxxxxxxxx> > Date: Tue, 17 Feb 2015 00:59:14 -0500 > Subject: [PATCH] USB: ch341: set tty baud speed according to tty struct Your patch is still whitespace damaged. Consider using git send-email for sending. Try sending it to yourself first and run scritps/checkpatch.pl on the received mail to make sure you got it right. > The ch341_set_baudrate() function initialize the device baud speed according > to the value on priv->baud_rate. By default the ch341_open() set it to a > hardcoded value (DEFAULT_BAUD_RATE 9600). Unfortunately, the tty_struct is > not initialized with the same default value. (usually 56700) > > This means that the tty_struct and the device baud rate generator are not > synchronized after opening the port. Good catch. > Fixup is elementary simple by calling tty_get_baud_rate() and > tty_encode_baud_rate() helper to sync up the baud rate during the > ch341_open() call. I believe the fix should be implemented slightly differently however. Most usb-serial driver call set_termios from open to handle this issue. It looks like you could simply replace the calls to set baudrate and "handshake" in open with ch341_set_termios(tty, port, NULL); Care to send an updated v2 of your patch? Remember to include the patch revision in the subject line when resending (i.e. "[PATCH v2]"). Thanks, Johan -- 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