mirror of
https://github.com/ipxe/ipxe
synced 2026-02-04 06:59:59 +03:00
[dhcp] Simplify platform-specific client architecture definitions
Move the platform-specific DHCP client architecture definitions to header files of the form <ipxe/$(PLATFORM)/dhcparch.h>. This simplifies the directory structure and allows the otherwise unused arch/$(ARCH)/include/$(PLATFORM) to be removed from the include directory search path, which avoids the confusing situation in which a header file may potentially be accessed through more than one path. For Linux userspace binaries on any architecture, use the EFI values for that architecture by delegating to the EFI header file. This avoids the need to explicitly select values for Linux userspace binaries for each architecture. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
16
src/include/ipxe/dhcparch.h
Normal file
16
src/include/ipxe/dhcparch.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef _IPXE_DHCPARCH_H
|
||||
#define _IPXE_DHCPARCH_H
|
||||
|
||||
/** @file
|
||||
*
|
||||
* DHCP client architecture definitions
|
||||
*
|
||||
*/
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
|
||||
/* Include platform-specific client architecture definitions */
|
||||
#define PLATFORM_DHCPARCH(_platform) <ipxe/_platform/dhcparch.h>
|
||||
#include PLATFORM_DHCPARCH(PLATFORM)
|
||||
|
||||
#endif /* _IPXE_DHCPARCH_H */
|
||||
20
src/include/ipxe/linux/dhcparch.h
Normal file
20
src/include/ipxe/linux/dhcparch.h
Normal file
@@ -0,0 +1,20 @@
|
||||
#ifndef _IPXE_LINUX_DHCPARCH_H
|
||||
#define _IPXE_LINUX_DHCPARCH_H
|
||||
|
||||
/** @file
|
||||
*
|
||||
* DHCP client architecture definitions
|
||||
*
|
||||
*/
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
|
||||
/*
|
||||
* There are no specification-defined values for DHCP architecture for
|
||||
* PXE clients running as Linux userspace applications. Pretend to be
|
||||
* the equivalent EFI client.
|
||||
*
|
||||
*/
|
||||
#include <ipxe/efi/dhcparch.h>
|
||||
|
||||
#endif /* _IPXE_LINUX_DHCPARCH_H */
|
||||
Reference in New Issue
Block a user