Commit 77c1ff39 authored by Committed by Dave Airlie
vgaarb: fix incorrect dereference of userspace pointer.
This patch corrects a userspace pointer dereference in the VGA arbiter in 184.108.40.206. copy_from_user() is used at line 822 to copy the contents of buf into kbuf, but a call to strncmp() on line 964 uses buf rather than kbuf. This problem led to a GPF in strncmp() when X was started on my x86_32 systems. X triggered the behavior with a write of "target PCI:0000:01:00.0" to /dev/vga_arbiter. The patch has been tested against 220.127.116.11 and observed to correct the GPF observed when starting X or manually writing the string "target PCI:0000:01:00.0" to /dev/vga_arbiter. Signed-off-by: Andy Getzendanner <firstname.lastname@example.org> Cc: Jesse Barnes <email@example.com> Cc: <firstname.lastname@example.org> Signed-off-by: Andrew Morton <email@example.com> Signed-off-by: Dave Airlie <firstname.lastname@example.org>
Showing with 1 addition and 1 deletion