lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <4D257C87.4040400@evidence.eu.com>
Date:	Thu, 06 Jan 2011 09:25:43 +0100
From:	Claudio Scordino <claudio@...dence.eu.com>
To:	starvik@...s.com, Jesper Nilsson <Jesper.Nilsson@...s.com>
CC:	linux-cris-kernel <linux-cris-kernel@...s.com>,
	"linux-serial@...r.kernel.org" <linux-serial@...r.kernel.org>,
	Linux Kernel <linux-kernel@...r.kernel.org>
Subject: [PATCH] RS485 on Cris: use global value of TIOCSRS485

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@...dence.eu.com>
---
 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-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ