linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build warning after merge of the tty tree
@ 2015-03-10  5:28 Stephen Rothwell
  2015-03-10  8:23 ` Uwe Kleine-König
  2015-03-10  8:31 ` [PATCH] fixup! serial: imx: add support for half duplex rs485 Uwe Kleine-König
  0 siblings, 2 replies; 5+ messages in thread
From: Stephen Rothwell @ 2015-03-10  5:28 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-next, linux-kernel, Uwe Kleine-König

[-- Attachment #1: Type: text/plain, Size: 506 bytes --]

Hi Greg,

After merging the tty tree, today's linux-next build (arm
multi_v7_defconfig) produced this warning:

drivers/tty/serial/imx.c: In function 'imx_set_termios':
drivers/tty/serial/imx.c:1301:7: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
    if (port->rs485.flags & SER_RS485_ENABLED)
       ^

Introduced by commit 17b8f2a3fdca ("serial: imx: add support for half
duplex rs485").

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: linux-next: build warning after merge of the tty tree
  2015-03-10  5:28 linux-next: build warning after merge of the tty tree Stephen Rothwell
@ 2015-03-10  8:23 ` Uwe Kleine-König
  2015-03-10  9:19   ` Greg KH
  2015-03-10  8:31 ` [PATCH] fixup! serial: imx: add support for half duplex rs485 Uwe Kleine-König
  1 sibling, 1 reply; 5+ messages in thread
From: Uwe Kleine-König @ 2015-03-10  8:23 UTC (permalink / raw)
  To: Stephen Rothwell, linux-next, linux-kernel; +Cc: Greg KH

Hello Greg,

On Tue, Mar 10, 2015 at 04:28:16PM +1100, Stephen Rothwell wrote:
> After merging the tty tree, today's linux-next build (arm
> multi_v7_defconfig) produced this warning:
> 
> drivers/tty/serial/imx.c: In function 'imx_set_termios':
> drivers/tty/serial/imx.c:1301:7: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
>     if (port->rs485.flags & SER_RS485_ENABLED)
>        ^
> 
> Introduced by commit 17b8f2a3fdca ("serial: imx: add support for half
> duplex rs485").
should I send a fixed commit or do you prefer an incremental change?

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH] fixup! serial: imx: add support for half duplex rs485
  2015-03-10  5:28 linux-next: build warning after merge of the tty tree Stephen Rothwell
  2015-03-10  8:23 ` Uwe Kleine-König
@ 2015-03-10  8:31 ` Uwe Kleine-König
  2015-03-10  9:19   ` Greg KH
  1 sibling, 1 reply; 5+ messages in thread
From: Uwe Kleine-König @ 2015-03-10  8:31 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-next, linux-kernel

---
 drivers/tty/serial/imx.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
index ddfb672d0152..e9102eba49c4 100644
--- a/drivers/tty/serial/imx.c
+++ b/drivers/tty/serial/imx.c
@@ -1298,7 +1298,7 @@ imx_set_termios(struct uart_port *port, struct ktermios *termios,
 		if (sport->have_rtscts) {
 			ucr2 &= ~UCR2_IRTS;
 
-			if (port->rs485.flags & SER_RS485_ENABLED)
+			if (port->rs485.flags & SER_RS485_ENABLED) {
 				/*
 				 * RTS is mandatory for rs485 operation, so keep
 				 * it under manual control and keep transmitter
@@ -1307,8 +1307,9 @@ imx_set_termios(struct uart_port *port, struct ktermios *termios,
 				if (!(port->rs485.flags &
 				      SER_RS485_RTS_AFTER_SEND))
 					ucr2 |= UCR2_CTS;
-			else
+			} else {
 				ucr2 |= UCR2_CTSC;
+			}
 
 		} else {
 			termios->c_cflag &= ~CRTSCTS;
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: linux-next: build warning after merge of the tty tree
  2015-03-10  8:23 ` Uwe Kleine-König
@ 2015-03-10  9:19   ` Greg KH
  0 siblings, 0 replies; 5+ messages in thread
From: Greg KH @ 2015-03-10  9:19 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: Stephen Rothwell, linux-next, linux-kernel

On Tue, Mar 10, 2015 at 09:23:18AM +0100, Uwe Kleine-König wrote:
> Hello Greg,
> 
> On Tue, Mar 10, 2015 at 04:28:16PM +1100, Stephen Rothwell wrote:
> > After merging the tty tree, today's linux-next build (arm
> > multi_v7_defconfig) produced this warning:
> > 
> > drivers/tty/serial/imx.c: In function 'imx_set_termios':
> > drivers/tty/serial/imx.c:1301:7: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
> >     if (port->rs485.flags & SER_RS485_ENABLED)
> >        ^
> > 
> > Introduced by commit 17b8f2a3fdca ("serial: imx: add support for half
> > duplex rs485").
> should I send a fixed commit or do you prefer an incremental change?

It's already in my tree, so I need an add-on patch.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] fixup! serial: imx: add support for half duplex rs485
  2015-03-10  8:31 ` [PATCH] fixup! serial: imx: add support for half duplex rs485 Uwe Kleine-König
@ 2015-03-10  9:19   ` Greg KH
  0 siblings, 0 replies; 5+ messages in thread
From: Greg KH @ 2015-03-10  9:19 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: linux-next, linux-kernel

On Tue, Mar 10, 2015 at 09:31:09AM +0100, Uwe Kleine-König wrote:
> ---
>  drivers/tty/serial/imx.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)

Same errors as your other patch :(

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-03-10  9:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-10  5:28 linux-next: build warning after merge of the tty tree Stephen Rothwell
2015-03-10  8:23 ` Uwe Kleine-König
2015-03-10  9:19   ` Greg KH
2015-03-10  8:31 ` [PATCH] fixup! serial: imx: add support for half duplex rs485 Uwe Kleine-König
2015-03-10  9:19   ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).