diff options
Diffstat (limited to 'drivers/net/hamradio/mkiss.c')
| -rw-r--r-- | drivers/net/hamradio/mkiss.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/hamradio/mkiss.c b/drivers/net/hamradio/mkiss.c index 0e4f23531140..4c628393c8b1 100644 --- a/drivers/net/hamradio/mkiss.c +++ b/drivers/net/hamradio/mkiss.c | |||
| @@ -923,14 +923,13 @@ static long mkiss_compat_ioctl(struct tty_struct *tty, struct file *file, | |||
| 923 | * a block of data has been received, which can now be decapsulated | 923 | * a block of data has been received, which can now be decapsulated |
| 924 | * and sent on to the AX.25 layer for further processing. | 924 | * and sent on to the AX.25 layer for further processing. |
| 925 | */ | 925 | */ |
| 926 | static unsigned int mkiss_receive_buf(struct tty_struct *tty, | 926 | static void mkiss_receive_buf(struct tty_struct *tty, const unsigned char *cp, |
| 927 | const unsigned char *cp, char *fp, int count) | 927 | char *fp, int count) |
| 928 | { | 928 | { |
| 929 | struct mkiss *ax = mkiss_get(tty); | 929 | struct mkiss *ax = mkiss_get(tty); |
| 930 | int bytes = count; | ||
| 931 | 930 | ||
| 932 | if (!ax) | 931 | if (!ax) |
| 933 | return -ENODEV; | 932 | return; |
| 934 | 933 | ||
| 935 | /* | 934 | /* |
| 936 | * Argh! mtu change time! - costs us the packet part received | 935 | * Argh! mtu change time! - costs us the packet part received |
| @@ -940,7 +939,7 @@ static unsigned int mkiss_receive_buf(struct tty_struct *tty, | |||
| 940 | ax_changedmtu(ax); | 939 | ax_changedmtu(ax); |
| 941 | 940 | ||
| 942 | /* Read the characters out of the buffer */ | 941 | /* Read the characters out of the buffer */ |
| 943 | while (bytes--) { | 942 | while (count--) { |
| 944 | if (fp != NULL && *fp++) { | 943 | if (fp != NULL && *fp++) { |
| 945 | if (!test_and_set_bit(AXF_ERROR, &ax->flags)) | 944 | if (!test_and_set_bit(AXF_ERROR, &ax->flags)) |
| 946 | ax->dev->stats.rx_errors++; | 945 | ax->dev->stats.rx_errors++; |
| @@ -953,8 +952,6 @@ static unsigned int mkiss_receive_buf(struct tty_struct *tty, | |||
| 953 | 952 | ||
| 954 | mkiss_put(ax); | 953 | mkiss_put(ax); |
| 955 | tty_unthrottle(tty); | 954 | tty_unthrottle(tty); |
| 956 | |||
| 957 | return count; | ||
| 958 | } | 955 | } |
| 959 | 956 | ||
| 960 | /* | 957 | /* |
