Hello,
On 07.07.20 21:40, Parfait Tokponnon wrote:
> Hello,
> I want to run Genode on Windriver Simics
> <https://www.windriver.com/products/simics/>.
> I've just created a disk image with the demo scenario from a freshly cloned
> Genode.
> It crashes with the following error.
>
>> page fault, pd='init -> drivers -> acpi_drv' thread='ep' cpu=0
>> ip=0x1011062 address=0xbff00000 stack pointer=0x401fbbc0 qualifiers=0x4
>> irUwp reason=1
it looks like that not all memory is mapped for parsing the table.
>
> The IP:0x1010ab2 resolves to
> /home/parfait/git/genode20.05/repos/os/src/drivers/acpi/acpi.cc:254 where I
> can read following :
>
> Fadt(addr_t a) : Genode::Mmio(a)
>> {
>> features = read<Fadt::Feature_flags>();
>> reset_type = read<Fadt::Reset_reg_type>();
>> 254 reset_addr = read<Fadt::Reset_reg_addr>();
>> reset_value = read<Fadt::Reset_value>();
>> }
>>
> It seems like there is an issue with the parsing of the acpi table,
> especially the FADT.
I would suggest to set the 'verbose' variable to 'true' within the code.
Additionally, I would suggest to monitor the memory ranges which get attached
during parsing all the tables.
Attached patch gives you some output alike:
Genode 20.05-83-g75f3012ade <local changes>
471 MiB RAM and 63253 caps assigned to init
[init -> test-pci] --- Platform test started ---
[init -> acpi_drv] Warning: attach memory - 0x1ffe2000+0x1000
[init -> acpi_drv] table mapped 'RSDT' at 0x9ffe20b8 (from 0x1ffe20b8) size 0x34
[init -> acpi_drv] Warning: attach memory - 0x1ffe1000+0x1000
[init -> acpi_drv] table mapped 'FACP' at 0x9ffe1ed8 (from 0x1ffe1ed8) size 0xf4
[init -> acpi_drv] Warning: attach memory - 0x1ffe0000+0x1000
[init -> acpi_drv] Warning: attach memory - 0x1ffe0000+0x2000
[init -> acpi_drv] table mapped 'DSDT' at 0x9ffe0040 (from 0x1ffe0040) size
0x1e98
The attached memory ranges should comprise the whole table, e.g for FADT/FACP
of interest is:
[init -> acpi_drv] Warning: attach memory - 0x1ffe1000+0x1000
[init -> acpi_drv] table mapped 'FACP' at 0x9ffe1ed8 (from 0x1ffe1ed8) size 0xf4
If for your FACP/FADT table not the whole memory is mapped, you will have to
look into
repos/os/src/drivers/acpi/memory.h to understand and fix the issue.
Hope it helps,
Alex.
--
Alexander Boettcher
Genode Labs
https://www.genode-labs.com - https://www.genode.org
Genode Labs GmbH - Amtsgericht Dresden - HRB 28424 - Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth
diff --git a/repos/os/src/drivers/acpi/acpi.cc b/repos/os/src/drivers/acpi/acpi.cc
index d620c1d20e..937400abd1 100644
--- a/repos/os/src/drivers/acpi/acpi.cc
+++ b/repos/os/src/drivers/acpi/acpi.cc
@@ -32,7 +32,7 @@
using namespace Genode;
/* enable debugging output */
-static const bool verbose = false;
+static const bool verbose = true;
/**
diff --git a/repos/os/src/drivers/acpi/memory.h b/repos/os/src/drivers/acpi/memory.h
index e434037938..30822346c8 100644
--- a/repos/os/src/drivers/acpi/memory.h
+++ b/repos/os/src/drivers/acpi/memory.h
@@ -187,6 +187,8 @@ class Acpi::Memory
_range.metadata((void *)loop_region.base())->connection->dataspace(),
loop_region.base() - _io_region->base(), loop_region.size());
+ Genode::warning("attach memory - ", Genode::Hex(loop_region.base() - _io_region->base()), "+", Genode::Hex(loop_region.size()));
+
return _acpi_ptr(req_base);
}
_______________________________________________
Genode users mailing list
[email protected]
https://lists.genode.org/listinfo/users