poke: use phys_addr_t for mem_map_args's physical_address field
This is needed to fix usage of POKE_GET_PHYSICAL_ADDRESS on x86 32 bits (with PAE). Change-Id: Ic00185ec7fcf9b6666ad6169a752d8b8edd2b61b Reviewed-on: https://review.haiku-os.org/c/haiku/+/5975 Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org> Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
This commit is contained in:
parent
42aa87de9e
commit
59b54f3810
@ -60,7 +60,7 @@ typedef struct {
|
||||
uint32 signature;
|
||||
area_id area;
|
||||
const char* name;
|
||||
void* physical_address;
|
||||
phys_addr_t physical_address;
|
||||
size_t size;
|
||||
uint32 flags;
|
||||
uint32 protection;
|
||||
|
@ -285,8 +285,7 @@ poke_control(void* cookie, uint32 op, void* arg, size_t length)
|
||||
return B_BAD_VALUE;
|
||||
|
||||
result = get_memory_map(ioctl.address, ioctl.size, &table, 1);
|
||||
ioctl.physical_address = (void*)(addr_t)table.address;
|
||||
// TODO: mem_map_args::physical_address should be phys_addr_t!
|
||||
ioctl.physical_address = table.address;
|
||||
ioctl.size = table.size;
|
||||
if (user_memcpy(arg, &ioctl, sizeof(mem_map_args)) != B_OK)
|
||||
return B_BAD_ADDRESS;
|
||||
|
Loading…
Reference in New Issue
Block a user