Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 06bc0f4a authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge branch 'x86-build-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull x86/build changes from Ingo Molnar:
 "Misc smaller improvements"

* 'x86-build-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86, boot: Move intcall() to the .inittext section
  x86, boot: Use .code16 instead of .code16gcc
  x86, sparse: Do not force removal of __user when calling copy_to/from_user_nocheck()
parents 4cd41569 6f34152f
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
/* -----------------------------------------------------------------------
 *
 *   Copyright 2009 Intel Corporation; author H. Peter Anvin
 *   Copyright 2009-2014 Intel Corporation; author H. Peter Anvin
 *
 *   This file is part of the Linux kernel, and is made available under
 *   the terms of the GNU General Public License version 2 or (at your
@@ -13,8 +13,8 @@
 * touching registers they shouldn't be.
 */

	.code16gcc
	.text
	.code16
	.section ".inittext","ax"
	.globl	intcall
	.type	intcall, @function
intcall:
+11 −11
Original line number Diff line number Diff line
@@ -14,7 +14,7 @@
 * Memory copy routines
 */

	.code16gcc
	.code16
	.text

GLOBAL(memcpy)
@@ -30,7 +30,7 @@ GLOBAL(memcpy)
	rep; movsb
	popw	%di
	popw	%si
	ret
	retl
ENDPROC(memcpy)

GLOBAL(memset)
@@ -45,25 +45,25 @@ GLOBAL(memset)
	andw	$3, %cx
	rep; stosb
	popw	%di
	ret
	retl
ENDPROC(memset)

GLOBAL(copy_from_fs)
	pushw	%ds
	pushw	%fs
	popw	%ds
	call	memcpy
	calll	memcpy
	popw	%ds
	ret
	retl
ENDPROC(copy_from_fs)

GLOBAL(copy_to_fs)
	pushw	%es
	pushw	%fs
	popw	%es
	call	memcpy
	calll	memcpy
	popw	%es
	ret
	retl
ENDPROC(copy_to_fs)

#if 0 /* Not currently used, but can be enabled as needed */
@@ -71,17 +71,17 @@ GLOBAL(copy_from_gs)
	pushw	%ds
	pushw	%gs
	popw	%ds
	call	memcpy
	calll	memcpy
	popw	%ds
	ret
	retl
ENDPROC(copy_from_gs)

GLOBAL(copy_to_gs)
	pushw	%es
	pushw	%gs
	popw	%es
	call	memcpy
	calll	memcpy
	popw	%es
	ret
	retl
ENDPROC(copy_to_gs)
#endif
+2 −2
Original line number Diff line number Diff line
@@ -204,13 +204,13 @@ int __copy_in_user(void __user *dst, const void __user *src, unsigned size)
static __must_check __always_inline int
__copy_from_user_inatomic(void *dst, const void __user *src, unsigned size)
{
	return __copy_from_user_nocheck(dst, (__force const void *)src, size);
	return __copy_from_user_nocheck(dst, src, size);
}

static __must_check __always_inline int
__copy_to_user_inatomic(void __user *dst, const void *src, unsigned size)
{
	return __copy_to_user_nocheck((__force void *)dst, src, size);
	return __copy_to_user_nocheck(dst, src, size);
}

extern long __copy_user_nocache(void *dst, const void __user *src,