From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LIzQl-0004wJ-No for qemu-devel@nongnu.org; Sat, 03 Jan 2009 00:52:15 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LIzQk-0004w7-PE for qemu-devel@nongnu.org; Sat, 03 Jan 2009 00:52:15 -0500 Received: from [199.232.76.173] (port=37708 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LIzQk-0004w4-HD for qemu-devel@nongnu.org; Sat, 03 Jan 2009 00:52:14 -0500 Received: from vsmtp04.dti.ne.jp ([202.216.231.139]:59492) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LIzQj-0008S4-RU for qemu-devel@nongnu.org; Sat, 03 Jan 2009 00:52:14 -0500 Received: from [192.168.1.21] (PPPa1787.e11.eacc.dti.ne.jp [124.255.93.17]) by vsmtp04.dti.ne.jp (3.11v) with ESMTP AUTH id n035q89e021321 for ; Sat, 3 Jan 2009 14:52:08 +0900 (JST) Message-ID: <495EFD0D.8050002@juno.dti.ne.jp> Date: Sat, 03 Jan 2009 14:52:13 +0900 From: Shin-ichiro KAWASAKI MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] [RFC] sh: SM501 usb host emulation References: <49564399.7020006@juno.dti.ne.jp> In-Reply-To: <49564399.7020006@juno.dti.ne.jp> Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Shin-ichiro KAWASAKI wrote: > Hi, all. > > SM501 is a multi function device on sh4/r2d evaluation board. > Now, only its minimum graphics feature is implemented. > This patch adds SM501's usb host feature. > > To use usb keyboard for sh4/r2d system emulation, we need to apply > another patch to add PCI usb host. This patch avoids this work, > and provides more precise usb host emultation than PCI one. > > Reviews and comments will be appreciated. > This patch modifies not only r2d/sm501 related source files but also > "hw/usb-ohci.c". It should not have any impact on other board emulations' > usb feature. Reviews from this point of view will be meaningful. I hope the patch to be applied to trunk, because now I believe it has no impact for other board emulation, which has PCI usb host or PXA usb host. I've checked it with following way. - I built sh4/r2d system emulation environment with PCI usb host. Code was taken from qemu svn head and qemu-sh staging quilt repository. And I confirmed that USB keyboard works fine with it. - Applied the SM501 usb host patch to the environment. - Disabled SM501 usb host by killing off following lines in hw/sm501.c /* bridge to usb host emulation module */ usb_ohci_init_sm501(base + MMIO_BASE_OFFSET + SM501_USB_HOST, base, 2, -1, irq); - Booted up the SH-Linux with the environment, and saw how the USB keyboard worked with PCI usb host. As a result, PCI usb host works fine under the modification of SM501 usb host patch. I didn't checked PXA usb host, but it shares whole codes with PCI usb host emulation in "hw/usb-ohci.c". Regards, Shin-ichiro KAWASAKI