diff options
author | H. Peter Anvin <hpa@zytor.com> | 2010-02-03 16:06:41 -0800 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2010-02-03 16:06:41 -0800 |
commit | addaeaeb3949d576c4e0eb5cfc133b7c3bcfa8fa (patch) | |
tree | 2ffea726dc494e87ecc9f506bc6a2bc9242730e3 /gpxe/src/arch/i386/include/gpxe | |
parent | 5c0f48e49f8d7d084810ecf0b98a76aaebb44835 (diff) | |
parent | e7a5f95432132c8fc8f8ede39fda1d368002ddd8 (diff) | |
download | syslinux.git-addaeaeb3949d576c4e0eb5cfc133b7c3bcfa8fa.tar.gz syslinux.git-addaeaeb3949d576c4e0eb5cfc133b7c3bcfa8fa.tar.xz syslinux.git-addaeaeb3949d576c4e0eb5cfc133b7c3bcfa8fa.zip |
Merge branch 'master' into i915res
Diffstat (limited to 'gpxe/src/arch/i386/include/gpxe')
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/abft.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/bios_nap.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/bios_smbios.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/bios_timer.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/ibft.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/memtop_umalloc.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/rdtsc_timer.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/sbft.h | 125 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/timer2.h | 2 | ||||
-rw-r--r-- | gpxe/src/arch/i386/include/gpxe/x86_io.h | 2 |
10 files changed, 143 insertions, 0 deletions
diff --git a/gpxe/src/arch/i386/include/gpxe/abft.h b/gpxe/src/arch/i386/include/gpxe/abft.h index 1c651ef1..9065e61a 100644 --- a/gpxe/src/arch/i386/include/gpxe/abft.h +++ b/gpxe/src/arch/i386/include/gpxe/abft.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #include <stdint.h> #include <gpxe/acpi.h> #include <gpxe/if_ether.h> diff --git a/gpxe/src/arch/i386/include/gpxe/bios_nap.h b/gpxe/src/arch/i386/include/gpxe/bios_nap.h index f1c721e9..c32429b9 100644 --- a/gpxe/src/arch/i386/include/gpxe/bios_nap.h +++ b/gpxe/src/arch/i386/include/gpxe/bios_nap.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef NAP_PCBIOS #define NAP_PREFIX_pcbios #else diff --git a/gpxe/src/arch/i386/include/gpxe/bios_smbios.h b/gpxe/src/arch/i386/include/gpxe/bios_smbios.h index 0a6f277a..83726b11 100644 --- a/gpxe/src/arch/i386/include/gpxe/bios_smbios.h +++ b/gpxe/src/arch/i386/include/gpxe/bios_smbios.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef SMBIOS_PCBIOS #define SMBIOS_PREFIX_pcbios #else diff --git a/gpxe/src/arch/i386/include/gpxe/bios_timer.h b/gpxe/src/arch/i386/include/gpxe/bios_timer.h index 7e3caa3c..ed9df522 100644 --- a/gpxe/src/arch/i386/include/gpxe/bios_timer.h +++ b/gpxe/src/arch/i386/include/gpxe/bios_timer.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef TIMER_PCBIOS #define TIMER_PREFIX_pcbios #else diff --git a/gpxe/src/arch/i386/include/gpxe/ibft.h b/gpxe/src/arch/i386/include/gpxe/ibft.h index 5eef547b..c41e2e40 100644 --- a/gpxe/src/arch/i386/include/gpxe/ibft.h +++ b/gpxe/src/arch/i386/include/gpxe/ibft.h @@ -28,6 +28,8 @@ * */ +FILE_LICENCE ( BSD2 ); + /** @file * * iSCSI boot firmware table diff --git a/gpxe/src/arch/i386/include/gpxe/memtop_umalloc.h b/gpxe/src/arch/i386/include/gpxe/memtop_umalloc.h index a3cd2c01..eaf7025b 100644 --- a/gpxe/src/arch/i386/include/gpxe/memtop_umalloc.h +++ b/gpxe/src/arch/i386/include/gpxe/memtop_umalloc.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef UMALLOC_MEMTOP #define UMALLOC_PREFIX_memtop #else diff --git a/gpxe/src/arch/i386/include/gpxe/rdtsc_timer.h b/gpxe/src/arch/i386/include/gpxe/rdtsc_timer.h index 0e03d707..67ba22f0 100644 --- a/gpxe/src/arch/i386/include/gpxe/rdtsc_timer.h +++ b/gpxe/src/arch/i386/include/gpxe/rdtsc_timer.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef TIMER_RDTSC #define TIMER_PREFIX_rdtsc #else diff --git a/gpxe/src/arch/i386/include/gpxe/sbft.h b/gpxe/src/arch/i386/include/gpxe/sbft.h new file mode 100644 index 00000000..30038436 --- /dev/null +++ b/gpxe/src/arch/i386/include/gpxe/sbft.h @@ -0,0 +1,125 @@ +#ifndef _GPXE_SBFT_H +#define _GPXE_SBFT_H + +/* + * Copyright (C) 2009 Fen Systems Ltd <mbrown@fensystems.co.uk>. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, + * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + * OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +FILE_LICENCE ( BSD2 ); + +/** @file + * + * SRP boot firmware table + * + * The working draft specification for the SRP boot firmware table can + * be found at + * + * http://etherboot.org/wiki/srp/sbft + * + */ + +#include <stdint.h> +#include <gpxe/acpi.h> +#include <gpxe/scsi.h> +#include <gpxe/srp.h> +#include <gpxe/ib_srp.h> + +/** SRP Boot Firmware Table signature */ +#define SBFT_SIG "sBFT" + +/** An offset from the start of the sBFT */ +typedef uint16_t sbft_off_t; + +/** + * SRP Boot Firmware Table + */ +struct sbft_table { + /** ACPI header */ + struct acpi_description_header acpi; + /** Offset to SCSI subtable */ + sbft_off_t scsi_offset; + /** Offset to SRP subtable */ + sbft_off_t srp_offset; + /** Offset to IB subtable, if present */ + sbft_off_t ib_offset; + /** Reserved */ + uint8_t reserved[6]; +} __attribute__ (( packed )); + +/** + * sBFT SCSI subtable + */ +struct sbft_scsi_subtable { + /** LUN */ + struct scsi_lun lun; +} __attribute__ (( packed )); + +/** + * sBFT SRP subtable + */ +struct sbft_srp_subtable { + /** Initiator and target ports */ + struct srp_port_ids port_ids; +} __attribute__ (( packed )); + +/** + * sBFT IB subtable + */ +struct sbft_ib_subtable { + /** Source GID */ + struct ib_gid sgid; + /** Destination GID */ + struct ib_gid dgid; + /** Service ID */ + struct ib_gid_half service_id; + /** Partition key */ + uint16_t pkey; + /** Reserved */ + uint8_t reserved[6]; +} __attribute__ (( packed )); + +/** + * An sBFT created by gPXE + */ +struct gpxe_sbft { + /** The table header */ + struct sbft_table table; + /** The SCSI subtable */ + struct sbft_scsi_subtable scsi; + /** The SRP subtable */ + struct sbft_srp_subtable srp; + /** The IB subtable */ + struct sbft_ib_subtable ib; +} __attribute__ (( packed, aligned ( 16 ) )); + +struct srp_device; + +extern int sbft_fill_data ( struct srp_device *srp ); + +#endif /* _GPXE_SBFT_H */ diff --git a/gpxe/src/arch/i386/include/gpxe/timer2.h b/gpxe/src/arch/i386/include/gpxe/timer2.h index 59705fa2..8f119515 100644 --- a/gpxe/src/arch/i386/include/gpxe/timer2.h +++ b/gpxe/src/arch/i386/include/gpxe/timer2.h @@ -7,6 +7,8 @@ * */ +FILE_LICENCE ( GPL2_OR_LATER ); + extern void timer2_udelay ( unsigned long usecs ); #endif /* _GPXE_TIMER2_H */ diff --git a/gpxe/src/arch/i386/include/gpxe/x86_io.h b/gpxe/src/arch/i386/include/gpxe/x86_io.h index b1ae3bac..beb5b22a 100644 --- a/gpxe/src/arch/i386/include/gpxe/x86_io.h +++ b/gpxe/src/arch/i386/include/gpxe/x86_io.h @@ -15,6 +15,8 @@ * into a machine with such an old CPU anyway. */ +FILE_LICENCE ( GPL2_OR_LATER ); + #ifdef IOAPI_X86 #define IOAPI_PREFIX_x86 #else |