From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HYVd0-0005M5-OS for qemu-devel@nongnu.org; Mon, 02 Apr 2007 19:07:58 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HYVcy-0005Lt-4p for qemu-devel@nongnu.org; Mon, 02 Apr 2007 19:07:57 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HYVcx-0005Lq-Vw for qemu-devel@nongnu.org; Mon, 02 Apr 2007 19:07:56 -0400 Received: from an-out-0708.google.com ([209.85.132.251]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1HYVZs-00058u-Bw for qemu-devel@nongnu.org; Mon, 02 Apr 2007 19:04:44 -0400 Received: by an-out-0708.google.com with SMTP id d40so3113662and for ; Mon, 02 Apr 2007 16:04:43 -0700 (PDT) Message-ID: Date: Tue, 3 Apr 2007 01:04:42 +0200 From: "andrzej zaborowski" Sender: balrogg@gmail.com Subject: Re: [Qemu-devel] Simtec BAST emulation In-Reply-To: <1175522199.18271.19.camel@petitemort.i.digital-scurf.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <1175522199.18271.19.camel@petitemort.i.digital-scurf.org> Reply-To: balrogg@gmail.com, qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: dsilvers@simtec.co.uk, qemu-devel@nongnu.org Hi, On 02/04/07, Daniel Silverstone wrote: > Hi, > > Myself and my colleagues have worked hard and produced a new system > emulation for qemu for the Simtec BAST board. > > The BAST is a Samsung 2410 based board (ARM 9 based SoC, with MMU) with > various peripherals including a Davicom DM9000 Ethernet port. > > The emulation is complete enough to start Simtec's ABLE boot loader > (downloadable from www.simtec.co.uk) and also is capable of being > direct-booted with a linux kernel/initrd combination as per the > versatile etc. > > Among other things, the patch needs to add support for OHCI USB systems > not on PCI, ARM systems where SDRAM isn't at 0 (phys) and MMIO based > IDE. Naturally this has all been done as generically as made sense at > the time. > > There is one generic fix in the patch which hardly seemed worth breaking > out on its own. It corrects a bug where QEMU would ignore WIN_DIAGNOSE's > behaviour for normal drives. It assumed HDDs behaved as CDROMs under > WIN_DIAGNOSE which is not the case. > > Unfortunately I was unable to sensibly separate the patch up because of > the difficulties which stem from qemu's current source layout. E.g. it > was hard to split out the MMIO IDE from the rest of the IDE without > dramatically changing the exported symbol lists. > > Hopefully you'll be happy with the whole patch. In particular I've tried > to isolate the s3c2410x stuff away from the BAST stuff, so that in > future other 2410x based systems such as the H1940 PDA or the FIC NEO > 1973 (openmoko?) can be implemented with minimal fuss. > > We have a partially complete s3c2410x NAND driver, a partial LCD driver > and various other bits which we will submit as and when we have them > done. We have also implemented emulation of the S3C2410x SoC. I hope we can merge both implementations to come up with better emulation. Our tree is accessible at http://svn.openmoko.org/trunk/src/host/qemu-neo1973/ and our main target machine is the FIC Neo1973 which you mention above. The tree is still heavily a work-in-progress but the processor part (S3C2410 with on-chip preripherals) is quite mature. All of the on-chip peripherals described in the S3C2410A User Manual rev 1.0 except the Watchdog timer and USB Slave are emulated with high level of detail. The OHCI USB uses the same routine as the PXA2xx emulator. Things that are tested to work: OpenMoko firmware from the real device boots as a NAND Flash image. The OpenMoko rootfs can also be booted off the emulated SD card. We use the u-boot and kernel images from the original device. Input is through GPIO buttons or touchscreen connected to the on-chip ADC, output through on-chip UARTs and LCD. Audio through a codec connected to on-chip I2C and I2S busses. There is also an SPI-connected peripheral (can be driven either through the on-chip SPI interface or GPIO bit-banging). S3C2410 idle mode is supported. There's no save/restore support. Apparently there's some code duplication, which is sad but I hope we can get both machines (BAST and Neo1973) to use common code. Briefly looking at your patch, the openmoko tree seems to have a more complete/specs-conformant S3C2410 part. Regards, Andrzej