cvs commit: src/sys/pci if_sk.c

Ruslan Ermilov ru at FreeBSD.org
Wed Nov 17 14:43:37 PST 2004


On Wed, Nov 17, 2004 at 09:35:23PM +0000, John-Mark Gurney wrote:
> jmg         2004-11-17 21:35:22 UTC
> 
>   FreeBSD src repository
> 
>   Modified files:
>     sys/pci              if_sk.c 
>   Log:
>   only clear the IFF_OACTIVE flag when we have a chance of being able to
>   queue a packet to the hardware... instead of when the hardware queue is
>   empty..
>   
>   don't initalize cur_tx now that it doesn't need to be...
>   
>   Pointed out by: bde
>   
>   Revision  Changes    Path
>   1.92      +4 -4      src/sys/pci/if_sk.c
> 
Wrong wording.  The correct wording would be:

> clear the IFF_OACTIVE flag AS SOON AS we have a chance of being
> able to queue a packet to the hardware... instead of ONLY when
> the hardware TX queue is empty..

My old patch (that I didn't commit due to the lack of h/w),
resets IFF_OACTIVE inside the while() loop, like this:

                sc_if->sk_cdata.sk_tx_cnt--;
+               ifp->if_flags &= ~IFF_OACTIVE;
                SK_INC(idx, SK_TX_RING_CNT);

I believe this is more correct than what got committed,
but I cannot prove it.  ;)


Cheers,
-- 
Ruslan Ermilov
ru at FreeBSD.org
FreeBSD committer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/cvs-all/attachments/20041118/1cc39e20/attachment.bin


More information about the cvs-all mailing list