viafb: make it work on x86_64
authorHarald Welte <HaraldWelte@viatech.com>
Tue, 12 May 2009 20:19:42 +0000 (13:19 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 12 May 2009 21:11:35 +0000 (14:11 -0700)
commitee1ef82c7e6d073f881952348960bbc639687482
tree81e81d6196fb9675cff955d79caf5ed8b7288d9a
parentee83126bb17f6216e8815a4146e80032b4d80ba4
viafb: make it work on x86_64

Fix a bug in viafb on x86_64 builds (e.g. for VIA Nano CPU).

You cannot make the assumption that sizeof(unsigned int) ==
sizeof(unsigned long), so the parsing of the default mode (640x480) fails,
leading to a division by zero during insmod of the driver.

Signed-off-by: Harald Welte <HaraldWelte@viatech.com>
Cc: <JosephChan@via.com.tw>
Cc: <ScottFang@viatech.com.cn>
Cc: Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/video/via/viafbdev.c