Subject: Re: New RTL8168 revision(?)
To: None <d.den.brok@uni-bonn.de>
From: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
List: tech-kern
Date: 03/19/2007 21:05:21
d.den.brok@uni-bonn.de wrote:

> >> Ah, yes, sorry. And you're right, IPv6 seems not to work yet. That
> >> "pci_mem_find: void region" below quite certainly belongs to re(4), also
> >> (before your patch, there were three such lines).
> >
> > Okay, could you try this one?
> 
> I'm sorry to say it doesn't seem to work, at least dhclient is unable to  
> acquire an IP now.

There is a botch in my patch (diff attached),
but does the previous one work on dhclient?
i.e. re(4) with the latest patch is attached
but no TX/RX packets are sent/received on it?
Does tcpdump(8) show anything?

For now I don't have idea which part break something
because it works fine on my 8169S and 8139C+..

> Note that I'm on netbsd-4, apart from if_re_pci.c from  
> -current, against which the patch wouldn't apply cleanly otherwise.

I think only difference on if_re_pci.c between -current
and netbsd-4 is boolean_t -> bool changes.
---
Izumi Tsutsui

--- if_re_pci.c.orig	2007-03-19 20:57:07.000000000 +0900
+++ if_re_pci.c	2007-03-19 20:57:09.000000000 +0900
@@ -232,7 +232,7 @@
 	case PCI_MAPREG_TYPE_MEM | PCI_MAPREG_MEM_TYPE_32BIT:
 	case PCI_MAPREG_TYPE_MEM | PCI_MAPREG_MEM_TYPE_64BIT:
 		memh_valid = (pci_mapreg_map(pa, RTK_PCI_LOMEM,
-		    PCI_MAPREG_TYPE_MEM, 0, &memt, &memh, NULL, &memsize) == 0);
+		    memtype, 0, &memt, &memh, NULL, &memsize) == 0);
 	default:
 		memh_valid = 0;
 	}