linux-stable/arch/x86/um/asm
Al Viro c693cc4676 saner calling conventions for csum_and_copy_..._user()
All callers of these primitives will
	* discard anything we might've copied in case of error
	* ignore the csum value in case of error
	* always pass 0xffffffff as the initial sum, so the
resulting csum value (in case of success, that is) will never be 0.

That suggest the following calling conventions:
	* don't pass err_ptr - just return 0 on error.
	* don't bother with zeroing destination, etc. in case of error
	* don't pass the initial sum - just use 0xffffffff.

This commit does the minimal conversion in the instances of csum_and_copy_...();
the changes of actual asm code behind them are done later in the series.
Note that this asm code is often shared with csum_partial_copy_nocheck();
the difference is that csum_partial_copy_nocheck() passes 0 for initial
sum while csum_and_copy_..._user() pass 0xffffffff.  Fortunately, we are
free to pass 0xffffffff in all cases and subsequent patches will use that
freedom without any special comments.

A part that could be split off: parisc and uml/i386 claimed to have
csum_and_copy_to_user() instances of their own, but those were identical
to the generic one, so we simply drop them.  Not sure if it's worth
a separate commit...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2020-08-20 15:45:15 -04:00
..
apic.h um: asm/apic.h is there only to shadow the x86 one... 2011-11-02 14:15:22 +01:00
arch_hweight.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
archparam.h
barrier.h um: Use real DMA barriers 2019-09-15 21:37:14 +02:00
checksum.h unify generic instances of csum_partial_copy_nocheck() 2020-08-20 15:45:14 -04:00
checksum_32.h saner calling conventions for csum_and_copy_..._user() 2020-08-20 15:45:15 -04:00
checksum_64.h um/x86: merge 32 and 64bit variants of checksum.h 2012-10-09 22:28:16 +02:00
desc.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
elf.h x86: Clean up 'sizeof x' => 'sizeof(x)' 2018-10-29 07:13:28 +01:00
irq_vectors.h um: irq_vectors.h just shadows x86 one 2011-11-02 14:15:24 +01:00
mm_context.h
module.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
processor.h um: Implement cpu_relax() as ndelay(1) for time-travel 2020-03-29 23:29:56 +02:00
processor_32.h treewide: remove current_text_addr 2018-10-31 08:54:12 -07:00
processor_64.h treewide: remove current_text_addr 2018-10-31 08:54:12 -07:00
ptrace.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
required-features.h um: required-features.h is there only to shadow x86 one... 2011-11-02 14:15:23 +01:00
segment.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
syscall.h syscall_get_arch: add "struct task_struct *" argument 2019-03-20 21:12:36 -04:00
vm-flags.h mm/vma: define a default value for VM_DATA_DEFAULT_FLAGS 2020-04-10 15:36:21 -07:00