From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1H9Tk4-00014X-JR for qemu-devel@nongnu.org; Tue, 23 Jan 2007 17:03:48 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1H9Tk3-00013U-KX for qemu-devel@nongnu.org; Tue, 23 Jan 2007 17:03:48 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1H9Tk3-00013H-HD for qemu-devel@nongnu.org; Tue, 23 Jan 2007 17:03:47 -0500 Received: from [84.96.92.55] (helo=smtP.neuf.fr) by monty-python.gnu.org with esmtp (Exim 4.52) id 1H9Tk3-0002R1-0P for qemu-devel@nongnu.org; Tue, 23 Jan 2007 17:03:47 -0500 Received: from [84.102.211.142] by sp604004mt.gpm.neuf.ld (Sun Java System Messaging Server 6.2-5.05 (built Feb 16 2006)) with ESMTP id <0JCC00ALRCMW3PB0@sp604004mt.gpm.neuf.ld> for qemu-devel@nongnu.org; Tue, 23 Jan 2007 22:49:44 +0100 (CET) Date: Tue, 23 Jan 2007 22:49:59 +0100 From: Fabrice Bellard Subject: Re: [Qemu-devel] [PATCH] PIIX4 SMBus host, EEPROM device emulation In-reply-to: Message-id: <45B68307.9090509@bellard.org> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7BIT References: 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 Ed Swierk wrote: > The attached patch adds SMBus host support to the emulated PIIX4 power > management device (acpi.c), and adds an emulated serial EEPROM device > accessible via the SMBus interface. > > I tried to follow the Intel 82371AB spec for the SMBus support; the > interface should be generic enough to implement a variety of > SMBus-compliant devices. > > The EEPROM device can use a file for persistent storage > (smbus_eeprom.bin in the BIOS directory). If this file does not exist, > a temporary buffer is used instead. > > I tested the devices with Linux using the i2c-piix4 host driver and > the eeprom chip driver. I have no idea what will happen on other OSes. > > Comments and suggestions welcome. > [...] OK, but avoid using mmap() in the device code. Moreover, files in the BIOS directory are not writable. Regards, Fabrice.