From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=58550 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q6oJV-00031m-C9 for qemu-devel@nongnu.org; Mon, 04 Apr 2011 14:15:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q6oJT-0001oN-MI for qemu-devel@nongnu.org; Mon, 04 Apr 2011 14:15:45 -0400 Received: from hall.aurel32.net ([88.191.126.93]:55054) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q6oJT-0001me-Hf for qemu-devel@nongnu.org; Mon, 04 Apr 2011 14:15:43 -0400 Date: Mon, 4 Apr 2011 20:15:30 +0200 From: Aurelien Jarno Subject: Re: [Qemu-devel] [PATCH] lan9118: Ignore write to MAC_VLAN1 register Message-ID: <20110404181530.GC23034@volta.aurel32.net> References: <1301406072-8649-1-git-send-email-anemo@mba.ocn.ne.jp> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <1301406072-8649-1-git-send-email-anemo@mba.ocn.ne.jp> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Atsushi Nemoto Cc: qemu-devel@nongnu.org, Paul Brook On Tue, Mar 29, 2011 at 10:41:12PM +0900, Atsushi Nemoto wrote: > Since kernel 2.6.38, smsc911x driver writes to VLAN1 registger. > > Signed-off-by: Atsushi Nemoto > --- > hw/lan9118.c | 2 ++ > 1 files changed, 2 insertions(+), 0 deletions(-) > > diff --git a/hw/lan9118.c b/hw/lan9118.c > index af6949f..62aead3 100644 > --- a/hw/lan9118.c > +++ b/hw/lan9118.c > @@ -785,6 +785,8 @@ static void do_mac_write(lan9118_state *s, int reg, uint32_t val) > case MAC_FLOW: > s->mac_flow = val & 0xffff0000; > break; > + case MAC_VLAN1: > + break; /* just ignore */ > default: > hw_error("lan9118: Unimplemented MAC register write: %d = 0x%x\n", > s->mac_cmd & 0xf, val); Is it really safe ignoring write to this register? If yes, it's probably a good idea to explain why in a comment. In any case, if supporting this register is easy to do, it would be the best option. -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net