From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=34064 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJw94-0007fj-0O for qemu-devel@nongnu.org; Wed, 02 Jun 2010 18:10:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OJw92-0002Gb-Gu for qemu-devel@nongnu.org; Wed, 02 Jun 2010 18:10:42 -0400 Received: from adelie.canonical.com ([91.189.90.139]:37462) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OJw92-0002GO-AU for qemu-devel@nongnu.org; Wed, 02 Jun 2010 18:10:40 -0400 Received: from loganberry.canonical.com ([91.189.90.37]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1OJw90-00034q-Cu for ; Wed, 02 Jun 2010 23:10:38 +0100 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id B33392E8064 for ; Wed, 2 Jun 2010 23:10:37 +0100 (BST) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Date: Wed, 02 Jun 2010 22:02:55 -0000 From: Ryan Harper Sender: bounces@canonical.com References: <20100517132539.15293.52060.malonedeb@gandwana.canonical.com> Message-Id: <20100602220255.22944.37999.malone@soybean.canonical.com> Errors-To: bounces@canonical.com Subject: [Qemu-devel] [Bug 581737] Re: Can't read e1000 NIC EEPROM on NetBSD guest Reply-To: Bug 581737 <581737@bugs.launchpad.net> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org I applied this patch against qemu.git and it does indeed fix the issue for netbsd referenced in the bug. Please submit this patch against upstream qemu.git and include a Signed-off-by: in the patch. ** Changed in: qemu Status: New =3D> Incomplete -- = Can't read e1000 NIC EEPROM on NetBSD guest https://bugs.launchpad.net/bugs/581737 You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. Status in QEMU: Incomplete Bug description: QEMU Version: qemu-0.12.4 Host OS: NetBSD/i386 5.0.2 Guest OS: NetBSD/i386 5.1_RC1 On this environment, guest NetBSD tries to attach e1000 NIC using its own w= m(4) driver but fails to read EEPROM as the following: --- NetBSD 5.1_RC1 (GENERIC) #0: Sat Apr 24 23:26:09 UTC 2010 builds@b7.netbsd.org:/home/builds/ab/netbsd-5-1-RC1/i386/2010042500= 32Z-obj/home/builds/ab/ netbsd-5-1-RC1/src/sys/arch/i386/compile/GENERIC total memory =3D 127 MB avail memory =3D 113 MB Bochs Bochs : drm at vga1 not configured wm0 at pci0 dev 3 function 0: Intel i82540EM 1000BASE-T Ethernet, rev. 3 wm0: interrupting at irq 11 wm0: unable to read Ethernet address isa0 at pcib0 : --- You can reproduce this with NetBSD/i386 install CD image: ftp://ftp.NetBSD.org/pub/NetBSD/NetBSD-5.1_RC1/iso/i386cd-5.1_RC1.iso % qemu -cdrom i386cd-5.1_RC1.iso -boot d ---in QEMU window--- [type ^C to quit installer] # dmesg | grep wm0 ------ Per DBGOUT(EEPROM) messages, it show too large eecd_state.bitnum values, i.= e. EEPROM state is not reset properly. The set_eecd() function in e1000.c clears EEPROM internal state values on S= K rising edge during CS=3D=3DL. But according to FM93C06 EEPROM (which is MicroWire compatible) data sheet, EEPROM internal status should be cleared on CS rise edge regardless of SK i= nput: "... a rising edge on this signal is required to reset the internal state-= machine to accept a new cycle .." Intel's em driver seems to explicitly raise and lower SK output after CS is= negated in em_standby_eeprom() so many other OSes that use Intel's driver don't have this problem with cur= rent e1000.c implementation, but I can't find articles that say the MICROWIRE or EEPROM spec requires su= ch sequence. With the attached patch, NetBSD guest properly gets MAC address from e1000 = NIC EEPROM.