summaryrefslogtreecommitdiffstats
path: root/src/interface/linux/linux_umalloc.c
diff options
context:
space:
mode:
authorMichael Brown2025-04-20 18:26:48 +0200
committerMichael Brown2025-04-20 18:28:33 +0200
commitb65f67d443d213bbaf9d7859649f25920e6d6785 (patch)
treec9ed4eb4bd7a2d170990eed94a9f682ae09a657e /src/interface/linux/linux_umalloc.c
parent[uaccess] Add explicit casts to and from userptr_t where needed (diff)
downloadipxe-b65f67d443d213bbaf9d7859649f25920e6d6785.tar.gz
ipxe-b65f67d443d213bbaf9d7859649f25920e6d6785.tar.xz
ipxe-b65f67d443d213bbaf9d7859649f25920e6d6785.zip
[uaccess] Change userptr_t to be a pointer type
The original motivation for the userptr_t type was to be able to support a pure 16-bit real-mode memory model in which a segment:offset value could be encoded as an unsigned long, with corresponding copy_from_user() and copy_to_user() functions used to perform real-mode segmented memory accesses. Since this memory model was first created almost twenty years ago, no serious effort has been made to support a pure 16-bit mode of operation for iPXE. The constraints imposed by the memory model are becoming increasingly cumbersome to work within: for example, the parsing of devicetree structures is hugely simplified by being able to use and return direct pointers to the names and property values. The devicetree code therefore relies upon virt_to_user(), which is nominally illegal under the userptr_t memory model. Drop support for the concept of a memory location that cannot be reached through a straightforward pointer dereference, by redefining userptr_t to be a simple pointer type. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/interface/linux/linux_umalloc.c')
0 files changed, 0 insertions, 0 deletions