Staging: serqt_usb: fix build due to proc tty changes
authorGreg Kroah-Hartman <gregkh@suse.de>
Fri, 3 Apr 2009 20:55:23 +0000 (13:55 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 3 Apr 2009 21:54:27 +0000 (14:54 -0700)
Just delete the proc tty usage in the driver as it's not needed and will
go away when it switches over to a usb-serial driver.  This fixes the
build error in the driver.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/serqt_usb/serqt_usb.c

index 3b73c782e3c96d81885adea28cddbfb17a253dd2..1781510c53fd7a5a7dbc4e04c7b768801d3e06fd 100644 (file)
@@ -288,8 +288,6 @@ static void serial_throttle(struct tty_struct *tty);
 static void serial_unthrottle(struct tty_struct *tty);
 static int serial_break(struct tty_struct *tty, int break_state);
 static int serial_chars_in_buffer(struct tty_struct *tty);
-static int serial_read_proc(char *page, char **start, off_t off, int count,
-                           int *eof, void *data);
 
 static int qt_open(struct usb_serial_port *port, struct file *filp);
 static int BoxSetPrebufferLevel(struct usb_serial *serial);
@@ -438,7 +436,6 @@ static const struct tty_operations serial_ops = {
        .unthrottle = serial_unthrottle,
        .break_ctl = serial_break,
        .chars_in_buffer = serial_chars_in_buffer,
-       .read_proc = serial_read_proc,
        .tiocmset = serial_tiocmset,
        .tiocmget = serial_tiocmget,
 };
@@ -2417,52 +2414,6 @@ exit:
        return 0;
 }
 
-static int serial_read_proc(char *page, char **start, off_t off, int count,
-                           int *eof, void *data)
-{
-       struct usb_serial *serial;
-       int length = 0;
-       int i;
-       off_t begin = 0;
-
-       mydbg("%s\n", __func__);
-       length += sprintf(page, "usbserinfo:1.0 driver:%s\n", DRIVER_VERSION);
-       for (i = 0; i < SERIAL_TTY_MINORS && length < PAGE_SIZE; ++i) {
-               serial = get_serial_by_minor(i);
-               if (serial == NULL)
-                       continue;
-
-               length += sprintf(page + length, "%d:\n", i);
-               length +=
-                   sprintf(page + length, " vendor:%04x product:%04x\n",
-                           serial->vendor, serial->product);
-               length +=
-                   sprintf(page + length, " num_ports:%d\n",
-                           serial->num_ports);
-               length +=
-                   sprintf(page + length, " port:%d\n", i - serial->minor + 1);
-
-/*
-               usb_make_path(serial->dev, tmp, sizeof(tmp));
-               length += sprintf (page+length, " path:%s", tmp);
-*/
-
-               length += sprintf(page + length, "\n");
-               if ((length + begin) > (off + count))
-                       goto done;
-               if ((length + begin) < off) {
-                       begin += length;
-                       length = 0;
-               }
-       }
-       *eof = 1;
-done:
-       if (off >= (length + begin))
-               return 0;
-       *start = page + (off - begin);
-       return ((count < begin + length - off) ? count : begin + length - off);
-}
-
 static int ioctl_serial_usb(struct inode *innod, struct file *filp, unsigned int cmd,
                     unsigned long arg)
 {