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-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 06 Apr 2009 17:35:25 +0100
From:	Alan Cox <alan@...rguk.ukuu.org.uk>
To:	torvalds@...ux-foundation.org, linux-kernel@...r.kernel.org
Subject: [PATCH 25/27] symbol: Remove various bits of left over junk

There are various bits of code here that are unfinished and instead of
being harmless either confuse or spew stuff into the logs at higher than
debug level. They can and should go away.

Also remove the bogus use of tty->lowlatency. We fixed the need for this hack
long ago (with the flip buffer rewrite) but people keep copying it into drivers.

Signed-off-by: Alan Cox <alan@...rguk.ukuu.org.uk>
---

 drivers/usb/serial/symbolserial.c |   67 -------------------------------------
 1 files changed, 0 insertions(+), 67 deletions(-)


diff --git a/drivers/usb/serial/symbolserial.c b/drivers/usb/serial/symbolserial.c
index 8b3cbc8..69879e4 100644
--- a/drivers/usb/serial/symbolserial.c
+++ b/drivers/usb/serial/symbolserial.c
@@ -139,14 +139,6 @@ static int symbol_open(struct tty_struct *tty, struct usb_serial_port *port,
 	priv->port = port;
 	spin_unlock_irqrestore(&priv->lock, flags);
 
-	/*
-	 * Force low_latency on so that our tty_push actually forces the data
-	 * through, otherwise it is scheduled, and with high data rates (like
-	 * with OHCI) data can get lost.
-	 */
-	if (tty)
-		tty->low_latency = 1;
-
 	/* Start reading from the device */
 	usb_fill_int_urb(priv->int_urb, priv->udev,
 			 usb_rcvintpipe(priv->udev, priv->int_address),
@@ -205,62 +197,6 @@ static void symbol_unthrottle(struct tty_struct *tty)
 							__func__, result);
 }
 
-static int symbol_ioctl(struct tty_struct *tty, struct file *file,
-			unsigned int cmd, unsigned long arg)
-{
-	struct usb_serial_port *port = tty->driver_data;
-	struct device *dev = &port->dev;
-
-	/*
-	 * Right now we need to figure out what commands
-	 * most userspace tools want to see for this driver,
-	 * so just log the things.
-	 */
-	switch (cmd) {
-	case TIOCSERGETLSR:
-		dev_info(dev, "%s: TIOCSERGETLSR\n", __func__);
-		break;
-
-	case TIOCGSERIAL:
-		dev_info(dev, "%s: TIOCGSERIAL\n", __func__);
-		break;
-
-	case TIOCMIWAIT:
-		dev_info(dev, "%s: TIOCMIWAIT\n", __func__);
-		break;
-
-	case TIOCGICOUNT:
-		dev_info(dev, "%s: TIOCGICOUNT\n", __func__);
-		break;
-	default:
-		dev_info(dev, "%s: unknown (%d)\n", __func__, cmd);
-	}
-	return -ENOIOCTLCMD;
-}
-
-static int symbol_tiocmget(struct tty_struct *tty, struct file *file)
-{
-	struct usb_serial_port *port = tty->driver_data;
-	struct device *dev = &port->dev;
-
-	/* TODO */
-	/* probably just need to shadow whatever was sent to us here */
-	dev_info(dev, "%s\n", __func__);
-	return 0;
-}
-
-static int symbol_tiocmset(struct tty_struct *tty, struct file *file,
-			   unsigned int set, unsigned int clear)
-{
-	struct usb_serial_port *port = tty->driver_data;
-	struct device *dev = &port->dev;
-
-	/* TODO */
-	/* probably just need to shadow whatever was sent to us here */
-	dev_info(dev, "%s\n", __func__);
-	return 0;
-}
-
 static int symbol_startup(struct usb_serial *serial)
 {
 	struct symbol_private *priv;
@@ -367,9 +303,6 @@ static struct usb_serial_driver symbol_device = {
 	.shutdown =		symbol_shutdown,
 	.throttle = 		symbol_throttle,
 	.unthrottle =		symbol_unthrottle,
-	.ioctl = 		symbol_ioctl,
-	.tiocmget = 		symbol_tiocmget,
-	.tiocmset = 		symbol_tiocmset,
 };
 
 static int __init symbol_init(void)

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