mtd: speedtest: fix integer overflow
authorDavid Lambert <dave@lambsys.com>
Mon, 7 Mar 2011 10:00:46 +0000 (12:00 +0200)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Fri, 11 Mar 2011 14:22:49 +0000 (14:22 +0000)
commite70727e442eb61581f836a9a0ca0c3b70d8a3ff2
tree52691fbc86e772642978cc09a32eaaf807ef1016
parent5d9d9936209e589569a97985285b3282310cf2db
mtd: speedtest: fix integer overflow

32-bit integers used in 'calc_speed()' may overflow and lead to
incorrect results. Use 64-bit integers instead.

Signed-off-by: David Lambert <dave@lambsys.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/tests/mtd_speedtest.c