diff options
author | Alan Cox <alan@redhat.com> | 2007-11-07 04:27:34 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-11-07 07:14:24 -0500 |
commit | d0127539ea9b5fcfe1a1d7d4d57f12384da5190c (patch) | |
tree | ea533cf6c337c9d2fdd9641fb6e67bf895e3b5c8 /drivers/net/ppp_async.c | |
parent | 0fc00e2440b717e19bab1ae0015f03936bdf7967 (diff) |
[TTY]: Use tty_mode_ioctl() in network drivers.
We conciously make a change here - we permit mode and speed setting to
be done in things like SLIP mode. There isn't actually a technical
reason to disallow this. It's usually a silly thing to do but we can
do it and soemone might wish to do so.
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ppp_async.c')
-rw-r--r-- | drivers/net/ppp_async.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/net/ppp_async.c b/drivers/net/ppp_async.c index 27f5b904f48e..8d278c87ba48 100644 --- a/drivers/net/ppp_async.c +++ b/drivers/net/ppp_async.c | |||
@@ -309,16 +309,11 @@ ppp_asynctty_ioctl(struct tty_struct *tty, struct file *file, | |||
309 | err = 0; | 309 | err = 0; |
310 | break; | 310 | break; |
311 | 311 | ||
312 | case TCGETS: | ||
313 | case TCGETA: | ||
314 | err = n_tty_ioctl(tty, file, cmd, arg); | ||
315 | break; | ||
316 | |||
317 | case TCFLSH: | 312 | case TCFLSH: |
318 | /* flush our buffers and the serial port's buffer */ | 313 | /* flush our buffers and the serial port's buffer */ |
319 | if (arg == TCIOFLUSH || arg == TCOFLUSH) | 314 | if (arg == TCIOFLUSH || arg == TCOFLUSH) |
320 | ppp_async_flush_output(ap); | 315 | ppp_async_flush_output(ap); |
321 | err = n_tty_ioctl(tty, file, cmd, arg); | 316 | err = tty_perform_flush(tty, arg); |
322 | break; | 317 | break; |
323 | 318 | ||
324 | case FIONREAD: | 319 | case FIONREAD: |
@@ -329,7 +324,8 @@ ppp_asynctty_ioctl(struct tty_struct *tty, struct file *file, | |||
329 | break; | 324 | break; |
330 | 325 | ||
331 | default: | 326 | default: |
332 | err = -ENOIOCTLCMD; | 327 | /* Try the various mode ioctls */ |
328 | err = tty_mode_ioctl(tty, file, cmd, arg); | ||
333 | } | 329 | } |
334 | 330 | ||
335 | ap_put(ap); | 331 | ap_put(ap); |