Просмотр исходного кода

[udp] Move high-frequency debug messages to DBGLVL_EXTRA

This makes it possible to leave UDP debugging enabled in order to see
interesting UDP events, without flooding the console with at least one
message per packet.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 12 лет назад
Родитель
Сommit
e972057381
1 измененных файлов: 5 добавлений и 5 удалений
  1. 5
    5
      src/net/udp.c

+ 5
- 5
src/net/udp.c Просмотреть файл

220
 	udphdr->chksum = tcpip_chksum ( udphdr, len );
220
 	udphdr->chksum = tcpip_chksum ( udphdr, len );
221
 
221
 
222
 	/* Dump debugging information */
222
 	/* Dump debugging information */
223
-	DBGC ( udp, "UDP %p TX %d->%d len %d\n", udp,
224
-	       ntohs ( udphdr->src ), ntohs ( udphdr->dest ),
225
-	       ntohs ( udphdr->len ) );
223
+	DBGC2 ( udp, "UDP %p TX %d->%d len %d\n", udp,
224
+		ntohs ( udphdr->src ), ntohs ( udphdr->dest ),
225
+		ntohs ( udphdr->len ) );
226
 
226
 
227
 	/* Send it to the next layer for processing */
227
 	/* Send it to the next layer for processing */
228
 	if ( ( rc = tcpip_tx ( iobuf, &udp_protocol, src, dest, netdev,
228
 	if ( ( rc = tcpip_tx ( iobuf, &udp_protocol, src, dest, netdev,
317
 	iob_pull ( iobuf, sizeof ( *udphdr ) );
317
 	iob_pull ( iobuf, sizeof ( *udphdr ) );
318
 
318
 
319
 	/* Dump debugging information */
319
 	/* Dump debugging information */
320
-	DBGC ( udp, "UDP %p RX %d<-%d len %zd\n", udp,
321
-	       ntohs ( udphdr->dest ), ntohs ( udphdr->src ), ulen );
320
+	DBGC2 ( udp, "UDP %p RX %d<-%d len %zd\n", udp,
321
+		ntohs ( udphdr->dest ), ntohs ( udphdr->src ), ulen );
322
 
322
 
323
 	/* Ignore if no matching connection found */
323
 	/* Ignore if no matching connection found */
324
 	if ( ! udp ) {
324
 	if ( ! udp ) {

Загрузка…
Отмена
Сохранить