OSDN Git Service

video: kyro: fix incorrect sizes when copying to userspace
authorSasha Levin <sasha.levin@oracle.com>
Tue, 19 Nov 2013 19:25:36 +0000 (14:25 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 8 Dec 2013 15:29:27 +0000 (07:29 -0800)
commitca77581ebaa42e9279a231fbcb98ee031c37fe3a
treee0f1abd323bbaff28e1d1c0079c25826476738e6
parentf99510dc9a9b63ba8131e1e5eb70884db122a1bc
video: kyro: fix incorrect sizes when copying to userspace

commit 2ab68ec927310dc488f3403bb48f9e4ad00a9491 upstream.

kyro would copy u32s and specify sizeof(unsigned long) as the size to copy.

This would copy more data than intended and cause memory corruption and might
leak kernel memory.

Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/video/kyro/fbdev.c