ia64/xen-unstable

changeset 7849:9f4efb238f5b

/dev/mem write function should use copy_from_user, not copy_to_user.

Signed-off-by: Vincent Hanquez <vincent@xensource.com>
author kaf24@firebug.cl.cam.ac.uk
date Wed Nov 16 11:34:19 2005 +0100 (2005-11-16)
parents 592d8f74d23d
children 54a05cd0d060
files linux-2.6-xen-sparse/arch/xen/kernel/devmem.c
line diff
     1.1 --- a/linux-2.6-xen-sparse/arch/xen/kernel/devmem.c	Wed Nov 16 11:33:13 2005 +0100
     1.2 +++ b/linux-2.6-xen-sparse/arch/xen/kernel/devmem.c	Wed Nov 16 11:34:19 2005 +0100
     1.3 @@ -79,7 +79,7 @@ static ssize_t write_mem(struct file * f
     1.4  
     1.5  	if ((v = ioremap(p, count)) == NULL)
     1.6  		return -EFAULT;
     1.7 -	if (copy_to_user(v, buf, count))
     1.8 +	if (copy_from_user(v, buf, count))
     1.9  		goto out;
    1.10  
    1.11  	written = count;