public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
* linux-next: manual merge of the uml tree with the asm-generic tree
@ 2021-08-26 23:02 Stephen Rothwell
  0 siblings, 0 replies; only message in thread
From: Stephen Rothwell @ 2021-08-26 23:02 UTC (permalink / raw)
  To: Richard Weinberger, Arnd Bergmann
  Cc: Christoph Hellwig, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 1633 bytes --]

Hi all,

Today's linux-next merge of the uml tree got a conflict in:

  arch/um/kernel/skas/uaccess.c

between commit:

  f27180dd63e1 ("asm-generic/uaccess.h: remove __strncpy_from_user/__strnlen_user")

from the asm-generic tree and commit:

  043f5d3ffaf6 ("um: Remove set_fs")

from the uml tree.

I fixed it up (I think - see below) and can carry the fix as
necessary. This is now fixed as far as linux-next is concerned, but any
non trivial conflicts should be mentioned to your upstream maintainer
when your tree is submitted for merging.  You may also want to consider
cooperating with the maintainer of the conflicting tree to minimise any
particularly complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc arch/um/kernel/skas/uaccess.c
index a509be911026,dda2439ab550..000000000000
--- a/arch/um/kernel/skas/uaccess.c
+++ b/arch/um/kernel/skas/uaccess.c
@@@ -194,14 -184,6 +184,9 @@@ long strncpy_from_user(char *dst, cons
  	long n;
  	char *ptr = dst;
  
 +	if (!access_ok(src, 1))
 +		return -EFAULT;
 +
- 	if (uaccess_kernel()) {
- 		strncpy(dst, (__force void *) src, count);
- 		return strnlen(dst, count);
- 	}
- 
  	n = buffer_op((unsigned long) src, count, 0, strncpy_chunk_from_user,
  		      &ptr);
  	if (n != 0)
@@@ -243,12 -220,6 +223,9 @@@ long strnlen_user(const char __user *st
  {
  	int count = 0, n;
  
 +	if (!access_ok(str, 1))
 +		return -EFAULT;
 +
- 	if (uaccess_kernel())
- 		return strnlen((__force char*)str, len) + 1;
- 
  	n = buffer_op((unsigned long) str, len, 0, strnlen_chunk, &count);
  	if (n == 0)
  		return count + 1;

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-08-26 23:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-08-26 23:02 linux-next: manual merge of the uml tree with the asm-generic tree Stephen Rothwell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox