Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Sep 2013 22:49:22 +0800
From:      zhixiang yu <zxyu.core@gmail.com>
To:        soc-status@freebsd.org
Cc:        Alexander Motin <mav@freebsd.org>, "grehan@freebsd.org" <grehan@freebsd.org>, Neel Natu <neelnatu@gmail.com>
Subject:   Final Weekly report and the summary of my GSoC project
Message-ID:  <CADr9iNu-g7WmwiCsL2Nww=uwdHiO7n2-hFXyBwzhCjc_d0pDsQ@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi all,

During the last week, I spent time on stress testing, bug fixing,
limitation removing and make bhyve cdrom emulation works under Linux.

My stress test is running the following cmds at the same time:

1. cp src.txz  from virioblk to ata device, then diff, exit if diff
report error, delete src.txz. loop for ever
2. cp /usr from virioblk to ata device, then diff, exit if diff report
error, delete. loop for ever
3. tar zxf src.txz to ata device, then delete. loop for ever
4. cp /boot from virioblk to ata device, then diff, exit if diff
report error, delete. loop for ever
5. run "zpool scrub test0" and "zpool status" every 10min, check the output
6. use release.iso as the atapi backing file, mount, cat everything to /dev/null

After 24 hours, everything seems fine.


Here is the summary of my GSoC project.

During this summer, I added AHCI device emulation to bhyve so that we
can emulate normal cdroms and hard drives. The development is done
under the guide from Alexander, Peter and Neel.

During SoC application period, I carefully divided the project into
small goals and give the timeline for each goal. Basically speaking, I
almost follow the timeline I planed in my gsoc proposal. Before early
July, I implemented one bare bone pci_ahci.c. Before midterm
evaluation, I completed the emulation for almost all port registers
and the most important three data structures of AHCI (command list,
command table and PRDT). I also sent out my first accepted FreeBSD
patch during that period ;)  After midterm evaluation, necessary ata
commands emulation and atapi commands emulation were finished.

The biggest pleasure/achievements during this summer are:

1. write code under old-hand's guidance. My mentors from FreeBSD
community are really amazing. They are really experts in their
technology area. They can quickly find out the main problem in your
code and find the best direction to your questions/problems. NOTE:
they tell you what, why and one brief but clear and definite
direction, it's your own responsibility to design and implement the
solution. For example:

Alexander clearly pointed out the backing file io should be done in
another thread rather than block main emulation thread during initial
design decision. Then Peter told me that he has implemented on common
block_if, this makes my ahci emulation is the first real user of his
blockif framework ;) And Alexander also suggested to handle single ATA
command as multiple block I/Os if S/G list is longer then supported to
remove one big limitation of my initial code.

Peter and Neel quickly replied that I can follow existing instruction
emulations to handle one instruction exception. This results in my
first accepted FreeBSD's patch ;)

2. I can't be familiar with AHCI any more. Now, I can even clearly
describe the main mechanism of AHCI in several minutes with one
pencil. I guess I can quickly implement AHCI driver for various hobby
OSs

In the end, thank FreeBSD and Google to provide me such great coding
opportunity. Thank Alexander, Peter and Neel for their great help and
guidance.

Best wishes to everyone!



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CADr9iNu-g7WmwiCsL2Nww=uwdHiO7n2-hFXyBwzhCjc_d0pDsQ>