GoogleGit

commitee1a0b2337dbae4f47263805aba0581eceb7c0b1[log][tgz]
authorRussell King <rmk+kernel@arm.linux.org.uk>Fri Sep 07 18:22:28 2012 +0100
committerEd Tam <etam@google.com>Wed Oct 16 15:21:56 2013 -0700
tree23789961f6f421c3ee74c3fa54fb1a1cadef2e94
parent2ad77439be85bd9e56b37347ecc4b8f6edfa0807[diff]
ARM: 7527/1: uaccess: explicitly check __user pointer when !CPU_USE_DOMAINS

The {get,put}_user macros don't perform range checking on the provided
__user address when !CPU_HAS_DOMAINS.

This patch reworks the out-of-line assembly accessors to check the user
address against a specified limit, returning -EFAULT if is is out of
range.

[will: changed get_user register allocation to match put_user]
[rmk: fixed building on older ARM architectures]

Reported-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Cc: stable@vger.kernel.org
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
4 files changed
tree: 23789961f6f421c3ee74c3fa54fb1a1cadef2e94
  1. .gitignore
  2. .mailmap
  3. COPYING
  4. CREDITS
  5. Documentation/
  6. Kbuild
  7. Kconfig
  8. MAINTAINERS
  9. Makefile
  10. README
  11. REPORTING-BUGS
  12. arch/
  13. block/
  14. crypto/
  15. drivers/
  16. firmware/
  17. fs/
  18. include/
  19. init/
  20. ipc/
  21. kernel/
  22. lib/
  23. mm/
  24. net/
  25. samples/
  26. scripts/
  27. security/
  28. sound/
  29. tools/
  30. usr/
  31. virt/