Adventium MiCART Project

From DDCIDeos
Jump to navigationJump to search

Description

Deos running under the Xen Hypervisor/VM.

Admin info

Website: http://www.adventiumlabs.org/

Technical Contacts:

End Game

Planing for the rest of the program.

BSP

All the pieces are implemented, but the interrupts from Xen are not coming with consistent timing. Still not sure if this is a DDC-I or Adventium problem. Status: In work.

White Paper

BC is doing draft.

USB

We now have what appears to be stable USB communication on VMWare. We are still having application level issues, e.g., the Lego brick has specific timing requirements.

Remaining tasks for USB (unordered)

  1. Packaging, e.g., Cygwin, howto docs, etc.
  2. Update to BSD 5.1 source tree. (optional, but in work).
  3. serial2usb.c layer cleanup.
  4. Port to Xen
    1. Get Adina access to AL's Xen box.
    2. Get Lego brick in AL's office (optional?)
    3. The actual porting.
  5. Packaging and documents

Bluetooth

  1. Get it working

Lego Bot info

  • Using 1.31 firmware
  • Bluetooth dongle not yet known.

Connecting to the Xen box

  1. The IP address can be gotten from aaron's home directory on linux02, e.g.,
    scp linux02:~alarson/xenaddress.txt .

    There can be a 3ish minute delay after loss of the VPN for the new address to show up

  2. ssh or scp can be used to the IP address, which we'll refer to as "xen1" below. aroffelsen and su passwords are frap3zent7
  3. in the xen bsp mainline directory,
    make install
  4. Edit the /desk/platform/xen/etc/deos-xen.cfg file to replace /home/alarson with your home directory on xen1, then from your local machine:
      scp ./deos.iso the-edited-deos-xen.cfg  aroffelsen@xen1:

    From an xterminal on the Mac:

      ssh -Y aroffelsen@xen1            
      xen1> su
      xen1> xm shutdown deos; xm create deos-xen.cfg && xm vncviewer deos
  5. At present you have to scp files to xen1, then on xen1 use ftp to put files to the target.

In order to setup the USB controllers for Deos, run

 ~aroffelsen/unbind-usb.sh

That script deallocates both USB controllers from the Dom-0 kernel thus making them available to Deos. The deos-xen.cfg file then needs to have the following added to it:

 pci = ['00:1d.0', '00:1a.0']

At present both the Lego tower and the NXT are plugged into the front panel USB connectors.

Status

Milestones Due Date Estimated Delivery Delivered Percentage Complete
[1] Deos Running Under Xen TBD TBD TBD 0%
[2] Deos/Xen with Demo Apps TBD TBD TBD 0%


[1] Deos Running Under Xen

Task Dependency Assignee Original Estimate Elapsed Remaining
1.1 Provide requirements Xen must meet in order for Deos to function None TBD4 97 0 97
1.2 Review tool requirements for multi-core scheduling None TBD4 216 0 216
1.3 Provide DEOS running in a Xen domain (HVM) None TBD4 324 0 324
1.4 Add Xen target to OpenArbor None TBD4 60 0 60
1.5 QA None TBD4 40 0 40
1.6 Release with Xen as Suported HVM Platform None TBD4 45 0 45
Totals 782 0 782

[2] Deos/Xen with Demo Apps

Task Dependency Assignee Original Estimate Elapsed Remaining
2.1 Identify representative demonstration application None TBD4 22 0 22
2.2 Support demonstration architecture development None TBD4 108 0 108
2.3 Evaluate demonstration results and identify next steps 2.2 TBD4 45 0 45
Totals 175 0 175

Operating Instructions

OpenSuse 11.1 is installed on dtower2 (see Aaron for root password). Remote X on the platform is ridiculously slow, so you have to VNC to the box on port 5902 (e.g., vncviewer dtower2:2).

Activity Log

2010-09-15(ish)

Got Deos running on qemu on ubuntu and windows. Ref https://ddci.zapto.org:/scm/Deos/products/bsp/xen/branches/mainline/

2010-09-20

Aaron met with Adventium staff Todd Carpenter, Stephen Harp, Steven Vestal, and Hazel Shackleton. Notes:

  • We need to deliver a BSP for Xen 3.3.1, although Xen 4 may be an option. The preferred version is in OpenSuse 11.1
  • For now, Deos running in a hardware virtualization strategy is acceptable, although long term they'd like to move to paravirtualization. They'd like us to scope the cost for developing a paravirtualized Deos kernel.
  • Device pass through is desired, especially for network device (using IOMMU) and USB.
    1. The RTL-81xx network driver used in the qemu doesn't work with IOMMU (according to Stephen Harp).
    2. The PRO-100 or Pro-1000 network cards supposedly do work.
  • Adventium is currently using Xen in a 64-bit architecture, but it does support 32-bit clients.
  • Eventually they'd like to get Deos running (under Xen) in a COTS Curtiss-Wright board (a single board computer).

Stephen Harp suggested the following references:

  • The definitive Guide to the Xen Hypervisor, 2007 David Chisnall.
  • Time keeping in VMware Virtual Machines (didn't get a clear reference). Apparently this is a white-paper from VMware.


Real time in a VM

The main research task is to determine how to do partitioned real time in a virtual machine. Space partitioning is moderately easy, time partitioning is quite difficult. There are basically two strategies:

  1. Assume the hypervisor can provide a consistent view of time to all clients without the clients knowing about it.
  2. Make each client deal with the time effects of virtualization.

Personally, I don't see #1 being very likely. Wall time and virtual time will always have different properties, and applications will depend on the properties in different ways. In a real-time system this just seems intractable.

The second option obviously requires more work for each virtual client system (not just the OS). We discussed this at some length. In Deos, RMA is both a help and a hindrance. Since apps don't nominally have pre-period deadlines, slipping some time in the schedule for other hypervisor clients should have minimal effect. The problem is that the Deos kernel needs to model when that happens. It seems like modeling the time spent in another client as an interrupt of some sort is the most likely solution. Although an alternative would be to make use of our 653 capability to model pre-determined time slots for other clients.

The other big real-time issue is cache effects. They don't have a strategy for this. I did mention that we had some patents in this area that might be of use and outlined the basic idea (cache partitioning). I made it very clear, and the acknowledged that this was under NDA.

2010-09-30

Stephen Harp reports that the Deos boot ISO that worked under qemu doesn't work under Xen. It appears to be an IRQ issue.

2010-10-04

I installed Gnome opensuse 11.1 on an old computer I had, then attempted to install xen using the instructions at: http://www.susegeek.com/general/how-to-install-configure-xen-virtualization-in-opensuse-110/

YaST reported error:

 download failed:
    Permission to access 'http://download.opensuse.org/distribution11.1/repo/oss/suse/i586/python-gtk-vnc-0.3.7-5.3.i586.rpm' denied.

After reboot, the instructions say "KMenu – Applications – System – Virtualization"

I had to do: "KMenu – More Applications – System – Virtual Machine Manager"

Xen reported that my system didn't support virtualization (an older Athlon processor). I'm contacting Steven Harp to see how to proceed.

2010-10-11

I updated the /etc/xinetd.d/vnc file on dtower2 to enable VNC port 5902. I also replaced /usr/share/wallpapers/openSUSE111-1600x1200.png with an empty file (eliminate the background image). If you connect with VNC forced to 8 bit, response is now acceptable.

2010-10-14 & 15

Replicated Adventium results when attempting to boot Deos on Open Suse 11.3 (Xen 3.3.1). Loading the task register or attempting to do a floating point save hangs the kernel. SHH is shipping the Xen target box to MSP so I can work with it directly and install the latest Open Suse/Xen on it.