Retrieve address region information for the specified logical partition address region.
result = lv1_query_logical_partition_address_region_info( /*IN*/ 0,
/*OUT*/ &start_address, &size, &access_right, &max_page_size, &flags);
| Inputs | |
|---|---|
| Register | Description |
| R3 | 0 - logical partition address region (lpar) |
| Outputs | |
| Register | Description |
| R3 | status: 0 = LV1_SUCCESS |
| R4 | start_address - start address of logical partition address region |
| R5 | size - size of logical partition address region |
| R6 | access_right - ? |
| R7 | max_page_size - maximum page size of logical partition address region? or order of the allocation? |
| R8 | flags - ? |
Notes:
Only the “max_page_size” parameter is currently used by the Kernel, in “mm.c”
| Register | Hex | Decimal | Comment |
|---|---|---|---|
| R3 | 0×00000000 | (0) | value seems not to affect result |
| Outputs | |||
| R3 | 0×00000000 | (0) | LV1_SUCCESS |
| R4 | 0×00000000 | (0) | start_address |
| R5 | 0×08000000 | (134217728) | size - 128 Mb |
| R6 | 0×00000003 | (3) | access_right |
| R7 | 0x0000001b | (27) | max_page_size |
| R8 | 0×00000008 | (8) | flags |
This suggests lpar 0 is a special lpar representing the first 128MB of RAM that are always available at boot time. In this case, max_page_size seems to correspond to the order of the allocation (2**27 = 128 MB). The meaning of access_right and flags is unknown.
Also works on a lpar obtained from lv1_allocate_memory, for example
lv1_allocate_memory(4096 /* size */, 12 /* page size */, 0, 0, &lpar, &muid); lv1_query_logical_partition_address_region_info(lpar, &start_address, &size, &access_right, &max_page_size, &flags);
returns:
| Register | Hex | Decimal | Comment |
|---|---|---|---|
| R3 | 0x30000001f000 | (0) | lpar obtained from lv1_allocate_memory |
| Outputs | |||
| R3 | 0×00000000 | (0) | LV1_SUCCESS |
| R4 | 0x30000001f000 | (0) | start_address (same as input lpar) |
| R5 | 0×00001000 | (4096) | size - 4kB |
| R6 | 0×00000003 | (3) | access_right |
| R7 | 0x0000000c | (12) | max_page_size |
| R8 | 0×00000000 | (0) | flags |