From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ie0-f195.google.com ([209.85.223.195]) by pp; Mon Nov 10 05:39:26 EST 2014 Received: by mail-ie0-f195.google.com with SMTP id rp18so2091543iec.2 for <9front@9front.org>; Mon, 10 Nov 2014 02:39:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=fdbcUCfevj6zLRhcHoHkKwUn7fDzwYYvhlF/5CkowXQ=; b=LEXgBKw/jwDdKL5y2Fe4EvB6axUHYBNcuW+bwonhoccx60XRGYoaB2JSzlVyAqPfRK +T2xDAS6usqRfBRmLmC1oyUlR5MNSmFZj8PWUeik6RuwLx51LP+m/IWAiEfDTwYcfxAb MXIW5vlO/1YYOjqYjLd9dzay8jsvbcDzHrenwWHv8RFkvDfpWxUE9wRgr/MRRDjfAGtt qU5baE556ICIGWt78hYbvVyZCr8jUPpHNgTQnDxxv3Dubwe5HWQmWSAGRCzhhcMGllG1 GDTZ6MA7f2gtUMFzCMFHw83p7pREEfheiHHbwajtfCz2+DAi44fEHr1osdMnaMEuAeRH TNeg== MIME-Version: 1.0 X-Received: by 10.43.138.201 with SMTP id it9mr34936464icc.2.1415615962962; Mon, 10 Nov 2014 02:39:22 -0800 (PST) Received: by 10.107.28.136 with HTTP; Mon, 10 Nov 2014 02:39:22 -0800 (PST) In-Reply-To: References: Date: Mon, 10 Nov 2014 11:39:22 +0100 Message-ID: List-ID: <9front.9front.org> X-Glyph: ➈ X-Bullshit: STM storage hardware plugin firewall Subject: ether8169.c: support for rtl8411b (rtl8168g family) From: quux quux To: 9front@9front.org Content-Type: text/plain; charset=UTF-8 Without the inlined patch: term% grep rtl /dev/kmesg rtl8169: unknown mac 8168 5c800000 I have no idea what the correct Macv?? is, 41 is arbitrary. Someone who knows what they are doing may have to review this. - based on the following changes in FreeBSD/OpenBSD: http://svnweb.freebsd.org/base?view=revision&revision=257305 http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/dev/ic/re.c.diff?r1=1.144&r2=1.145&f=h http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/dev/ic/rtl81x9reg.h.diff?r1=1.76&r2=1.77&f=h http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/dev/ic/rtl81x9reg.h.diff?r1=1.83&r2=1.84&f=h - sysinfo _with_ patch, on amd64 (please disregard non-working audio and iwl stuff): http://sysinfo.9front.org/src/86/body - tested only on amd64; machine is an Acer V5-573G (exact model: V5-573G-74518G1Takk) diff -r 7c2d0e7d27a7 sys/src/9/pc/ether8169.c --- a/sys/src/9/pc/ether8169.c Sun Nov 09 13:41:06 2014 -0800 +++ b/sys/src/9/pc/ether8169.c Mon Nov 10 00:00:35 2014 +0100 @@ -121,6 +121,7 @@ Macv29 = 0x40800000, /* RTL8101/8102E */ Macv30 = 0x24000000, /* RTL8101E? (untested) */ Macv40 = 0x4c000000, /* RTL8168G */ + Macv41 = 0x5c800000, /* RTL8411B */ Ifg0 = 0x01000000, /* Interframe Gap 0 */ Ifg1 = 0x02000000, /* Interframe Gap 1 */ }; @@ -702,6 +703,7 @@ cplusc |= Txenb|Mulrw; switch(ctlr->macv){ case Macv40: + case Macv41: cplusc |= Macstatdis; break; default: @@ -1051,6 +1053,7 @@ case Macv29: case Macv30: case Macv40: + case Macv41: break; } return 0;