USB: ftdi_sio: fix TIOCSSERIAL baud_base handling
authorJohan Hovold <jhovold@gmail.com>
Tue, 10 Jan 2012 22:33:37 +0000 (23:33 +0100)
committerSimone Willett <swillett@nvidia.com>
Thu, 9 Feb 2012 23:32:23 +0000 (15:32 -0800)
commitd7d55f41b54967769fad9aebe3c7a1744cbd0fd4
treefbbb19c0d1511dd13c234f9006e048b603a0ef42
parentd6f4da1e2f5ccff58e22880cff4024e5bca633d8
USB: ftdi_sio: fix TIOCSSERIAL baud_base handling

commit eb833a9e0972f60beb4ab8104ad7ef6bf30f02fc upstream.

Return EINVAL if new baud_base does not match the current one.

The baud_base is device specific and can not be changed. This restores
the old (pre-2005) behaviour which was changed due to a
misunderstanding regarding this fact (see
https://lkml.org/lkml/2005/1/20/84).

Reported-by: Torbj√∂rn Lofterud <torbjorn@pi.nxs.se>
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Change-Id: I672bd484e4c55708f0e97c83037c5acbc7b9e7c7
Reviewed-on: http://git-master/r/79666
Reviewed-by: Automatic_Commit_Validation_User
drivers/usb/serial/ftdi_sio.c