load_LDT(pc);
mask = cpumask_of_cpu(smp_processor_id());
if (!cpus_equal(current->mm->cpu_vm_mask, mask))
- smp_call_function(flush_ldt, 0, 1, 1);
+ smp_call_function(flush_ldt, NULL, 1, 1);
preempt_enable();
#else
load_LDT(pc);
bytes = size - i;
if (bytes > PAGE_SIZE)
bytes = PAGE_SIZE;
- if (copy_to_user(ptr + i, kaddr, size - i))
+ if (copy_to_user(ptr + i, kaddr, bytes))
err = -EFAULT;
kunmap(mm->context.ldt_pages[nr]);
}