[PATCH] RS485 on Cris: use global value of TIOCSRS485

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

 



Hi Jesper, Hi Mikael,

	    the following patch sets the value of TIOCSRS485 on Cris
equal to the value of all other architectures (as currently is for
TIOCGRS485).

With this patch, TIOCSRS485 gets the same value across all
architectures, making maintenance and portability of user-level code
easier.

Best regards,

	Claudio


RS485: use global value of TIOCSRS485 (i.e. 0x546F) on Cris.

Signed-off-by: Claudio Scordino <claudio@xxxxxxxxxxxxxxx>
---
 arch/cris/include/asm/ioctls.h |    2 +-
 drivers/serial/crisv10.c       |    5 +++++
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/arch/cris/include/asm/ioctls.h b/arch/cris/include/asm/ioctls.h
index 488fbb3..2c15ff8 100644
--- a/arch/cris/include/asm/ioctls.h
+++ b/arch/cris/include/asm/ioctls.h
@@ -4,7 +4,7 @@
 #define TIOCSERGSTRUCT	0x5458 /* For debugging only */
 #define TIOCSERSETRS485	0x5461  /* enable rs-485 (deprecated) */
 #define TIOCSERWRRS485	0x5462  /* write rs-485 */
-#define TIOCSRS485	0x5463  /* enable rs-485 */
+#define TIOCSRS485DEPR	0x5463  /* enable rs-485 (deprecated) */
 
 #include <asm-generic/ioctls.h>
 
diff --git a/drivers/serial/crisv10.c b/drivers/serial/crisv10.c
index bcc31f2..29bd418 100644
--- a/drivers/serial/crisv10.c
+++ b/drivers/serial/crisv10.c
@@ -3717,6 +3717,11 @@ rs_ioctl(struct tty_struct *tty, struct file * file,
 		return e100_enable_rs485(tty, &rs485data);
 	}
 
+	case TIOCSRS485DEPR:
+	{
+		printk(KERN_DEBUG "The use of this ioctl is deprecated. Use TIOCSRS485 instead\n");
+		/* Fall through */
+	}
 	case TIOCSRS485:
 	{
 		/* This is the new version of TIOCSRS485, with new
-- 
1.7.1



--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux