linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM
@ 2015-10-27  7:46 Saurabh Sengar
  2015-10-28 13:45 ` Peter Hurley
  0 siblings, 1 reply; 3+ messages in thread
From: Saurabh Sengar @ 2015-10-27  7:46 UTC (permalink / raw)
  To: gregkh, jslaby, linux-serial, linux-kernel; +Cc: Saurabh Sengar

use UPIO_MEM rather then SERIAL_IO_MEM.
both have the same value

Signed-off-by: Saurabh Sengar <saurabh.truth@gmail.com>
---
 drivers/tty/serial/sa1100.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/sa1100.c b/drivers/tty/serial/sa1100.c
index fd3d132..283c7e0 100644
--- a/drivers/tty/serial/sa1100.c
+++ b/drivers/tty/serial/sa1100.c
@@ -579,7 +579,7 @@ sa1100_verify_port(struct uart_port *port, struct serial_struct *ser)
 		ret = -EINVAL;
 	if (sport->port.irq != ser->irq)
 		ret = -EINVAL;
-	if (ser->io_type != SERIAL_IO_MEM)
+	if (ser->io_type != UPIO_MEM)
 		ret = -EINVAL;
 	if (sport->port.uartclk / 16 != ser->baud_base)
 		ret = -EINVAL;
-- 
1.9.1

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

* Re: [PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM
  2015-10-27  7:46 [PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM Saurabh Sengar
@ 2015-10-28 13:45 ` Peter Hurley
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Hurley @ 2015-10-28 13:45 UTC (permalink / raw)
  To: Saurabh Sengar; +Cc: gregkh, jslaby, linux-serial, linux-kernel

Hi Saurabh,

On 10/27/2015 03:46 AM, Saurabh Sengar wrote:
> use UPIO_MEM rather then SERIAL_IO_MEM.
> both have the same value
> 
> Signed-off-by: Saurabh Sengar <saurabh.truth@gmail.com>
> ---
>  drivers/tty/serial/sa1100.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/tty/serial/sa1100.c b/drivers/tty/serial/sa1100.c
> index fd3d132..283c7e0 100644
> --- a/drivers/tty/serial/sa1100.c
> +++ b/drivers/tty/serial/sa1100.c
> @@ -579,7 +579,7 @@ sa1100_verify_port(struct uart_port *port, struct serial_struct *ser)
>  		ret = -EINVAL;
>  	if (sport->port.irq != ser->irq)
>  		ret = -EINVAL;
> -	if (ser->io_type != SERIAL_IO_MEM)
> +	if (ser->io_type != UPIO_MEM)

SERIAL_IO_* io_type defines are the appropriate constants for the
struct serial_struct::io_type field. Both are defined in the
uapi header, include/uapi/linux/serial.h

UPIO_* io_type defines are the appropriate constants for the
struct uart_port::io_type field. Both are defined in the kernel
header, include/kernel/serial_core.h

I defined the UPIO_* io_types in terms of SERIAL_IO_* because
userspace breakage was occurring as contributors were changing
the UPIO_* constant values.


Regards,
Peter Hurley


>  		ret = -EINVAL;
>  	if (sport->port.uartclk / 16 != ser->baud_base)
>  		ret = -EINVAL;
> 

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

* Re: [PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM
       [not found] <[PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM>
@ 2015-10-28 14:52 ` Saurabh Sengar
  0 siblings, 0 replies; 3+ messages in thread
From: Saurabh Sengar @ 2015-10-28 14:52 UTC (permalink / raw)
  To: peter, linux-serial, linux-kernel

Thank you Peter, for your explanation.

Regards,
Saurabh

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

end of thread, other threads:[~2015-10-28 14:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-27  7:46 [PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM Saurabh Sengar
2015-10-28 13:45 ` Peter Hurley
     [not found] <[PATCH] tty: serial: sa1100.c: use UPIO_MEM rather than SERIAL_IO_MEM>
2015-10-28 14:52 ` Saurabh Sengar

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).