Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Feb 2001 11:23:10 +0900
From:      Kenjiro Cho <kjc@csl.sony.co.jp>
To:        rizzo@aciri.org
Cc:        net@freebsd.org
Subject:   Re: fxp performance ?
Message-ID:  <20010214112310G.kjc@csl.sony.co.jp>
In-Reply-To: <200102140053.f1E0rET55388@iguana.aciri.org>
References:  <200102140053.f1E0rET55388@iguana.aciri.org>

next in thread | previous in thread | raw e-mail | index | archive | help

Luigi Rizzo wrote:
> I am trying to generate (send only) packets at maximum rate on a
> 100Mbit ethernet, which means using 64-byte packets and, once you
> do the math (counting preamble, packet and inter-packet gap),
> results in some 148.000 packets-per-second (and just to get the
> idea, this also means that a new packet is transmitted every 6.72us).
> 
> Note, the above is not trivial as you need a fast CPU, and probably
> some tricks in order to avoid parf of the overhead of ip_output().
> 
> In any case, on botu a P3-650 and an Athlon-750, I managed to
> achieve this speed using the "dc" driver. When i tried the same
> with the 'fxp' driver, there was no way i managed to go above
> 105-110.000 packets per second (meaning an average of 9.1us/packet).
> 
> Any idea on what is going on ? I have spent quite some time in
> the fxp driver and cannot really tell where the problem is.
> Unfortunately my diagnostic tools do not let me see what is going
> on on the wire, whether the spacing is larger than it should be,
> etc. etc.

It might be related to the fact that the fxp driver doesn't generate
a transmission complete interrupt unless the interface queue length is
exactly 119.

Does the following change make any difference?

--- if_fxp.c-	Wed Feb 14 11:13:42 2001
+++ if_fxp.c	Wed Feb 14 11:14:27 2001
@@ -1183,6 +1183,7 @@
 	 * going again if suspended.
 	 */
 	if (txp != NULL) {
+		txp->cb_command |= FXP_CB_COMMAND_I;
 		fxp_scb_wait(sc);
 		CSR_WRITE_1(sc, FXP_CSR_SCB_COMMAND, FXP_SCB_COMMAND_CU_RESUME);
 	}

-Kenjiro


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010214112310G.kjc>