staging: most: usb: fix size overflow
authorAndrey Shvetsov <andrey.shvetsov@k2l.de>
Fri, 7 Apr 2017 13:38:39 +0000 (15:38 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 8 Apr 2017 10:41:40 +0000 (12:41 +0200)
commit5c13155d190464fade0344e16b6341f18af25f1f
tree11433e65b1b9331132922322b70421f9ecaeb6b1
parentf500192890c7c6745a92b677f5f69e58a2d60715
staging: most: usb: fix size overflow

Despite the user payload may not be bigger than (2**16 - 1) bytes, the
final packet size may be bigger because of the gap space needed for the
controller.

This patch removes the temporary variables of the type u16 that are used
to hold the offsets that may be bigger than 2**16 bytes.

Signed-off-by: Andrey Shvetsov <andrey.shvetsov@k2l.de>
Signed-off-by: Christian Gromm <christian.gromm@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/most/hdm-usb/hdm_usb.c