Ver código fonte

[pxe] Add debug message to display real-mode segment addresses

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 8 anos atrás
pai
commit
7d48affec2
1 arquivos alterados com 11 adições e 0 exclusões
  1. 11
    0
      src/arch/i386/interface/pxe/pxe_call.c

+ 11
- 0
src/arch/i386/interface/pxe/pxe_call.c Ver arquivo

@@ -54,6 +54,12 @@ extern void pxe_int_1a ( void );
54 54
 /** INT 1A hooked flag */
55 55
 static int int_1a_hooked = 0;
56 56
 
57
+/** Real-mode code segment size */
58
+extern char _text16_memsz[];
59
+
60
+/** Real-mode data segment size */
61
+extern char _data16_memsz[];
62
+
57 63
 /** PXENV_UNDI_TRANSMIT API call profiler */
58 64
 static struct profiler pxe_api_tx_profiler __profiler =
59 65
 	{ .name = "pxeapi.tx" };
@@ -331,6 +337,11 @@ int pxe_start_nbp ( void ) {
331 337
 	int discard_b, discard_c, discard_d, discard_D;
332 338
 	uint16_t status;
333 339
 
340
+	DBGC ( &pxe_netdev, "PXE NBP starting with netdev %s, code %04x:%04x, "
341
+	       "data %04x:%04x\n", ( pxe_netdev ? pxe_netdev->name : "<none>" ),
342
+	       rm_cs, ( ( unsigned int ) _text16_memsz ),
343
+	       rm_ds, ( ( unsigned int ) _data16_memsz ) );
344
+
334 345
 	/* Allow restarting NBP via PXENV_RESTART_TFTP */
335 346
 	jmp = rmsetjmp ( pxe_restart_nbp );
336 347
 	if ( jmp )

Carregando…
Cancelar
Salvar