diff options
| author | Michael Brown | 2025-04-22 15:13:45 +0200 |
|---|---|---|
| committer | Michael Brown | 2025-04-22 15:21:06 +0200 |
| commit | 0b3fc48fefd311b17b666fecf3a34688717727e8 (patch) | |
| tree | d1d462ffa6deeb2437f64b35e5aae9e117882e05 /src/interface/linux | |
| parent | [deflate] Remove userptr_t from decompression code (diff) | |
| download | ipxe-0b3fc48fefd311b17b666fecf3a34688717727e8.tar.gz ipxe-0b3fc48fefd311b17b666fecf3a34688717727e8.tar.xz ipxe-0b3fc48fefd311b17b666fecf3a34688717727e8.zip | |
[acpi] Remove userptr_t from ACPI table parsing
Simplify the ACPI table parsing code by assuming that all table
content is fully accessible via pointer dereferences.
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/interface/linux')
| -rw-r--r-- | src/interface/linux/linux_acpi.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/interface/linux/linux_acpi.c b/src/interface/linux/linux_acpi.c index 846db2f1f..a2a8bf12e 100644 --- a/src/interface/linux/linux_acpi.c +++ b/src/interface/linux/linux_acpi.c @@ -42,7 +42,7 @@ struct linux_acpi_table { /** Index */ unsigned int index; /** Cached data */ - userptr_t data; + void *data; }; /** List of cached ACPI tables */ @@ -53,9 +53,10 @@ static LIST_HEAD ( linux_acpi_tables ); * * @v signature Requested table signature * @v index Requested index of table with this signature - * @ret table Table, or UNULL if not found + * @ret table Table, or NULL if not found */ -static userptr_t linux_acpi_find ( uint32_t signature, unsigned int index ) { +static const struct acpi_header * linux_acpi_find ( uint32_t signature, + unsigned int index ) { struct linux_acpi_table *table; struct acpi_header *header; union { @@ -121,7 +122,7 @@ static userptr_t linux_acpi_find ( uint32_t signature, unsigned int index ) { err_read: free ( table ); err_alloc: - return UNULL; + return NULL; } /** |
