Thread (18 messages) flat view 18 messages, 7 authors, 2005-09-09

Re: [PATCH] 3c59x: read current link status from phy

From: Andy Fleming <hidden>
Date: 2005-09-09 18:08:36
Also in: lkml

On Sep 9, 2005, at 05:10, Bogdan Costescu wrote:
On Thu, 8 Sep 2005, Andy Fleming wrote:

quoted
Is the cost of an extra read every minute really too high?
You probably didn't look at the code. The MII registers are not  
exposed in the PCI space, they need to be accessed through a serial  
protocol, such that each MII register read is in fact about 200 (in  
total) of outw and inw/inl operations.
I certainly looked at the code.  I'm aware that there are probably  
about 150 microseconds of work, tops, to do each read.  Do it outside  
of interrupt time, and separate from the normal thread of the driver  
(like a task struct), and it shouldn't take up that much CPU time.   
And if it's being done every minute, it's really not a big deal, is it?

Anyway, it's not a big deal to me.  I agree that doing only one read,  
if the link is reported as up, is a good idea.  I'll be sure to put  
it in the next rev of the PHY Layer.

I also agree that polling should be done every 5 seconds, at least  
when the link is down.

Andy Fleming
Freescale Open Source Team
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help