From owner-freebsd-hackers@FreeBSD.ORG Sun Jan 24 20:17:45 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8B1131065679 for ; Sun, 24 Jan 2010 20:17:45 +0000 (UTC) (envelope-from pyunyh@gmail.com) Received: from qw-out-2122.google.com (qw-out-2122.google.com [74.125.92.25]) by mx1.freebsd.org (Postfix) with ESMTP id 3C5878FC15 for ; Sun, 24 Jan 2010 20:17:44 +0000 (UTC) Received: by qw-out-2122.google.com with SMTP id 5so106645qwd.7 for ; Sun, 24 Jan 2010 12:17:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:received:from:date:to:cc :subject:message-id:reply-to:references:mime-version:content-type :content-disposition:in-reply-to:user-agent; bh=pM9ohRiTDiOEN5+JFb7t/6TRwHuaBxBp8I/6P97TRFg=; b=RVbMhUJzkFghEcwsK6WeECdE4pr70CF4UCSKRlMjAH3iUqWcN9a20d0TrTTOFqLQFL Q9BWOQixrdaZEY7eA1mSN3xyvh/v9+AkWn6rVXMM+IicExvZhvgDgUVKNOJmt3FyvhUB FmT3ZvnQSI/Ti20gkHU6S+8Q3r9K+I1FSxYws= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:date:to:cc:subject:message-id:reply-to:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=i2EiwrYOWUKMIWBH1WZDIOuaJqqOi3hZAA8r8HruZqOXhvKTl+pzVZBiITLlyKFpYr tKJK4qmrXAnfhJK90Fn6LG7d1m0giEmjb+371MPczFu6jGlC4V806THune88jnRhuGi4 67nryG63bAPmPNfbh7FnDuxE6pON/nUpTT9nk= Received: by 10.224.82.144 with SMTP id b16mr3585840qal.193.1264364264171; Sun, 24 Jan 2010 12:17:44 -0800 (PST) Received: from pyunyh@gmail.com ([174.35.1.224]) by mx.google.com with ESMTPS id 23sm1757007qyk.15.2010.01.24.12.17.41 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 24 Jan 2010 12:17:42 -0800 (PST) Received: by pyunyh@gmail.com (sSMTP sendmail emulation); Sun, 24 Jan 2010 12:17:40 -0800 From: Pyun YongHyeon Date: Sun, 24 Jan 2010 12:17:40 -0800 To: zloidemon Message-ID: <20100124201739.GA1187@michelle.cdnetworks.com> References: <201001240101.54360.g.veniamin@googlemail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201001240101.54360.g.veniamin@googlemail.com> User-Agent: Mutt/1.4.2.3i Cc: freebsd-hackers@freebsd.org Subject: Re: ethernet SiS(190/191) problem driver X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: pyunyh@gmail.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Jan 2010 20:17:45 -0000 On Sun, Jan 24, 2010 at 01:01:53AM +0700, zloidemon wrote: > Hi all! > > zlobook# uname -a > FreeBSD zlobook.local 8.0-STABLE FreeBSD 8.0-STABLE #22: Sun Jan 3 12:17:19 > KRAT 2010 root@zlobook.local:/usr/obj/usr/src/sys/zlobook i386 > > none0@pci0:0:4:0: class=0x020000 card=0x08021558 chip=0x01911039 > rev=0x02 hdr=0x00 > vendor = 'Silicon Integrated Systems (SiS)' > device = 'SIS190 (SIS190)' > class = network > subclass = ethernet > > this is chip=0x01911039 real SiS191 ethernet card > I'm not sure but SiS191 is gigabit controller so I guess you have a variant of SiS190. > i downloaded this is driver for sis 190 from http://pohoyda.gmxhome.de/sis190- > freebsd-7.tar.gz > > a problem when compiling.... > > zlobook# make > Warning: Object directory not changed from original /root/123/sis190-FreeBSD-7 > @ -> /usr/src/sys > machine -> /usr/src/sys/i386/include > awk -f @/tools/makeobjops.awk @/kern/device_if.m -h > awk -f @/tools/makeobjops.awk @/kern/bus_if.m -h > awk -f @/tools/makeobjops.awk @/dev/pci/pci_if.m -h > awk -f @/tools/makeobjops.awk @/dev/mii/miibus_if.m -h > cc -O2 -pipe -fno-strict-aliasing -Werror -D_KERNEL -DKLD_MODULE -nostdinc - > I. -I@ -I@/contrib/altq -finline-limit=8000 --param inline-unit-growth=100 -- > param large-function-growth=1000 -fno-common -mno-align-long-strings - > mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 > -ffreestanding -fstack-protector -std=iso9899:1999 -fstack-protector -Wall - > Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes - > Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat- > extensions -c if_sis19x.c > cc1: warnings being treated as errors > if_sis19x.c:148: warning: pointer type mismatch in conditional expression > *** Error code 1 > > Stop in /root/sis190-FreeBSD-7. > > I made a patch for the driver. Now support SiS 191 and SiS 190. Tested only > SiS 191 > [...] > i see a problem every 10-30 seconds > > sis19x0: error_bits=0x40020001 > sis19x0: watchdog timeout > sis19x0: watchdog timeout > sis19x0: watchdog timeout > sis19x0: watchdog timeout > sis19x0: watchdog timeout > sis19x0: watchdog timeout > sis19x0: error_bits=0x40020001 > sis19x0: watchdog timeout > > 64 bytes from 192.168.3.100: icmp_seq=52 ttl=128 time=0.256 ms > 64 bytes from 192.168.3.100: icmp_seq=53 ttl=128 time=0.272 ms > 64 bytes from 192.168.3.100: icmp_seq=54 ttl=128 time=0.294 ms > 64 bytes from 192.168.3.100: icmp_seq=55 ttl=128 time=4148.943 ms > 64 bytes from 192.168.3.100: icmp_seq=56 ttl=128 time=3150.245 ms > 64 bytes from 192.168.3.100: icmp_seq=57 ttl=128 time=2148.678 ms > 64 bytes from 192.168.3.100: icmp_seq=58 ttl=128 time=1148.346 ms > 64 bytes from 192.168.3.100: icmp_seq=59 ttl=128 time=147.464 ms > 64 bytes from 192.168.3.100: icmp_seq=60 ttl=128 time=0.111 ms > > somehow fix this possible? Because I'm not familiar with the code, I'm not sure whether this change is enough or not. If I remember correctly there were a couple of request for SiS190/SiS191 support and Alexander Pohoyda already wrote the driver for FreeBSD. The problem is I have no way to test his driver because there seems to be no way to buy stand-alone PCI/PCIe SiS190/SiS191 controller in market. All I can find was LOM implementation. Linux also has driver for SiS190/SiS191 and it has minimal support code as SiS didn't release datasheet to open source developers. But the code is relatively simple except using some magic values so I guess Alexander Pohoyda can help you.