patch-2.4.4 linux/drivers/char/agp/agpgart_fe.c

Next file: linux/drivers/char/cyclades.c
Previous file: linux/drivers/char/Makefile
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.3/linux/drivers/char/agp/agpgart_fe.c linux/drivers/char/agp/agpgart_fe.c
@@ -879,7 +879,7 @@
 			return -ENOMEM;
 		}
 		if (copy_from_user(segment, (void *) reserve.seg_list,
-				   GFP_KERNEL)) {
+				   sizeof(agp_segment) * reserve.seg_count)) {
 			kfree(segment);
 			return -EFAULT;
 		}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)