Google Summer of Code 2013

From QEMU

Introduction

QEMU is going to apply as a mentoring organization for Google Summer of Code 2013. This page contains our ideas list and information for students and mentors.

Preliminary information: Please remember that Google has not accepted organizations for 2013 yet.

Please note that QEMU, as a GSoC organization, also includes the following projects:

  • The Linux Kernel's KVM module
  • Libvirt, the virtualization library

Find Us

Please contact the following people with questions about QEMU in GSoC. IRC is usually the quickest way to get an answer, see below for methods of communication.

Important links

Information for students

We require students to provide at least the following information in their applications:

  • Contact information (email, irc nick, phone number)
  • A general personal description (skills, past experiences and open source contributions, if any)
  • Why QEMU and why this project
  • A detailed description of the approach the student will take

Please get in touch before applying so we can arrange for an IRC interview and get to know each other. Students who do not contact the mentor cannot be accepted.

VERY IMPORTANT: Submitting a patch and having it merged by QEMU or KVM increases your chances of being accepted.

Project Ideas

This is the listing of suggested project ideas. Students are free to suggest their own projects, too.

QEMU projects

Add USB Media Transfer Protocol emulation to QEMU

Summary: Flesh out the prototype of MTP emulation and get the working result merged into QEMU.

There is a USB Media Transfer Protocol prototype which supports linux hosts. Media Transfer Protocol is a USB protocol used to exchange files with cameras, audio players, and smartphones. It is particularly interesting for QEMU because modern guest operating systems support it out-of-the-box and it can be used to easily transfer files between the guest and host.

High priority tasks:

  • Make it portable (i.e. work on windows hosts), evaluate options and implement it. Possible options: (1) create small posix/win32 abstraction layer for file+directory access, or (2) hook up virtfs code.
  • Finishing touches to get it into mergable state (not that much, little cleanups here and there).

Medium priority tasks:

  • Figure why Windows guests classify our MTP device as "Digital Camera" & fix it.
  • Test with different guests / guest applications, fix issues as they pop up.

Useful features which can be added:

  • Write support (current prototype is read-only).
  • Quota (so the guest can't fill up the hosts disk, obviously depends on write support).
  • Notification support: signal changes in the directory tree to the guest, so new/deleted files are instantly visible in the guest (probably hard to do in a efficient & portable way, maybe target linux+inotify).

For background information on MTP, see http://en.wikipedia.org/wiki/Media_Transfer_Protocol.

  • Skill level: intermediate/advanced
  • Language: C
  • Mentor: Gerd Hoffmann <kraxel@redhat.com> ("kraxel" on IRC)

Converting coroutines to Continuation Passing C

Summary: Integrate Continuation Passing C into QEMU as a drop-in replacement for coroutines.

QEMU implements coroutines using stack switching, which has proved fragile and hard to port. Continuation Passing C provides a similar programming model to coroutines without using stack switching.

This project attempts to replace coroutines with Continuation Passing C. Most effort will be in adapting Continuation Passing C and its runtime library to implement QEMU's coroutine API. Hopefully QEMU code changes will be minimal.

If the student has sufficient time they can explore reimplementing the Continuation Passing C translator in a format that is easier to consume - like a GCC patch or plugin.

This project is suitable for students interested in compilers and programming languages. This is a challenging project that requires listening to and working with the community.

Please take a look at the links below before getting in touch about this project.

Links:

Details:

  • Skill level: advanced
  • Language: C, OCaml (read-only)
  • Mentor: Stefan Hajnoczi <stefanha@gmail.com> ("stefanha" on IRC)

Integrated Copy/Paste

Summary: Add guest copy/paste support to builtin QEMU UIs

Users have come to expect copy-paste between host and guest to work. This is also called clipboard sharing and makes it easier to work with graphical guests.

This project would start out integrating copy/paste APIs into qemu-ga. Copy/paste support is already available in the spice agents so those should serve as a starting point. Once qemu-ga can support copy/paste, it can then be plumbed through the VNC server and the GTK UI. Stretch goals would include drag and drop and/or Windows guest enablement

Links:

Details:

  • Skill level: beginner to advanced
  • Language: C
  • Mentor: Anthony Liguori <anthony@codemonkey.ws> ("aliguori" on IRC)
  • Mentor: Mike Roth <mdroth@linux.vnet.ibm.com> ("mdroth" on IRC)
  • Suggested by: Anthony Liguori

Improving the Win32 and Win64 ports of QEMU

Summary: QEMU supports Windows (both 32-bit and 64-bit), but the limited amount of testing caused performance to suffer and bugs to creep in release after release. This project aims at fixing QEMU bugs affecting Windows platforms, and adding new features such as migration.

  • Skill level: intermediate/advanced
  • Language: C
  • Mentor: Paolo Bonzini <pbonzini@redhat.com> ("bonzini" on IRC)

KVM projects

Improve nested virtualization support for x86

Summary: Improve nested virtualization support for Intel and AMD CPUs using test cases

Every wanted to write your own hypervisor? This is a unique chance! Granted, the result will "just" be test cases for KVM, but this will still allow to explore interesting aspects of the x86 architecture and learn a lot about CPU virtualization on x86 and how it is used by KVM. Precondition is an intermediate understanding of the x86 architecture, good C knowledge and experience with x86 assembly. The test cases shall be written within the kvm unit test framework. They have to establish an environment that allows switching a CPU into virtualization mode and running pieces of guest code, also provided by the tests. Those pieces shall trigger corner cases of nested virtualization reliably that are never or only rarely hit by standard hypervisors. If bugs in KVM are found, they should ideally be addressed as well. Foundation will be the Intel and AMD system programming manuals, but likely also intensive discussions about their interpretation in the community.

Links:

Details:

  • Skill level: advanced
  • Language: C, x86 assembly
  • Mentor: Jan Kiszka
  • Suggested by: Jan Kiszka

Libvirt projects

Introducing job control to the storage driver

Currently, libvirt support job cancellation and progress reporting on domains. That is, if there's a long running job on a domain, e.g. migration, libvirt reports how much data has already been transferred to the destination and how much still needs to be transferred. However, libvirt lacks such information reporting in storage area, to which libvirt developers refer to as the storage driver. The aim is to report progress on several storage tasks, like volume wiping, file allocation an others.

  • Skill level: intermediate

More intelligent virsh auto-completion

Even though there's already some auto-completion in virsh, it is not enough. For better user experience, virsh should auto complete objects to virsh commands, e.g. "start <TAB><TAB>" lists not only options that the start command knows, but list of inactive domains as well. Moreover, the same applies to command options.

  • Skill level: beginner

Introduce API to query IP addresses for given domain

One of the most desired APIs in libvirt that still hasn't been implemented. The aim is to get/guess list of IP addresses assigned to domain. There are several ways to get such list: asking guest agent, snooping for domain traffic, parsing dnsmasq lease file, etc.

  • Skill level: beginner

Ability to run qemu-{system-}arm

Libvirt is nowadays tight to PCI bus based qemus: qemu-i386 and qemu-x86_64. However, with recent development of ARM architecture, as ARM based devices become more and more popular, the voice calling for ARM support in libvirt is getting stronger. The libvirt's assumption every domain has at least one PCI bus needs to be dropped and code adapted accordingly.

  • Skill level: advanced

Links:

Details:

  • Component: libvirt
  • Skill level: (see description to each item)
  • Language: C
  • Mentor: Michal Privoznik <mprivozn@redhat.com>, mprivozn on IRC (#virt OFTC)
  • Suggested by: Michal Privoznik <mprivozn@redhat.com>

Project idea template

=== TITLE ===
 
 '''Summary:''' Short description of the project
 
 Detailed description of the project.
 
 '''Links:'''
 * Wiki links to relevant material
 * External links to mailing lists or web sites
 
 '''Details:'''
 * Skill level: beginner or intermediate or advanced
 * Language: C
 * Mentor: Email address and IRC nick
 * Suggested by: Person who suggested the idea

Information for mentors

Mentors are responsible for keeping in touch with their student and assessing the student's progress. GSoC has a mid-term evaluation and a final evaluation where both the mentor and student assess each other.

The mentor typically gives advice, reviews the student's code, and has regular communication with the student to ensure progress is being made.

Being a mentor is a significant time commitment, plan for 5 hours per week. Make sure you can make this commitment because backing out during the summer will affect the student's experience.

The mentor chooses their student by reviewing student application forms and conducting IRC interviews with candidates. Depending on the number of candidates, this can be time-consuming in itself. Choosing the right student is critical so that both the mentor and the student can have a successful experience.