Re: Driver for via-velocity gigabit NIC

Timothy Legge <[email protected]> Tue, 07 Mar 2006 23:17:01 -0400
Newsgroups gmane.network.etherboot.devel
Message-ID <[email protected]>
Timothy Legge wrote:
> Marty Connor wrote:
> 
>> On Mar 6, 2006, at 8:29 PM, Timothy Legge wrote:
>>
>>> Hi
>>> I have a working version of a driver for the via-velocity 6120  based 
>>> cards.
>>
>>
>>
>> Nice.  Is this a chip that is on standalone PCI cards or something  
>> that is more on motherboards only?
> 
> 
> Yes, they are available on Ebay for next to nothing.
> 
>>> The only problem is that it is only working on 5.2.  With 5.4, it  
>>> causes a computer reset on a dual opteron machine and causes an old  
>>> Pentium to freeze.
>>> I am currently at a loss as to why.  I imagine it is the result of  
>>> some  bug or another but I have never seen a driver work on one  
>>> version and fail so badly on another.
>>> The bug manifests itself on the first or second go through the  
>>> transmit function and it seems to fail part way though.
>>> Does anyone have any quick thought on obvious things to review?
>>
>>
>>
>> Well, the two things that come to mind are interrupts and the  
>> transmit/receive buffer structure.
> 
> 
> I had not considered Interupts.  As for the buffer structure it is 4 
> transmit and 8 receive buffers with the required 64 byte alignment.  I 
> did do the alignment differntly this time but it is very similar to the 
> via-rhine method.

Well, I found the issue or more correctly I ripped out the method I was 
using for 64 byte alignment of the rings and buffers and replaced it 
with the method I used with the r8169 driver.  Afters hours of wasted 
effort, the tried and true method worked in just a few minutes...

I have committed the driver to the cvs but I still need to do a cleanup 
to remove some dead code, implement multicast and pxeify the driver.

There are at least one or two items that should be moved to pci.c but I 
will review it first to ensure that it is truely necessary.  If it is 
necessary, I will probably need to implement a cleaner versions of the 
functions as they do the bare minimum necessary for my purposes.

Tim


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642