Kaynağa Gözat

Use start_timer_nodelay() in protocols which rely on the retry timer

to generate the initial transmission; this cuts off around 0.3s per
instantiated connection.
tags/v0.9.3
Michael Brown 17 yıl önce
ebeveyn
işleme
2ff1b1245b
3 değiştirilmiş dosya ile 3 ekleme ve 3 silme
  1. 1
    1
      src/net/tcp.c
  2. 1
    1
      src/net/udp/dhcp.c
  3. 1
    1
      src/net/udp/tftp.c

+ 1
- 1
src/net/tcp.c Dosyayı Görüntüle

@@ -232,7 +232,7 @@ static int tcp_open ( struct xfer_interface *xfer, struct sockaddr *peer,
232 232
 		goto err;
233 233
 
234 234
 	/* Start timer to initiate SYN */
235
-	start_timer ( &tcp->timer );
235
+	start_timer_nodelay ( &tcp->timer );
236 236
 
237 237
 	/* Attach parent interface, transfer reference to connection
238 238
 	 * list and return

+ 1
- 1
src/net/udp/dhcp.c Dosyayı Görüntüle

@@ -912,7 +912,7 @@ int start_dhcp ( struct job_interface *job, struct net_device *netdev,
912 912
 		goto err;
913 913
 
914 914
 	/* Start timer to initiate initial DHCPREQUEST */
915
-	start_timer ( &dhcp->timer );
915
+	start_timer_nodelay ( &dhcp->timer );
916 916
 
917 917
 	/* Attach parent interface, mortalise self, and return */
918 918
 	job_plug_plug ( &dhcp->job, job );

+ 1
- 1
src/net/udp/tftp.c Dosyayı Görüntüle

@@ -657,7 +657,7 @@ int tftp_open ( struct xfer_interface *xfer, struct uri *uri ) {
657 657
 		goto err;
658 658
 
659 659
 	/* Start timer to initiate RRQ */
660
-	start_timer ( &tftp->timer );
660
+	start_timer_nodelay ( &tftp->timer );
661 661
 
662 662
 	/* Attach to parent interface, mortalise self, and return */
663 663
 	xfer_plug_plug ( &tftp->xfer, xfer );

Loading…
İptal
Kaydet