aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial
diff options
context:
space:
mode:
authorAlan Cox <alan@linux.intel.com>2011-02-14 11:26:14 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2011-02-17 14:47:33 -0500
commit60b33c133ca0b7c0b6072c87234b63fee6e80558 (patch)
tree379340a7ab563df42ddb2907be6f282202244077 /drivers/usb/serial
parentadf9251fe9b87b5a50deebe489db2df8df4715fc (diff)
tiocmget: kill off the passing of the struct file
We don't actually need this and it causes problems for internal use of this functionality. Currently there is a single use of the FILE * pointer. That is the serial core which uses it to check tty_hung_up_p. However if that is true then IO_ERROR is also already set so the check may be removed. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/serial')
-rw-r--r--drivers/usb/serial/ark3116.c2
-rw-r--r--drivers/usb/serial/belkin_sa.c4
-rw-r--r--drivers/usb/serial/ch341.c2
-rw-r--r--drivers/usb/serial/cp210x.c4
-rw-r--r--drivers/usb/serial/cypress_m8.c4
-rw-r--r--drivers/usb/serial/digi_acceleport.c4
-rw-r--r--drivers/usb/serial/ftdi_sio.c4
-rw-r--r--drivers/usb/serial/io_edgeport.c4
-rw-r--r--drivers/usb/serial/io_ti.c2
-rw-r--r--drivers/usb/serial/iuu_phoenix.c2
-rw-r--r--drivers/usb/serial/keyspan.c2
-rw-r--r--drivers/usb/serial/keyspan.h3
-rw-r--r--drivers/usb/serial/keyspan_pda.c2
-rw-r--r--drivers/usb/serial/kl5kusb105.c4
-rw-r--r--drivers/usb/serial/kobil_sct.c4
-rw-r--r--drivers/usb/serial/mct_u232.c4
-rw-r--r--drivers/usb/serial/mos7720.c4
-rw-r--r--drivers/usb/serial/mos7840.c2
-rw-r--r--drivers/usb/serial/opticon.c2
-rw-r--r--drivers/usb/serial/oti6858.c4
-rw-r--r--drivers/usb/serial/pl2303.c2
-rw-r--r--drivers/usb/serial/sierra.c2
-rw-r--r--drivers/usb/serial/spcp8x5.c2
-rw-r--r--drivers/usb/serial/ssu100.c2
-rw-r--r--drivers/usb/serial/ti_usb_3410_5052.c4
-rw-r--r--drivers/usb/serial/usb-serial.c4
-rw-r--r--drivers/usb/serial/usb-wwan.h2
-rw-r--r--drivers/usb/serial/usb_wwan.c2
-rw-r--r--drivers/usb/serial/whiteheat.c4
29 files changed, 43 insertions, 44 deletions
diff --git a/drivers/usb/serial/ark3116.c b/drivers/usb/serial/ark3116.c
index 8f1d4fb19d24..35b610aa3f92 100644
--- a/drivers/usb/serial/ark3116.c
+++ b/drivers/usb/serial/ark3116.c
@@ -485,7 +485,7 @@ static int ark3116_ioctl(struct tty_struct *tty, struct file *file,
485 return -ENOIOCTLCMD; 485 return -ENOIOCTLCMD;
486} 486}
487 487
488static int ark3116_tiocmget(struct tty_struct *tty, struct file *file) 488static int ark3116_tiocmget(struct tty_struct *tty)
489{ 489{
490 struct usb_serial_port *port = tty->driver_data; 490 struct usb_serial_port *port = tty->driver_data;
491 struct ark3116_private *priv = usb_get_serial_port_data(port); 491 struct ark3116_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/belkin_sa.c b/drivers/usb/serial/belkin_sa.c
index 36df35295db2..48fb3bad3cd6 100644
--- a/drivers/usb/serial/belkin_sa.c
+++ b/drivers/usb/serial/belkin_sa.c
@@ -100,7 +100,7 @@ static void belkin_sa_process_read_urb(struct urb *urb);
100static void belkin_sa_set_termios(struct tty_struct *tty, 100static void belkin_sa_set_termios(struct tty_struct *tty,
101 struct usb_serial_port *port, struct ktermios * old); 101 struct usb_serial_port *port, struct ktermios * old);
102static void belkin_sa_break_ctl(struct tty_struct *tty, int break_state); 102static void belkin_sa_break_ctl(struct tty_struct *tty, int break_state);
103static int belkin_sa_tiocmget(struct tty_struct *tty, struct file *file); 103static int belkin_sa_tiocmget(struct tty_struct *tty);
104static int belkin_sa_tiocmset(struct tty_struct *tty, struct file *file, 104static int belkin_sa_tiocmset(struct tty_struct *tty, struct file *file,
105 unsigned int set, unsigned int clear); 105 unsigned int set, unsigned int clear);
106 106
@@ -497,7 +497,7 @@ static void belkin_sa_break_ctl(struct tty_struct *tty, int break_state)
497 dev_err(&port->dev, "Set break_ctl %d\n", break_state); 497 dev_err(&port->dev, "Set break_ctl %d\n", break_state);
498} 498}
499 499
500static int belkin_sa_tiocmget(struct tty_struct *tty, struct file *file) 500static int belkin_sa_tiocmget(struct tty_struct *tty)
501{ 501{
502 struct usb_serial_port *port = tty->driver_data; 502 struct usb_serial_port *port = tty->driver_data;
503 struct belkin_sa_private *priv = usb_get_serial_port_data(port); 503 struct belkin_sa_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/ch341.c b/drivers/usb/serial/ch341.c
index 7b8815ddf368..aa0962b72f4c 100644
--- a/drivers/usb/serial/ch341.c
+++ b/drivers/usb/serial/ch341.c
@@ -572,7 +572,7 @@ static int ch341_ioctl(struct tty_struct *tty, struct file *file,
572 return -ENOIOCTLCMD; 572 return -ENOIOCTLCMD;
573} 573}
574 574
575static int ch341_tiocmget(struct tty_struct *tty, struct file *file) 575static int ch341_tiocmget(struct tty_struct *tty)
576{ 576{
577 struct usb_serial_port *port = tty->driver_data; 577 struct usb_serial_port *port = tty->driver_data;
578 struct ch341_private *priv = usb_get_serial_port_data(port); 578 struct ch341_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/cp210x.c b/drivers/usb/serial/cp210x.c
index 735ea03157ab..b3873815035c 100644
--- a/drivers/usb/serial/cp210x.c
+++ b/drivers/usb/serial/cp210x.c
@@ -41,7 +41,7 @@ static void cp210x_get_termios_port(struct usb_serial_port *port,
41 unsigned int *cflagp, unsigned int *baudp); 41 unsigned int *cflagp, unsigned int *baudp);
42static void cp210x_set_termios(struct tty_struct *, struct usb_serial_port *, 42static void cp210x_set_termios(struct tty_struct *, struct usb_serial_port *,
43 struct ktermios*); 43 struct ktermios*);
44static int cp210x_tiocmget(struct tty_struct *, struct file *); 44static int cp210x_tiocmget(struct tty_struct *);
45static int cp210x_tiocmset(struct tty_struct *, struct file *, 45static int cp210x_tiocmset(struct tty_struct *, struct file *,
46 unsigned int, unsigned int); 46 unsigned int, unsigned int);
47static int cp210x_tiocmset_port(struct usb_serial_port *port, struct file *, 47static int cp210x_tiocmset_port(struct usb_serial_port *port, struct file *,
@@ -742,7 +742,7 @@ static void cp210x_dtr_rts(struct usb_serial_port *p, int on)
742 cp210x_tiocmset_port(p, NULL, 0, TIOCM_DTR|TIOCM_RTS); 742 cp210x_tiocmset_port(p, NULL, 0, TIOCM_DTR|TIOCM_RTS);
743} 743}
744 744
745static int cp210x_tiocmget (struct tty_struct *tty, struct file *file) 745static int cp210x_tiocmget (struct tty_struct *tty)
746{ 746{
747 struct usb_serial_port *port = tty->driver_data; 747 struct usb_serial_port *port = tty->driver_data;
748 unsigned int control; 748 unsigned int control;
diff --git a/drivers/usb/serial/cypress_m8.c b/drivers/usb/serial/cypress_m8.c
index 2edf238b00b9..9c96cff691fd 100644
--- a/drivers/usb/serial/cypress_m8.c
+++ b/drivers/usb/serial/cypress_m8.c
@@ -173,7 +173,7 @@ static int cypress_ioctl(struct tty_struct *tty, struct file *file,
173 unsigned int cmd, unsigned long arg); 173 unsigned int cmd, unsigned long arg);
174static void cypress_set_termios(struct tty_struct *tty, 174static void cypress_set_termios(struct tty_struct *tty,
175 struct usb_serial_port *port, struct ktermios *old); 175 struct usb_serial_port *port, struct ktermios *old);
176static int cypress_tiocmget(struct tty_struct *tty, struct file *file); 176static int cypress_tiocmget(struct tty_struct *tty);
177static int cypress_tiocmset(struct tty_struct *tty, struct file *file, 177static int cypress_tiocmset(struct tty_struct *tty, struct file *file,
178 unsigned int set, unsigned int clear); 178 unsigned int set, unsigned int clear);
179static int cypress_chars_in_buffer(struct tty_struct *tty); 179static int cypress_chars_in_buffer(struct tty_struct *tty);
@@ -864,7 +864,7 @@ static int cypress_write_room(struct tty_struct *tty)
864} 864}
865 865
866 866
867static int cypress_tiocmget(struct tty_struct *tty, struct file *file) 867static int cypress_tiocmget(struct tty_struct *tty)
868{ 868{
869 struct usb_serial_port *port = tty->driver_data; 869 struct usb_serial_port *port = tty->driver_data;
870 struct cypress_private *priv = usb_get_serial_port_data(port); 870 struct cypress_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/digi_acceleport.c b/drivers/usb/serial/digi_acceleport.c
index 666e5a6edd82..08da46cb5825 100644
--- a/drivers/usb/serial/digi_acceleport.c
+++ b/drivers/usb/serial/digi_acceleport.c
@@ -445,7 +445,7 @@ static void digi_rx_unthrottle(struct tty_struct *tty);
445static void digi_set_termios(struct tty_struct *tty, 445static void digi_set_termios(struct tty_struct *tty,
446 struct usb_serial_port *port, struct ktermios *old_termios); 446 struct usb_serial_port *port, struct ktermios *old_termios);
447static void digi_break_ctl(struct tty_struct *tty, int break_state); 447static void digi_break_ctl(struct tty_struct *tty, int break_state);
448static int digi_tiocmget(struct tty_struct *tty, struct file *file); 448static int digi_tiocmget(struct tty_struct *tty);
449static int digi_tiocmset(struct tty_struct *tty, struct file *file, 449static int digi_tiocmset(struct tty_struct *tty, struct file *file,
450 unsigned int set, unsigned int clear); 450 unsigned int set, unsigned int clear);
451static int digi_write(struct tty_struct *tty, struct usb_serial_port *port, 451static int digi_write(struct tty_struct *tty, struct usb_serial_port *port,
@@ -1118,7 +1118,7 @@ static void digi_break_ctl(struct tty_struct *tty, int break_state)
1118} 1118}
1119 1119
1120 1120
1121static int digi_tiocmget(struct tty_struct *tty, struct file *file) 1121static int digi_tiocmget(struct tty_struct *tty)
1122{ 1122{
1123 struct usb_serial_port *port = tty->driver_data; 1123 struct usb_serial_port *port = tty->driver_data;
1124 struct digi_port *priv = usb_get_serial_port_data(port); 1124 struct digi_port *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/ftdi_sio.c b/drivers/usb/serial/ftdi_sio.c
index 4787c0cd063f..281d18141051 100644
--- a/drivers/usb/serial/ftdi_sio.c
+++ b/drivers/usb/serial/ftdi_sio.c
@@ -856,7 +856,7 @@ static int ftdi_prepare_write_buffer(struct usb_serial_port *port,
856 void *dest, size_t size); 856 void *dest, size_t size);
857static void ftdi_set_termios(struct tty_struct *tty, 857static void ftdi_set_termios(struct tty_struct *tty,
858 struct usb_serial_port *port, struct ktermios *old); 858 struct usb_serial_port *port, struct ktermios *old);
859static int ftdi_tiocmget(struct tty_struct *tty, struct file *file); 859static int ftdi_tiocmget(struct tty_struct *tty);
860static int ftdi_tiocmset(struct tty_struct *tty, struct file *file, 860static int ftdi_tiocmset(struct tty_struct *tty, struct file *file,
861 unsigned int set, unsigned int clear); 861 unsigned int set, unsigned int clear);
862static int ftdi_ioctl(struct tty_struct *tty, struct file *file, 862static int ftdi_ioctl(struct tty_struct *tty, struct file *file,
@@ -2149,7 +2149,7 @@ static void ftdi_set_termios(struct tty_struct *tty,
2149 } 2149 }
2150} 2150}
2151 2151
2152static int ftdi_tiocmget(struct tty_struct *tty, struct file *file) 2152static int ftdi_tiocmget(struct tty_struct *tty)
2153{ 2153{
2154 struct usb_serial_port *port = tty->driver_data; 2154 struct usb_serial_port *port = tty->driver_data;
2155 struct ftdi_private *priv = usb_get_serial_port_data(port); 2155 struct ftdi_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/io_edgeport.c b/drivers/usb/serial/io_edgeport.c
index cd769ef24f8a..e8fe4dcf72f0 100644
--- a/drivers/usb/serial/io_edgeport.c
+++ b/drivers/usb/serial/io_edgeport.c
@@ -219,7 +219,7 @@ static void edge_set_termios(struct tty_struct *tty,
219static int edge_ioctl(struct tty_struct *tty, struct file *file, 219static int edge_ioctl(struct tty_struct *tty, struct file *file,
220 unsigned int cmd, unsigned long arg); 220 unsigned int cmd, unsigned long arg);
221static void edge_break(struct tty_struct *tty, int break_state); 221static void edge_break(struct tty_struct *tty, int break_state);
222static int edge_tiocmget(struct tty_struct *tty, struct file *file); 222static int edge_tiocmget(struct tty_struct *tty);
223static int edge_tiocmset(struct tty_struct *tty, struct file *file, 223static int edge_tiocmset(struct tty_struct *tty, struct file *file,
224 unsigned int set, unsigned int clear); 224 unsigned int set, unsigned int clear);
225static int edge_get_icount(struct tty_struct *tty, 225static int edge_get_icount(struct tty_struct *tty,
@@ -1599,7 +1599,7 @@ static int edge_tiocmset(struct tty_struct *tty, struct file *file,
1599 return 0; 1599 return 0;
1600} 1600}
1601 1601
1602static int edge_tiocmget(struct tty_struct *tty, struct file *file) 1602static int edge_tiocmget(struct tty_struct *tty)
1603{ 1603{
1604 struct usb_serial_port *port = tty->driver_data; 1604 struct usb_serial_port *port = tty->driver_data;
1605 struct edgeport_port *edge_port = usb_get_serial_port_data(port); 1605 struct edgeport_port *edge_port = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/io_ti.c b/drivers/usb/serial/io_ti.c
index 22506b095c4f..7cb9f5cb91f3 100644
--- a/drivers/usb/serial/io_ti.c
+++ b/drivers/usb/serial/io_ti.c
@@ -2477,7 +2477,7 @@ static int edge_tiocmset(struct tty_struct *tty, struct file *file,
2477 return 0; 2477 return 0;
2478} 2478}
2479 2479
2480static int edge_tiocmget(struct tty_struct *tty, struct file *file) 2480static int edge_tiocmget(struct tty_struct *tty)
2481{ 2481{
2482 struct usb_serial_port *port = tty->driver_data; 2482 struct usb_serial_port *port = tty->driver_data;
2483 struct edgeport_port *edge_port = usb_get_serial_port_data(port); 2483 struct edgeport_port *edge_port = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/iuu_phoenix.c b/drivers/usb/serial/iuu_phoenix.c
index 99b97c04896f..1d96142f135a 100644
--- a/drivers/usb/serial/iuu_phoenix.c
+++ b/drivers/usb/serial/iuu_phoenix.c
@@ -179,7 +179,7 @@ static int iuu_tiocmset(struct tty_struct *tty, struct file *file,
179 * When no card , the reader respond with TIOCM_CD 179 * When no card , the reader respond with TIOCM_CD
180 * This is known as CD autodetect mechanism 180 * This is known as CD autodetect mechanism
181 */ 181 */
182static int iuu_tiocmget(struct tty_struct *tty, struct file *file) 182static int iuu_tiocmget(struct tty_struct *tty)
183{ 183{
184 struct usb_serial_port *port = tty->driver_data; 184 struct usb_serial_port *port = tty->driver_data;
185 struct iuu_private *priv = usb_get_serial_port_data(port); 185 struct iuu_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/keyspan.c b/drivers/usb/serial/keyspan.c
index 0791778a66f3..1beebbb7a20a 100644
--- a/drivers/usb/serial/keyspan.c
+++ b/drivers/usb/serial/keyspan.c
@@ -301,7 +301,7 @@ static void keyspan_set_termios(struct tty_struct *tty,
301 keyspan_send_setup(port, 0); 301 keyspan_send_setup(port, 0);
302} 302}
303 303
304static int keyspan_tiocmget(struct tty_struct *tty, struct file *file) 304static int keyspan_tiocmget(struct tty_struct *tty)
305{ 305{
306 struct usb_serial_port *port = tty->driver_data; 306 struct usb_serial_port *port = tty->driver_data;
307 struct keyspan_port_private *p_priv = usb_get_serial_port_data(port); 307 struct keyspan_port_private *p_priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/keyspan.h b/drivers/usb/serial/keyspan.h
index ce134dc28ddf..5e5fc71e68df 100644
--- a/drivers/usb/serial/keyspan.h
+++ b/drivers/usb/serial/keyspan.h
@@ -58,8 +58,7 @@ static void keyspan_set_termios (struct tty_struct *tty,
58 struct ktermios *old); 58 struct ktermios *old);
59static void keyspan_break_ctl (struct tty_struct *tty, 59static void keyspan_break_ctl (struct tty_struct *tty,
60 int break_state); 60 int break_state);
61static int keyspan_tiocmget (struct tty_struct *tty, 61static int keyspan_tiocmget (struct tty_struct *tty);
62 struct file *file);
63static int keyspan_tiocmset (struct tty_struct *tty, 62static int keyspan_tiocmset (struct tty_struct *tty,
64 struct file *file, unsigned int set, 63 struct file *file, unsigned int set,
65 unsigned int clear); 64 unsigned int clear);
diff --git a/drivers/usb/serial/keyspan_pda.c b/drivers/usb/serial/keyspan_pda.c
index 554a8693a463..49ad2baf77cd 100644
--- a/drivers/usb/serial/keyspan_pda.c
+++ b/drivers/usb/serial/keyspan_pda.c
@@ -457,7 +457,7 @@ static int keyspan_pda_set_modem_info(struct usb_serial *serial,
457 return rc; 457 return rc;
458} 458}
459 459
460static int keyspan_pda_tiocmget(struct tty_struct *tty, struct file *file) 460static int keyspan_pda_tiocmget(struct tty_struct *tty)
461{ 461{
462 struct usb_serial_port *port = tty->driver_data; 462 struct usb_serial_port *port = tty->driver_data;
463 struct usb_serial *serial = port->serial; 463 struct usb_serial *serial = port->serial;
diff --git a/drivers/usb/serial/kl5kusb105.c b/drivers/usb/serial/kl5kusb105.c
index e8a65ce45a2f..a570f5201c73 100644
--- a/drivers/usb/serial/kl5kusb105.c
+++ b/drivers/usb/serial/kl5kusb105.c
@@ -68,7 +68,7 @@ static int klsi_105_open(struct tty_struct *tty, struct usb_serial_port *port);
68static void klsi_105_close(struct usb_serial_port *port); 68static void klsi_105_close(struct usb_serial_port *port);
69static void klsi_105_set_termios(struct tty_struct *tty, 69static void klsi_105_set_termios(struct tty_struct *tty,
70 struct usb_serial_port *port, struct ktermios *old); 70 struct usb_serial_port *port, struct ktermios *old);
71static int klsi_105_tiocmget(struct tty_struct *tty, struct file *file); 71static int klsi_105_tiocmget(struct tty_struct *tty);
72static int klsi_105_tiocmset(struct tty_struct *tty, struct file *file, 72static int klsi_105_tiocmset(struct tty_struct *tty, struct file *file,
73 unsigned int set, unsigned int clear); 73 unsigned int set, unsigned int clear);
74static void klsi_105_process_read_urb(struct urb *urb); 74static void klsi_105_process_read_urb(struct urb *urb);
@@ -637,7 +637,7 @@ static void mct_u232_break_ctl(struct tty_struct *tty, int break_state)
637} 637}
638#endif 638#endif
639 639
640static int klsi_105_tiocmget(struct tty_struct *tty, struct file *file) 640static int klsi_105_tiocmget(struct tty_struct *tty)
641{ 641{
642 struct usb_serial_port *port = tty->driver_data; 642 struct usb_serial_port *port = tty->driver_data;
643 struct klsi_105_private *priv = usb_get_serial_port_data(port); 643 struct klsi_105_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/kobil_sct.c b/drivers/usb/serial/kobil_sct.c
index bd5bd8589e04..81d07fb299b8 100644
--- a/drivers/usb/serial/kobil_sct.c
+++ b/drivers/usb/serial/kobil_sct.c
@@ -77,7 +77,7 @@ static int kobil_write(struct tty_struct *tty, struct usb_serial_port *port,
77static int kobil_write_room(struct tty_struct *tty); 77static int kobil_write_room(struct tty_struct *tty);
78static int kobil_ioctl(struct tty_struct *tty, struct file *file, 78static int kobil_ioctl(struct tty_struct *tty, struct file *file,
79 unsigned int cmd, unsigned long arg); 79 unsigned int cmd, unsigned long arg);
80static int kobil_tiocmget(struct tty_struct *tty, struct file *file); 80static int kobil_tiocmget(struct tty_struct *tty);
81static int kobil_tiocmset(struct tty_struct *tty, struct file *file, 81static int kobil_tiocmset(struct tty_struct *tty, struct file *file,
82 unsigned int set, unsigned int clear); 82 unsigned int set, unsigned int clear);
83static void kobil_read_int_callback(struct urb *urb); 83static void kobil_read_int_callback(struct urb *urb);
@@ -504,7 +504,7 @@ static int kobil_write_room(struct tty_struct *tty)
504} 504}
505 505
506 506
507static int kobil_tiocmget(struct tty_struct *tty, struct file *file) 507static int kobil_tiocmget(struct tty_struct *tty)
508{ 508{
509 struct usb_serial_port *port = tty->driver_data; 509 struct usb_serial_port *port = tty->driver_data;
510 struct kobil_private *priv; 510 struct kobil_private *priv;
diff --git a/drivers/usb/serial/mct_u232.c b/drivers/usb/serial/mct_u232.c
index 2849f8c32015..27447095feae 100644
--- a/drivers/usb/serial/mct_u232.c
+++ b/drivers/usb/serial/mct_u232.c
@@ -101,7 +101,7 @@ static void mct_u232_read_int_callback(struct urb *urb);
101static void mct_u232_set_termios(struct tty_struct *tty, 101static void mct_u232_set_termios(struct tty_struct *tty,
102 struct usb_serial_port *port, struct ktermios *old); 102 struct usb_serial_port *port, struct ktermios *old);
103static void mct_u232_break_ctl(struct tty_struct *tty, int break_state); 103static void mct_u232_break_ctl(struct tty_struct *tty, int break_state);
104static int mct_u232_tiocmget(struct tty_struct *tty, struct file *file); 104static int mct_u232_tiocmget(struct tty_struct *tty);
105static int mct_u232_tiocmset(struct tty_struct *tty, struct file *file, 105static int mct_u232_tiocmset(struct tty_struct *tty, struct file *file,
106 unsigned int set, unsigned int clear); 106 unsigned int set, unsigned int clear);
107static void mct_u232_throttle(struct tty_struct *tty); 107static void mct_u232_throttle(struct tty_struct *tty);
@@ -762,7 +762,7 @@ static void mct_u232_break_ctl(struct tty_struct *tty, int break_state)
762} /* mct_u232_break_ctl */ 762} /* mct_u232_break_ctl */
763 763
764 764
765static int mct_u232_tiocmget(struct tty_struct *tty, struct file *file) 765static int mct_u232_tiocmget(struct tty_struct *tty)
766{ 766{
767 struct usb_serial_port *port = tty->driver_data; 767 struct usb_serial_port *port = tty->driver_data;
768 struct mct_u232_private *priv = usb_get_serial_port_data(port); 768 struct mct_u232_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/mos7720.c b/drivers/usb/serial/mos7720.c
index 7d3bc9a3e2b6..5d40d4151b5a 100644
--- a/drivers/usb/serial/mos7720.c
+++ b/drivers/usb/serial/mos7720.c
@@ -1833,7 +1833,7 @@ static int get_lsr_info(struct tty_struct *tty,
1833 return 0; 1833 return 0;
1834} 1834}
1835 1835
1836static int mos7720_tiocmget(struct tty_struct *tty, struct file *file) 1836static int mos7720_tiocmget(struct tty_struct *tty)
1837{ 1837{
1838 struct usb_serial_port *port = tty->driver_data; 1838 struct usb_serial_port *port = tty->driver_data;
1839 struct moschip_port *mos7720_port = usb_get_serial_port_data(port); 1839 struct moschip_port *mos7720_port = usb_get_serial_port_data(port);
@@ -1865,7 +1865,7 @@ static int mos7720_tiocmset(struct tty_struct *tty, struct file *file,
1865 struct moschip_port *mos7720_port = usb_get_serial_port_data(port); 1865 struct moschip_port *mos7720_port = usb_get_serial_port_data(port);
1866 unsigned int mcr ; 1866 unsigned int mcr ;
1867 dbg("%s - port %d", __func__, port->number); 1867 dbg("%s - port %d", __func__, port->number);
1868 dbg("he was at tiocmget"); 1868 dbg("he was at tiocmset");
1869 1869
1870 mcr = mos7720_port->shadowMCR; 1870 mcr = mos7720_port->shadowMCR;
1871 1871
diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c
index 5627993f9e41..ee0dc9a0890c 100644
--- a/drivers/usb/serial/mos7840.c
+++ b/drivers/usb/serial/mos7840.c
@@ -1644,7 +1644,7 @@ static void mos7840_unthrottle(struct tty_struct *tty)
1644 } 1644 }
1645} 1645}
1646 1646
1647static int mos7840_tiocmget(struct tty_struct *tty, struct file *file) 1647static int mos7840_tiocmget(struct tty_struct *tty)
1648{ 1648{
1649 struct usb_serial_port *port = tty->driver_data; 1649 struct usb_serial_port *port = tty->driver_data;
1650 struct moschip_port *mos7840_port; 1650 struct moschip_port *mos7840_port;
diff --git a/drivers/usb/serial/opticon.c b/drivers/usb/serial/opticon.c
index eda1f9266c4e..e305df807396 100644
--- a/drivers/usb/serial/opticon.c
+++ b/drivers/usb/serial/opticon.c
@@ -352,7 +352,7 @@ static void opticon_unthrottle(struct tty_struct *tty)
352 } 352 }
353} 353}
354 354
355static int opticon_tiocmget(struct tty_struct *tty, struct file *file) 355static int opticon_tiocmget(struct tty_struct *tty)
356{ 356{
357 struct usb_serial_port *port = tty->driver_data; 357 struct usb_serial_port *port = tty->driver_data;
358 struct opticon_private *priv = usb_get_serial_data(port->serial); 358 struct opticon_private *priv = usb_get_serial_data(port->serial);
diff --git a/drivers/usb/serial/oti6858.c b/drivers/usb/serial/oti6858.c
index 73613205be7a..4cd3b0ef4e61 100644
--- a/drivers/usb/serial/oti6858.c
+++ b/drivers/usb/serial/oti6858.c
@@ -144,7 +144,7 @@ static int oti6858_write(struct tty_struct *tty, struct usb_serial_port *port,
144 const unsigned char *buf, int count); 144 const unsigned char *buf, int count);
145static int oti6858_write_room(struct tty_struct *tty); 145static int oti6858_write_room(struct tty_struct *tty);
146static int oti6858_chars_in_buffer(struct tty_struct *tty); 146static int oti6858_chars_in_buffer(struct tty_struct *tty);
147static int oti6858_tiocmget(struct tty_struct *tty, struct file *file); 147static int oti6858_tiocmget(struct tty_struct *tty);
148static int oti6858_tiocmset(struct tty_struct *tty, struct file *file, 148static int oti6858_tiocmset(struct tty_struct *tty, struct file *file,
149 unsigned int set, unsigned int clear); 149 unsigned int set, unsigned int clear);
150static int oti6858_startup(struct usb_serial *serial); 150static int oti6858_startup(struct usb_serial *serial);
@@ -657,7 +657,7 @@ static int oti6858_tiocmset(struct tty_struct *tty, struct file *file,
657 return 0; 657 return 0;
658} 658}
659 659
660static int oti6858_tiocmget(struct tty_struct *tty, struct file *file) 660static int oti6858_tiocmget(struct tty_struct *tty)
661{ 661{
662 struct usb_serial_port *port = tty->driver_data; 662 struct usb_serial_port *port = tty->driver_data;
663 struct oti6858_private *priv = usb_get_serial_port_data(port); 663 struct oti6858_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/pl2303.c b/drivers/usb/serial/pl2303.c
index 08c9181b8e48..6cb4f503a3f1 100644
--- a/drivers/usb/serial/pl2303.c
+++ b/drivers/usb/serial/pl2303.c
@@ -531,7 +531,7 @@ static int pl2303_tiocmset(struct tty_struct *tty, struct file *file,
531 return set_control_lines(port->serial->dev, control); 531 return set_control_lines(port->serial->dev, control);
532} 532}
533 533
534static int pl2303_tiocmget(struct tty_struct *tty, struct file *file) 534static int pl2303_tiocmget(struct tty_struct *tty)
535{ 535{
536 struct usb_serial_port *port = tty->driver_data; 536 struct usb_serial_port *port = tty->driver_data;
537 struct pl2303_private *priv = usb_get_serial_port_data(port); 537 struct pl2303_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/sierra.c b/drivers/usb/serial/sierra.c
index 7481ff8a49e4..66437f1e9e5b 100644
--- a/drivers/usb/serial/sierra.c
+++ b/drivers/usb/serial/sierra.c
@@ -389,7 +389,7 @@ static void sierra_set_termios(struct tty_struct *tty,
389 sierra_send_setup(port); 389 sierra_send_setup(port);
390} 390}
391 391
392static int sierra_tiocmget(struct tty_struct *tty, struct file *file) 392static int sierra_tiocmget(struct tty_struct *tty)
393{ 393{
394 struct usb_serial_port *port = tty->driver_data; 394 struct usb_serial_port *port = tty->driver_data;
395 unsigned int value; 395 unsigned int value;
diff --git a/drivers/usb/serial/spcp8x5.c b/drivers/usb/serial/spcp8x5.c
index cbfb70bffdd0..cac13009fc5c 100644
--- a/drivers/usb/serial/spcp8x5.c
+++ b/drivers/usb/serial/spcp8x5.c
@@ -618,7 +618,7 @@ static int spcp8x5_tiocmset(struct tty_struct *tty, struct file *file,
618 return spcp8x5_set_ctrlLine(port->serial->dev, control , priv->type); 618 return spcp8x5_set_ctrlLine(port->serial->dev, control , priv->type);
619} 619}
620 620
621static int spcp8x5_tiocmget(struct tty_struct *tty, struct file *file) 621static int spcp8x5_tiocmget(struct tty_struct *tty)
622{ 622{
623 struct usb_serial_port *port = tty->driver_data; 623 struct usb_serial_port *port = tty->driver_data;
624 struct spcp8x5_private *priv = usb_get_serial_port_data(port); 624 struct spcp8x5_private *priv = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/ssu100.c b/drivers/usb/serial/ssu100.c
index 8359ec798959..b21583fa825c 100644
--- a/drivers/usb/serial/ssu100.c
+++ b/drivers/usb/serial/ssu100.c
@@ -484,7 +484,7 @@ static int ssu100_attach(struct usb_serial *serial)
484 return ssu100_initdevice(serial->dev); 484 return ssu100_initdevice(serial->dev);
485} 485}
486 486
487static int ssu100_tiocmget(struct tty_struct *tty, struct file *file) 487static int ssu100_tiocmget(struct tty_struct *tty)
488{ 488{
489 struct usb_serial_port *port = tty->driver_data; 489 struct usb_serial_port *port = tty->driver_data;
490 struct usb_device *dev = port->serial->dev; 490 struct usb_device *dev = port->serial->dev;
diff --git a/drivers/usb/serial/ti_usb_3410_5052.c b/drivers/usb/serial/ti_usb_3410_5052.c
index b2902f307b47..223e60e31735 100644
--- a/drivers/usb/serial/ti_usb_3410_5052.c
+++ b/drivers/usb/serial/ti_usb_3410_5052.c
@@ -112,7 +112,7 @@ static int ti_get_icount(struct tty_struct *tty,
112 struct serial_icounter_struct *icount); 112 struct serial_icounter_struct *icount);
113static void ti_set_termios(struct tty_struct *tty, 113static void ti_set_termios(struct tty_struct *tty,
114 struct usb_serial_port *port, struct ktermios *old_termios); 114 struct usb_serial_port *port, struct ktermios *old_termios);
115static int ti_tiocmget(struct tty_struct *tty, struct file *file); 115static int ti_tiocmget(struct tty_struct *tty);
116static int ti_tiocmset(struct tty_struct *tty, struct file *file, 116static int ti_tiocmset(struct tty_struct *tty, struct file *file,
117 unsigned int set, unsigned int clear); 117 unsigned int set, unsigned int clear);
118static void ti_break(struct tty_struct *tty, int break_state); 118static void ti_break(struct tty_struct *tty, int break_state);
@@ -1000,7 +1000,7 @@ static void ti_set_termios(struct tty_struct *tty,
1000} 1000}
1001 1001
1002 1002
1003static int ti_tiocmget(struct tty_struct *tty, struct file *file) 1003static int ti_tiocmget(struct tty_struct *tty)
1004{ 1004{
1005 struct usb_serial_port *port = tty->driver_data; 1005 struct usb_serial_port *port = tty->driver_data;
1006 struct ti_port *tport = usb_get_serial_port_data(port); 1006 struct ti_port *tport = usb_get_serial_port_data(port);
diff --git a/drivers/usb/serial/usb-serial.c b/drivers/usb/serial/usb-serial.c
index 546a52179bec..df105c6531a1 100644
--- a/drivers/usb/serial/usb-serial.c
+++ b/drivers/usb/serial/usb-serial.c
@@ -496,14 +496,14 @@ static const struct file_operations serial_proc_fops = {
496 .release = single_release, 496 .release = single_release,
497}; 497};
498 498
499static int serial_tiocmget(struct tty_struct *tty, struct file *file) 499static int serial_tiocmget(struct tty_struct *tty)
500{ 500{
501 struct usb_serial_port *port = tty->driver_data; 501 struct usb_serial_port *port = tty->driver_data;
502 502
503 dbg("%s - port %d", __func__, port->number); 503 dbg("%s - port %d", __func__, port->number);
504 504
505 if (port->serial->type->tiocmget) 505 if (port->serial->type->tiocmget)
506 return port->serial->type->tiocmget(tty, file); 506 return port->serial->type->tiocmget(tty);
507 return -EINVAL; 507 return -EINVAL;
508} 508}
509 509
diff --git a/drivers/usb/serial/usb-wwan.h b/drivers/usb/serial/usb-wwan.h
index 3ab77c5d9819..8b68fc783d5f 100644
--- a/drivers/usb/serial/usb-wwan.h
+++ b/drivers/usb/serial/usb-wwan.h
@@ -15,7 +15,7 @@ extern int usb_wwan_write_room(struct tty_struct *tty);
15extern void usb_wwan_set_termios(struct tty_struct *tty, 15extern void usb_wwan_set_termios(struct tty_struct *tty,
16 struct usb_serial_port *port, 16 struct usb_serial_port *port,
17 struct ktermios *old); 17 struct ktermios *old);
18extern int usb_wwan_tiocmget(struct tty_struct *tty, struct file *file); 18extern int usb_wwan_tiocmget(struct tty_struct *tty);
19extern int usb_wwan_tiocmset(struct tty_struct *tty, struct file *file, 19extern int usb_wwan_tiocmset(struct tty_struct *tty, struct file *file,
20 unsigned int set, unsigned int clear); 20 unsigned int set, unsigned int clear);
21extern int usb_wwan_ioctl(struct tty_struct *tty, struct file *file, 21extern int usb_wwan_ioctl(struct tty_struct *tty, struct file *file,
diff --git a/drivers/usb/serial/usb_wwan.c b/drivers/usb/serial/usb_wwan.c
index b004b2a485c3..60f942632cb4 100644
--- a/drivers/usb/serial/usb_wwan.c
+++ b/drivers/usb/serial/usb_wwan.c
@@ -79,7 +79,7 @@ void usb_wwan_set_termios(struct tty_struct *tty,
79} 79}
80EXPORT_SYMBOL(usb_wwan_set_termios); 80EXPORT_SYMBOL(usb_wwan_set_termios);
81 81
82int usb_wwan_tiocmget(struct tty_struct *tty, struct file *file) 82int usb_wwan_tiocmget(struct tty_struct *tty)
83{ 83{
84 struct usb_serial_port *port = tty->driver_data; 84 struct usb_serial_port *port = tty->driver_data;
85 unsigned int value; 85 unsigned int value;
diff --git a/drivers/usb/serial/whiteheat.c b/drivers/usb/serial/whiteheat.c
index 3f9ac88d588c..bf850139e0b8 100644
--- a/drivers/usb/serial/whiteheat.c
+++ b/drivers/usb/serial/whiteheat.c
@@ -156,7 +156,7 @@ static int whiteheat_ioctl(struct tty_struct *tty, struct file *file,
156 unsigned int cmd, unsigned long arg); 156 unsigned int cmd, unsigned long arg);
157static void whiteheat_set_termios(struct tty_struct *tty, 157static void whiteheat_set_termios(struct tty_struct *tty,
158 struct usb_serial_port *port, struct ktermios *old); 158 struct usb_serial_port *port, struct ktermios *old);
159static int whiteheat_tiocmget(struct tty_struct *tty, struct file *file); 159static int whiteheat_tiocmget(struct tty_struct *tty);
160static int whiteheat_tiocmset(struct tty_struct *tty, struct file *file, 160static int whiteheat_tiocmset(struct tty_struct *tty, struct file *file,
161 unsigned int set, unsigned int clear); 161 unsigned int set, unsigned int clear);
162static void whiteheat_break_ctl(struct tty_struct *tty, int break_state); 162static void whiteheat_break_ctl(struct tty_struct *tty, int break_state);
@@ -833,7 +833,7 @@ static int whiteheat_write_room(struct tty_struct *tty)
833 return (room); 833 return (room);
834} 834}
835 835
836static int whiteheat_tiocmget(struct tty_struct *tty, struct file *file) 836static int whiteheat_tiocmget(struct tty_struct *tty)
837{ 837{
838 struct usb_serial_port *port = tty->driver_data; 838 struct usb_serial_port *port = tty->driver_data;
839 struct whiteheat_private *info = usb_get_serial_port_data(port); 839 struct whiteheat_private *info = usb_get_serial_port_data(port);