Hi Jan-Marc,
in your nuc8i7.c, there is:
.debug_console = {
.address = 0x3f8,
.type = JAILHOUSE_CON_TYPE_8250,
.flags = JAILHOUSE_CON_ACCESS_PIO |
JAILHOUSE_CON_REGDIST_1,
},
So you define the (debug) console here to be ttyS0
And that is nowhere in the PIO regions there as far as I can see.
IIRC you need to have a matching set and for qemu we did route it to ttyS1
like so:
Correct number of
struct jailhouse_pio pio_regions[14];
[...]
.debug_console = {
.address = 0x2f8,
.type = JAILHOUSE_CON_TYPE_8250,
.flags = JAILHOUSE_CON_ACCESS_PIO |
JAILHOUSE_CON_REGDIST_1,
},
[...]
.pio_regions = {
/* Port I/O: 0000-001f : dma1 */
[...]
/* Port I/O: 02f8-02ff : serial */
PIO_RANGE(0x2f8, 0x8),
I don't know how to route this to a USB port ... check the ioports when
the usb adaptor is plugged in
on the host and adapt this?
Example for qemu is here:
https://git.automotivelinux.org/AGL/meta-agl-devel/tree/meta-agl-jailhouse/recipes-extended/jailhouse/files/qemu-agl.c
Best regards,
Jan-Simon
------
Jan-Simon Möller
On Wed, Sep 9, 2020 at 4:13 PM Jan-Marc Stranz <[email protected]>
wrote:
> My serial port is "/dev/ttyUSB0".
> I've connected this with an other Linux PC and tested it with "minicom".
>
> But if I start Jailhouse with "jailhouse enable ..." then I do not receive
> any messages via this serial port.
> Do jailhouse use "/dev/ttyUSB*"?
>
> Jan-Marc Stranz schrieb am Mittwoch, 9. September 2020 um 15:55:31 UTC+2:
>
>> I got it!
>> The entry msut be "memmap=0x5200000\$0x3a000000"(only one "\").
>>
>> The command "less /proc/iomem" then shows the following:
>> ...
>> 3a000000-3f1fffff : Reserved
>> ...
>>
>> So far everything is fine.
>>
>> I've also tried "jailhouse enable nuc8i7.cell"; the system freezes.
>> So now I have to adjust the cell configuration.
>> It could be that I need your help later.
>>
>>
>> [email protected] schrieb am Mittwoch, 9. September 2020 um 15:35:09
>> UTC+2:
>>
>>> On 09.09.20 15:21, Jan-Marc Stranz wrote:
>>> > I change the kernel command line directly in the "grub.cfg" file; i.e.
>>> > the resulting command line is identical to the line specified in the
>>> file.
>>> >
>>> > I've also tried "memmap=0x5200000\\\$0x3a000000" with the same result.
>>> >
>>>
>>> If the resulting command line of the kernel is actually
>>> "memmap=0x5200000$0x3a000000" now (directly in grub.conf, you must only
>>> quote once: "\$"), you either have some other resources at 0x3a000000,
>>> not just RAM. Check what /proc/iomem reports - when that parameter is
>>> not in use. Or your system has less than 512 MB RAM (unlikely)...
>>>
>>> Maybe share your generated config.c.
>>>
>>> Jan
>>>
>>> > [email protected] schrieb am Mittwoch, 9. September 2020 um
>>> 15:10:03
>>> > UTC+2:
>>> >
>>> > On 09.09.20 14:58, Jan-Marc Stranz wrote:
>>> > > I have good news.
>>> > > I now have a Linux system on an Intel NUC8I7 with IOMMU support!.
>>> > >
>>> > > The hardware check of Jalihouse works and I was able to create a
>>> > > configuration for the root cell with "jailhouse config create
>>> > nuc8i7.c".
>>> > > (I've attached this configuration.)
>>> > > I inserted this cell configuration into the Yocto build system and
>>> > the
>>> > > file "nuc8i7.cell" is created and installed under
>>> > > "/usr/share/jailhouse/cells".
>>> > >
>>> > > In order to start Jailhouse with "jailhouse enable nuc8i7.cell" I
>>> > > extended the Linux command line with:
>>> > > intel_iommu=off memmap=0x5200000$0x3a000000
>>> > >
>>> > > I took the entry "memmap = ..." from the generated configuration
>>> > "nuc8i7.c".
>>> > >
>>> > > While re-booting the system it gets stuck with the following
>>> message:
>>> > > Kernel panic - System is deadlocked on memory
>>> > >
>>> > > The kernel parameter "memmap = ..." should actually work, because
>>> > 82M
>>> > > of the following area is reserved:
>>> > >
>>> > > /* MemRegion: 00100000-39ffffff : System RAM */
>>> > > {
>>> > > .phys_start = 0x100000,
>>> > > .virt_start = 0x100000,
>>> > > .size = 0x39f00000,
>>> > > .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE |
>>> > > JAILHOUSE_MEM_EXECUTE | JAILHOUSE_MEM_DMA,
>>> > > }
>>> > >
>>> > > What could I do?
>>> > >
>>> >
>>> > Most probably, that "$" in the kernel command line is prematurely
>>> > resolved as "$0" or so and the resulting kernel command line is
>>> > invalid.
>>> > Depending in how you inject the parameter, make sure quoting or
>>> > escaping
>>> > ("\$", or even more) is correctly done and validate the output of the
>>> > kernel.
>>> >
>>> > Jan
>>> >
>>> > --
>>> > Siemens AG, Corporate Technology, CT RDA IOT SES-DE
>>> > Corporate Competence Center Embedded Linux
>>> >
>>> > --
>>> > You received this message because you are subscribed to the Google
>>> > Groups "Jailhouse" group.
>>> > To unsubscribe from this group and stop receiving emails from it, send
>>> > an email to [email protected]
>>> > <mailto:[email protected]>.
>>> > To view this discussion on the web visit
>>> >
>>> https://groups.google.com/d/msgid/jailhouse-dev/618bbad6-8276-476b-934e-ea765b28a796n%40googlegroups.com
>>> > <
>>> https://groups.google.com/d/msgid/jailhouse-dev/618bbad6-8276-476b-934e-ea765b28a796n%40googlegroups.com?utm_medium=email&utm_source=footer>.
>>>
>>>
>>> --
>>> Siemens AG, Corporate Technology, CT RDA IOT SES-DE
>>> Corporate Competence Center Embedded Linux
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Jailhouse" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jailhouse-dev/42b8fa41-88cc-4907-bdce-44474b98d8acn%40googlegroups.com
> <https://groups.google.com/d/msgid/jailhouse-dev/42b8fa41-88cc-4907-bdce-44474b98d8acn%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
--
You received this message because you are subscribed to the Google Groups
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jailhouse-dev/CADja47MrkFH%2BYS%2BqA%2Bs5PCMRLb1EWriG5yTc9F%2Bt9tfTEw00mw%40mail.gmail.com.