diff options
author | Christoph Hellwig <hch@lst.de> | 2020-07-23 08:09:08 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-24 15:41:54 -0700 |
commit | 6d04fe15f78acdf8e32329e208552e226f7a8ae6 (patch) | |
tree | 90ff9c419f8244651aa420349756cc371d539646 /kernel/extable.c | |
parent | a7b75c5a8c41445f33efb663887ff5f5c3b4454b (diff) | |
download | linux-6d04fe15f78acdf8e32329e208552e226f7a8ae6.tar.bz2 |
net: optimize the sockptr_t for unified kernel/user address spaces
For architectures like x86 and arm64 we don't need the separate bit to
indicate that a pointer is a kernel pointer as the address spaces are
unified. That way the sockptr_t can be reduced to a union of two
pointers, which leads to nicer calling conventions.
The only caveat is that we need to check that users don't pass in kernel
address and thus gain access to kernel memory. Thus the USER_SOCKPTR
helper is replaced with a init_user_sockptr function that does this check
and returns an error if it fails.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'kernel/extable.c')
0 files changed, 0 insertions, 0 deletions