Hi Peng,
Adding the ethernet card requires adding the 0 ASID in the vm.camkes file that I mentioned in the previous email.
Hi Peng,
Which hardware are you using to run the image? This project has only been tested on the TK1-SOM made by Colorado Engineering. The ethernet port doesn't work as the version of Linux that we use doesn't support it. As for your second question, we configure the IOMMU to only let Linux use the emmc device and USB device on the TK1-SOM. The error is caused because Linux is trying to access a SD card device that it isn't authorized to access. The TK1-SOM doesn't have any SD card hardware so camkes doesn't set up access.
If you want to use the Insecure config then you will need to modify apps/vm/vm.camkes and add the right ID to vm.smmu on line 443. To find out which ID to add we take the ID:98 from your Address translation error and look it up in the TK1 technical reference manual. In the memory controller section of the manual there is a "Error Data Capture: Status" section that starts on page 716. Using the table there you can look up ID:98 to see that it belongs to the SWGROUP sdmmc3a. We can now take this and look in seL4 ("kernel/include/plat/tk1/
plat/machine/smmu.h") to find the relevant ASID. From the list of ASIDs we see that SMMU_SDMMC3A_ASID is defined as 23. This is the ID that needs to be added to the vm.smmu array in vm.camkes.
Hope this helps,
Regards,
Kent.
From: Devel <devel-bounces@sel4.systems> on behalf of PX <seawolf.peng@gmail.com>
Sent: Friday, January 13, 2017 9:03 AM
To: devel@sel4.systems
Subject: [seL4] quesitons about TK1 VMMHi,
I built a TK1 ARM VMM image from the source code SEL4PROJ/camkes-vm-manifest in GitHub. I have some quesitons about the tk1_vmlinux.
Question 1: If I use the original tk1_vm_defconfig, the eth0 does not work in vm. Is the tk1_vm_linux in default not supposed to access Ethernet card? Hpw do I access Ethernet card in this case?
Question 2: If I change the VM conifg into insecure, CONFIG_TK1_INSECURE=y, the VM can not get booted, I get "SMMU address translation error". The error message is appended as follows:
"
[ 10.503932] mmc1: Invalid maximum block size, assuming 512 bytes
[ 10.566465] mmc1: SDHCI controller on 700b0400.sdhci [700b0400.sdhci] using ADMA 64-bit
SMMU Address translation error:
ID: 98 address: 0xae609000 type: 6 direction: 0x0
IOPT permission: read 0x0 write 0x0 nonsecure 0x0
[ 10.617123] mmc1: ADMA error"
Is this error caused by bugs in source code or my wrong config? if the later case, what's the correct config?
thanks
Peng