Subject: Re: [PATCH] [e1000]: Remove unnecessary tx_lock

From: jamal <[email-masked]>
Date: Sun, 06 Aug 2006 08:33:09 -0400

BTW, if you notice in the attached patch i have:
+       /* number of descriptors needed to wake up netdev */
+       unsigned int waket;
+       /* number of descriptors we allow to prune at a time */
+       unsigned int prunet;

and:

+       /* hard-coding for now, but we should be able to
+        * use ethtool or module params in the future
+       */
+       txdr->prunet = txdr->count>>2;
+       txdr->waket = txdr->count>>3;

i.e the two thresholds are based on the tx ring sizes.

I didnt like TX_WAKE_THRESHOLD and  E1000_TX_WEIGHT hardcoding.
if i make the ring smaller then these values could be invalid.
I also experimented with varying the two thresholds with varying traffic
throughput - lets say results are still magical and i am still looking
at it.

Q: Do you know the historical context of why TX_WAKE_THRESHOLD and
E1000_TX_WEIGHT are hard-coded (and not for example related to the size
of the ring)? Jesse?
Otherwise i would like to submit a patch for the above. eventually
probably even allow the setting via ethtool.

cheers,
jamal