From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Peter Hung <hpeter@gmail.com>, johan@kernel.org
Cc: gregkh@linuxfoundation.org, linux-usb@vger.kernel.org,
linux-kernel@vger.kernel.org, tom_tsai@fintek.com.tw,
peter_hong@fintek.com.tw,
Peter Hung <hpeter+linux_kernel@gmail.com>
Subject: Re: [PATCH v3 5/5] usb: serial: implement CMSPAR for F81232
Date: Wed, 28 Jan 2015 15:31:07 +0300 [thread overview]
Message-ID: <54C8D68B.6010607@cogentembedded.com> (raw)
In-Reply-To: <1422424712-7561-1-git-send-email-hpeter+linux_kernel@gmail.com>
Hello.
On 1/28/2015 8:58 AM, Peter Hung wrote:
> This patch implement CMSPAR in set_termios,
> and fix some warnning from checkpatch.pl
Please don't try to do 2 unrelated things in one patch.
> Signed-off-by: Peter Hung <hpeter+linux_kernel@gmail.com>
> ---
> drivers/usb/serial/f81232.c | 21 +++++++++++++++------
> 1 file changed, 15 insertions(+), 6 deletions(-)
> diff --git a/drivers/usb/serial/f81232.c b/drivers/usb/serial/f81232.c
> index 11a236b..79592d6 100644
> --- a/drivers/usb/serial/f81232.c
> +++ b/drivers/usb/serial/f81232.c
[...]
> @@ -361,12 +361,21 @@ static void f81232_set_termios(struct tty_struct *tty,
>
>
> if (cflag & PARENB) {
> - if (cflag & PARODD)
> - new_lcr |= UART_LCR_PARITY; /* odd */
> - else
> - new_lcr |= SERIAL_EVEN_PARITY; /* even */
> + if (cflag & CMSPAR) {
> + if (cflag & PARODD)
> + new_lcr |= (UART_LCR_PARITY | UART_LCR_SPAR);
> + else
> + new_lcr |= (SERIAL_EVEN_PARITY
> + | UART_LCR_SPAR);
> + } else {
> + if (cflag & PARODD)
> + new_lcr |= UART_LCR_PARITY; /* odd */
> + else
> + new_lcr |= SERIAL_EVEN_PARITY; /* even */
> + }
> }
>
> +
Not needed at all.
> if (cflag & CSTOPB)
> new_lcr |= UART_LCR_STOP;
> else
> @@ -445,7 +454,7 @@ static int f81232_open(struct tty_struct *tty, struct usb_serial_port *port)
>
> result = usb_submit_urb(port->interrupt_in_urb, GFP_KERNEL);
> if (result) {
> - dev_err(&port->dev, "failed submitting interrupt urb, error %d\n",
> + dev_err(&port->dev, "failed submitting urb, error %d\n",
What are you fixing here?
WBR, Sergei
next prev parent reply other threads:[~2015-01-29 1:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-28 5:58 [PATCH v3 5/5] usb: serial: implement CMSPAR for F81232 Peter Hung
2015-01-28 12:31 ` Sergei Shtylyov [this message]
2015-01-29 2:01 ` Peter Hung
2015-01-29 10:25 ` Sergei Shtylyov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54C8D68B.6010607@cogentembedded.com \
--to=sergei.shtylyov@cogentembedded.com \
--cc=gregkh@linuxfoundation.org \
--cc=hpeter+linux_kernel@gmail.com \
--cc=hpeter@gmail.com \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=peter_hong@fintek.com.tw \
--cc=tom_tsai@fintek.com.tw \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.