[pxe] Remove pxe_set_cached_filename()

gPXE currently overwrites the filename stored in the cached DHCP
packets when a call to PXENV_TFTP_READ_FILE or PXENV_RESTART_TFTP is
made.  This code has existed for many years as a workaround for RIS,
which seemed to require that this be done.

pxe_set_cached_filename() causes problems with the Bootix NBP, and a
recent test demonstrates that RIS will complete successfully even with
pxe_set_cached_filename() removed.  There have been many changes to
the DHCP and PXE logic since this code was first added, and it is
quite plausible that it was masking a bug that no longer exists.

Reported-by: Alex Zeffertt <alex.zeffertt@eu.citrix.com>
Debugged-by: Shao Miller <Shao.Miller@yrdsb.edu.on.ca>
Signed-off-by: Michael Brown <mcb30@etherboot.org>
This commit is contained in:
Michael Brown
2010-03-26 17:53:24 +00:00
parent 9acf442c20
commit 80d1ac7320
3 changed files with 0 additions and 37 deletions

View File

@@ -102,24 +102,6 @@ static struct pxe_dhcp_packet_creator pxe_dhcp_packet_creators[] = {
static union pxe_cached_info __bss16_array ( cached_info, [NUM_CACHED_INFOS] );
#define cached_info __use_data16 ( cached_info )
/**
* Set PXE cached TFTP filename
*
* @v filename TFTP filename
*
* This is a bug-for-bug compatibility hack needed in order to work
* with Microsoft Remote Installation Services (RIS). The filename
* used in a call to PXENV_RESTART_TFTP or PXENV_TFTP_READ_FILE must
* be returned as the DHCP filename in subsequent calls to
* PXENV_GET_CACHED_INFO.
*/
void pxe_set_cached_filename ( const unsigned char *filename ) {
memcpy ( cached_info[CACHED_INFO_DHCPACK].dhcphdr.file, filename,
sizeof ( cached_info[CACHED_INFO_DHCPACK].dhcphdr.file ) );
memcpy ( cached_info[CACHED_INFO_BINL].dhcphdr.file, filename,
sizeof ( cached_info[CACHED_INFO_BINL].dhcphdr.file ) );
}
/**
* UNLOAD BASE CODE STACK
*
@@ -236,9 +218,6 @@ PXENV_EXIT_t pxenv_restart_tftp ( struct s_PXENV_TFTP_READ_FILE
DBG ( "PXENV_RESTART_TFTP " );
/* Intel bug-for-bug hack */
pxe_set_cached_filename ( restart_tftp->FileName );
/* Words cannot describe the complete mismatch between the PXE
* specification and any possible version of reality...
*/