imx6-sabrelite

190 views
Skip to first unread message

Shivakumar Gangannavar

unread,
May 6, 2016, 9:01:42 AM5/6/16
to sukant...@gmail.com, xvisor...@googlegroups.com
Hello All,

I want to run xvisor on imx6-sabrelite board.

I have downloaded xvisor-master code from GIT[https://github.com/xvisor/xvisor] and built all the binaries of xvisor for imx6-sabrelite board.

In the imx6-sabrelite.txt, its mentioned that user has to copy all the binaries from xvisor to boot partition on sabre sd card.

I'm new to sabre environment, so just wanted to know where to copy these[xvisor] binaries onto sdcard.

there are four file systems mounted on development environment.

1) vendor
2) cache
3) data
4) 544mb filesystem

So can anyone help me to boot xvisor on sabrelite board.

Below are the steps where I have stuck
===============================
  [12. Copy and rename the host and guest device tree to boot partition of SD card]
  # cp -f build/arch/arm/board/generic/dts/imx6/sabrelite-a9/one_guest_sabrelite-a9.dtb <path_to_mounted_boot_partition_of_sd_card>/vmm-imx6q-sabrelite.dtb
  # cp -f build/sabrelite-a9.dtb <path_to_mounted_boot_partition_of_sd_card>/

  [13. Copy the basic firmware, the nor_flash.list and the cmdlist on the SD card boot partition]
  # cp -f build/tests/arm32/sabrelite-a9/basic/firmware.bin.patched <path_to_mounted_boot_partition_of_sd_card>/
  # cp -f tests/arm32/sabrelite-a9/linux/nor_flash.list <path_to_mounted_boot_partition_of_sd_card>/
  # cp -f tests/arm32/sabrelite-a9/linux/cmdlist <path_to_mounted_boot_partition_of_sd_card>/

  [16. Copy the _patched_ kernel image, and its device tree to the SD card boot partition]
  # cp -f <linux_build_directory>/arch/arm/boot/Image <path_to_mounted_boot_partition_of_sd_card>/
  # cp -f build/vexpress-v2p-ca9.dtb <path_to_mounted_boot_partition_of_sd_card>/

  [12. Copy the boot script to boot partition of SD card]
  # cp -f build/6x_bootscript <path_to_mounted_boot_partition_of_sd_card>/



Best Regards,
Shivakumar SG
+91-9972222662
in.linkedin.com/in/shivakumargangannavar

Jean Guyomarc'h

unread,
May 6, 2016, 9:35:56 AM5/6/16
to xvisor...@googlegroups.com
Hi Shivakumar,

I'm not sure to understand what you mean by "sabre environment".

The parition you should use to store Xvisor's file actually
depends on your current u-boot configuration.

It will most likely be the first partition in your SD card.
When you insert the SD card on your development machine, it may appear
as /dev/mmcblkXpY (X and Y being the port and partition numbers).
It is likely to be /dev/mmcblk0p1. This depends on your hardware and
potential dongles you use.

Assuming your u-boot uses the first partition, you must place your
files
on that partition.

Best regards,
Jean

--

Le 2016-05-06 13:20, Shivakumar Gangannavar a écrit :
> Hello All,
>
> I want to run xvisor on imx6-sabrelite board.
>
> I have downloaded xvisor-master code from
> GIT[*https://github.com/xvisor/xvisor
> <https://github.com/xvisor/xvisor>*] and built all the binaries of
> <http://in.linkedin.com/in/shivakumargangannavar>

Anup Patel

unread,
May 7, 2016, 6:42:14 AM5/7/16
to xvisor...@googlegroups.com, Shivakumar Gangannavar, Vishnu jayan
Hi Shivakurmar,

Once you are able to boot Xvisor on i.MX6, you might want to verify
your UART settings based on Vishnu's recent email thread
(https://groups.google.com/forum/#!topic/xvisor-devel/qqEVCxNINXc)

Also, please ensure that you patch Guest Linux kernel image for
i.MX6 becasue i.MX6 has Cortex-A9 which does not have virtualization
extensions.

@Jean,
Do we need documentation update for UART settings which you
mentioned in Vishnu's email thread?

Regards,
Anup
> --
> You received this message because you are subscribed to the Google Groups
> "Xvisor Development" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to xvisor-devel...@googlegroups.com.
> Visit this group at https://groups.google.com/group/xvisor-devel.
> For more options, visit https://groups.google.com/d/optout.

Jean Guyomarc'h

unread,
May 7, 2016, 6:41:22 PM5/7/16
to xvisor...@googlegroups.com
> @Jean,
> Do we need documentation update for UART settings which you
> mentioned in Vishnu's email thread?

I think what could be documented is that the sabrelite guest *assumes*
UART2 is the
UART being used (this can be found in the existing linux defconfigs
though).
So, if one wants to use a kernel configuration that uses UART1, one
needs to
adapt the kernel configuration (and not Xvisor itself).

The following parameter should be written in the kernel configuration:
CONFIG_DEBUG_IMX_UART_PORT=2
I'm not sure it's a standalone parameter, but it definitely is required
for UART2.

Best regards,
Jean

--

Shivakumar Gangannavar

unread,
May 9, 2016, 7:15:01 AM5/9/16
to xvisor...@googlegroups.com
Hello Jean and Anup,

Thanks for the quick response.

I have tried below 2 approaches to load xvisor on sabrelite board.

1) 
I could able to find boot partition under /dev/mmcblock0p1. But now I would like to know how to mount using which FS.

I have tried with below command and I'm not able to mount boot partition.

mount -t ext2 /dev/mmcblock0p1 /mnt/

So can you please help me to copy xvisor files onto boot partition of SD card.

2)
Tried to load xvisor using tftpboot.

Copied 'uvmm.bin' and 'vmm-imx6q-sabrelite.dtb' at addresses 10800000 and 12000000 respectively.

After that issued 'bootm 10800000 - 12000000' command.

On Console I can see 'Starting Linux' and then no debug traces.


Can you please update me the steps to follow using tftpboot?




Best Regards,
Shiv


On Fri, May 6, 2016 at 7:05 PM, Jean Guyomarc'h <jean.gu...@openwide.fr> wrote:

Jean Guyomarc'h

unread,
May 9, 2016, 8:39:19 AM5/9/16
to xvisor...@googlegroups.com
Hi Shivakumar,

1) to mount a partition, you should let Linux handle the FS type.
mount will try the possible FS it is aware of.
Furthermore, you need to specify a mountpoint, therefore a
single directory entry. You will be able to access the files
from there. You may want to try:

> mount /dev/mmcblock0p1 /mnt

Than you can manipulate the partition through /mnt

Example:
> cp xvisor.bin /mnt/

Don't forget to umount to flush IO buffers:
> umount /mnt

If mount does not work, you can seek for information thanks
to the dmesg command. You can also see the supported filesystems
by looking at /proc/filesystems.


2) I never tried tftboot with Xvisor. Your issue may be
related to
https://groups.google.com/forum/#!topic/xvisor-devel/qqEVCxNINXc
though...
Did you configure your kernel to use UART2. If not, please do so:
the firmware expects Linux to use UART2.

Best regards,
Jean

--

Le 2016-05-09 13:15, Shivakumar Gangannavar a écrit :
> Hello Jean and Anup,
>
> Thanks for the quick response.
>
> I have tried below 2 approaches to load xvisor on sabrelite board.
>
> 1)
> I could able to find boot partition under /dev/mmcblock0p1. But now I
> would
> like to know how to mount using which FS.
>
> I have tried with below command and I'm not able to mount boot
> partition.
>
> *mount -t ext2 /dev/mmcblock0p1 /mnt/*

Shivakumar Gangannavar

unread,
May 9, 2016, 12:05:03 PM5/9/16
to xvisor...@googlegroups.com

Hello Jean,

I tried mounting as you suggested before posting my previous post.

I got error saying file system type should be mentioned along with mount command.

I checked filesysstem type by issuing command as below

/sbin/parted /dev/mmvblock0p1 print

And I don't see any fstype.

So now I have stuck at this point.

Can you please suggest if I have missed any point.

Jean Guyomarc'h

unread,
May 9, 2016, 12:15:16 PM5/9/16
to xvisor...@googlegroups.com
At this point, logs would help.
Can you please provide the exact output (as well as the command
themselves)
of your mount command and a 'dmesg | tail -n 20'.

You can also try providing the 'auto' argument as a filesystem to
mount:
mount -t auto <PARTITION> <MOUNTPOINT>
This may help to overcome mount being picky.

Best regards,
Jean

--

Shivakumar Gangannavar

unread,
May 9, 2016, 12:34:31 PM5/9/16
to xvisor...@googlegroups.com
OK Jean, thanks.. Tomorrow I will provide the logs and will try the command which you have suggested.

I have few basic questions,
1) Do Xvisor support Android as Guest OS? if yes on which board its verified
2) Do Xvisor support two or more Linux Guest OS? if yes on which board its verified
3) How to configure Xvisor to assign dedicated cores to the Guest OS?

Shivakumar Gangannavar

unread,
May 10, 2016, 1:42:36 AM5/10/16
to xvisor...@googlegroups.com

Best Regards,
Shivakumar SG
+91-9972222662
in.linkedin.com/in/shivakumargangannavar


logs

Jean Guyomarc'h

unread,
May 10, 2016, 4:03:26 AM5/10/16
to xvisor...@googlegroups.com
Thanks for the logs, that's telling a lot.
I would suggest you to try to mount all the partitions.
It seems to me that mmcblk0p4 contains the rootfs.
Maybe mmcvlk0p1 is a swap or something like this.

I would advise you to:
= mount with 'mount -t auto' every partition
= if mount succeeds, look inside if there are
system binaries (e.g. uImage, zImage, Image, vmlinux, .dtb,
uenv.txt, boot.scr, ...)
When you have found the partition that contains such files,
you should modify the u-boot script in Xvisor to make it
use it (docs/arm/imx6-sabrelite-bootscript).

An alternative would be to format your card with
fdisk + mkfs for instance. This will delete everything though...

Best regards,
Jean

--

Le 2016-05-10 07:42, Shivakumar Gangannavar a écrit :
> Hello Jean,
>
> As requested I have captured the logs and attached herewith.
>
> Please help me to overcome this issue.
>
> *Target: IMX-6 Sabre Auto*
> <http://in.linkedin.com/in/shivakumargangannavar>

Shivakumar Gangannavar

unread,
May 10, 2016, 7:14:49 AM5/10/16
to xvisor...@googlegroups.com
Thanks Jean,

I have created new boot partition and mounted using below command.

sudo mount -t auto /dev/sdc1 /mnt/  [Connected sdcard using card reader to vmware]

copied all below files to boot partition

6x_bootscript
cmdlist
firmware.bin.patched
Image
nor_flash.list
sabrelite-a9.dtb
uvmm.bin
vexpress-v2p-ca9.dtb
vmm-imx6q-sabrelite.dtb

Now after u-boot its not finding kernel image to load and its entering in to fastboot

please find below logs for your reference

===============================================
U-Boot 2009.08 (Jun 21 2013 - 21:06:03)

CPU: Freescale i.MX6 family TO1.2 at 792 MHz
Thermal sensor with ratio = 187
Temperature:   37 C, calibration data 0x5a15017d
mx6q pll1: 792MHz
mx6q pll2: 528MHz
mx6q pll3: 480MHz
mx6q pll8: 50MHz
ipg clock     : 66000000Hz
ipg per clock : 66000000Hz
uart clock    : 80000000Hz
cspi clock    : 60000000Hz
ahb clock     : 132000000Hz
axi clock   : 264000000Hz
emi_slow clock: 132000000Hz
ddr clock     : 528000000Hz
usdhc1 clock  : 198000000Hz
usdhc2 clock  : 198000000Hz
usdhc3 clock  : 198000000Hz
usdhc4 clock  : 198000000Hz
nfc clock     : 24000000Hz
Board: i.MX6Q-SABREAUTO: unknown-board Board: 0x63012 [POR]
Boot Device: SD
I2C:   ready
DRAM:   2 GB
MMC:   FSL_USDHC: 0,FSL_USDHC: 1,FSL_USDHC: 2,FSL_USDHC: 3
*** Warning - bad CRC or MMC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   got MAC address from IIM: 00:04:9f:20:77:f1
FEC0 [PRIME]
Hit any key to stop autoboot:  0 
booti: bad boot image magic
fastboot is in init......flash target is MMC:2
Bad partition index:2 for partition:recovery
Bad partition index:5 for partition:system
wait usb cable into the connector!
====================================================


Best Regards,
Shivakumar SG
+91-9972222662
in.linkedin.com/in/shivakumargangannavar


Anup Patel

unread,
May 11, 2016, 8:18:05 AM5/11/16
to xvisor...@googlegroups.com

Hi Shivakumar,

Based on your uboot log, it seems to me that you are using an old uboot on imx6 which does not have DT (device tree) support.

If this is the case then you have to move to more recent uboot which has DT support.

The thing is that Xvisor follows ARM booting protocol and DT based booting to have same Xvisor binary on multiple boards.

Regards,
Anup

Jean Guyomarc'h

unread,
May 11, 2016, 12:28:44 PM5/11/16
to xvisor...@googlegroups.com
> 1) Do Xvisor support Android as Guest OS? if yes on which board its
> verified

As far as I know, Android is not supported in upstream Xvisor.

> 2) Do Xvisor support two or more Linux Guest OS? if yes on which board
> its
> verified

Yes, that's possible. Vexpress-a9 provides two guests.

> 3) How to configure Xvisor to assign dedicated cores to the Guest OS?

I don't know if CPU pinning is implemented. It should be possible
though...
You may want to look in core/include/vmm_scheduler.h in
core/include/vmm_manager.h for hints.

Anup Patel

unread,
May 11, 2016, 2:10:07 PM5/11/16
to xvisor...@googlegroups.com


On May 11, 2016 9:58 PM, "Jean Guyomarc'h" <jean.gu...@openwide.fr> wrote:
>>
>> 1) Do Xvisor support Android as Guest OS? if yes on which board its verified
>
>
> As far as I know, Android is not supported in upstream Xvisor.

This is not true. Xvisor arm32ve and arm64 allows booting multiple Android Guest.

Two years back ITRI, ICL, Taiwan folks had booted two Android Guests on ARM Fast Models.
https://www.youtube.com/watch?v=VWrFSnaigvA

Although, we have not tried Android Guest on Xvisor arm32. There might be some work in this area.

>
>
>> 2) Do Xvisor support two or more Linux Guest OS? if yes on which board its
>> verified
>
>
> Yes, that's possible. Vexpress-a9 provides two guests.
>
>
>> 3) How to configure Xvisor to assign dedicated cores to the Guest OS?
>
>
> I don't know if CPU pinning is implemented. It should be possible though...
> You may want to look in core/include/vmm_scheduler.h in core/include/vmm_manager.h for hints.

Yes, CPU pinning is also available since quite some time. We can set VCPU affinity using "affinity" DT attribute of VCPU DT node.

Regards,
Anup

Jean Guyomarc'h

unread,
May 11, 2016, 3:00:41 PM5/11/16
to xvisor...@googlegroups.com
> This is not true. Xvisor arm32ve and arm64 allows booting multiple
> Android
> Guest.

> Yes, CPU pinning is also available since quite some time. We can set
> VCPU
> affinity using "affinity" DT attribute of VCPU DT node.

Waw, I did not know that. Thanks Anup.

--
Jean


Reply all
Reply to author
Forward
0 new messages