From owner-soc-status@FreeBSD.ORG Fri Apr 19 15:43:32 2013 Return-Path: Delivered-To: soc-status@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id AFEB2902 for ; Fri, 19 Apr 2013 15:43:32 +0000 (UTC) (envelope-from gibbs@freebsd.org) Received: from aslan.scsiguy.com (mail.scsiguy.com [70.89.174.89]) by mx1.freebsd.org (Postfix) with ESMTP id 7C11FB39 for ; Fri, 19 Apr 2013 15:43:32 +0000 (UTC) Received: from [192.168.6.106] (207-225-98-3.dia.static.qwest.net [207.225.98.3]) (authenticated bits=0) by aslan.scsiguy.com (8.14.5/8.14.5) with ESMTP id r3JEsomN050473 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Fri, 19 Apr 2013 08:54:51 -0600 (MDT) (envelope-from gibbs@freebsd.org) Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Subject: =?utf-8?Q?Re=3A_Mentor_of_the_Project_=22PCI_frontend_XEN_PV_dri?= =?utf-8?Q?ver=22=EF=BC=9F?= From: "Justin T. Gibbs" In-Reply-To: Date: Fri, 19 Apr 2013 08:54:49 -0600 Message-Id: References: <920A79FE-8C56-4D26-8611-3CD48602FC3B@freebsd.org> <7AB96913-9118-4298-B183-A3D5EBC6F209@freebsd.org> To: Bei Guan X-Mailer: Apple Mail (2.1503) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (aslan.scsiguy.com [70.89.174.89]); Fri, 19 Apr 2013 08:54:51 -0600 (MDT) Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: soc-status X-BeenThere: soc-status@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Summer of Code Status Reports and Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Apr 2013 15:43:32 -0000 On Apr 18, 2013, at 7:14 AM, Bei Guan wrote: > 2013/4/16 Justin T. Gibbs > On Apr 12, 2013, at 3:02 AM, Bei Guan wrote: >=20 > > Thank you for your reply. > > > > I think it's also a good project for me to write a SCSI or USB PV = frontend for FreeBSD. I'm interest in Xen and have done some development = about Xen PV and HVM, but I didn't do any development on FreeBSD. As to = this project, where should I start? Is there any other similar FreeBSD = project I can refer to? >=20 > Front-end drivers for network, block, and control already exist and = should serve as a good starting point for the creation of another PV = driver. >=20 > I've also updated the ideas page to include more information about our = existing XEN implementation and what will be required for these = projects. >=20 > > In order to write a SCSI or USB PV driver, do we need the Xen PV = drivers in FreeBSD, such as event channel, hypercalls, xenbus, and so = on? >=20 > Yes, FreeBSD already has support for all XenBus APIs needed to write = these drivers. See "sys/xen" and "sys/dev/xen" in the FreeBSD kernel = source tree. >=20 > > You said the "drivers can be developed using an HVM guest", can you = give me more information about it? >=20 > Typically, you install FreeBSD using standard install media as a full = HVM guest on a system running Xen. Then compile a custom kernel using = the XENHVM config file in order to activate the existing PV drivers. > Hi Justin, >=20 > Does this project need to provide USB/SCSI PV drivers to both 32-bit = and 64-bit FreeBSD? Idealy, yes. > I've compiled the FreeBSD 8.3 (i386) as Xen DomU with the XENHVM = config. But, It cannot boot successfully. The screenshot is attached. > According to the page https://wiki.freebsd.org/FreeBSD/Xen , 32-bit = FreeBSD should work when compiled with XENHVM config. I have never tried a 32bit XENHVM configuration, but I know of no = reasons why it should not work. The issue shown by your screen shot (in = your other email) is probably due to a PV driver failing to fully = attach, or a mistake in the merge of SVN changeset 211236 to releng-8. = I would suggest instrumenting sys/xen/xenbus/xenbusb.c to determine the = driver that is still holding up the root mount process and then go from = there. See xenbusb_attach() and xenbusb_nop_confighook_cb() for = details. You may also want to invest in changing your Xen configuration to use a = serial console. This will allow you to properly log and examine all = kernel messages emitted during your test runs.=20 > I will try the 64-bit FreeBSD. However, if the FreeBSD boot = successfully (compiled with XENHVM config), how can we know it really = uses the PV drivers instead of the native drivers? Your configuration is definitely using PV drivers. xenbusb_front, xn, = and xbd, are all PV drivers. -- Justin=