ia64/xen-unstable

view xen/include/xen/multiboot.h @ 19800:78962f85c562

IOMMU: Add two generic functions to vendor neutral interface

Add 2 generic functions into the vendor neutral iommu interface, The
reason is that from changeset 19732, there is only one global flag
"iommu_enabled" that controls iommu enablement for both vtd and amd
systems, so we need different code paths for vtd and amd iommu systems
if this flag has been turned on. Also, the early checking of
"iommu_enabled" in iommu_setup() is removed to prevent iommu
functionalities from been disabled on amd systems.

Signed-off-by: Wei Wang <wei.wang2@amd.com>
author Keir Fraser <keir.fraser@citrix.com>
date Fri Jun 19 08:41:50 2009 +0100 (2009-06-19)
parents 1c15f97a220d
children
line source
1 /* multiboot.h - the header for Multiboot */
2 /* Copyright (C) 1999, 2001 Free Software Foundation, Inc.
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
18 #ifndef __MULTIBOOT_H__
19 #define __MULTIBOOT_H__
22 /*
23 * Multiboot header structure.
24 */
25 #define MULTIBOOT_HEADER_MAGIC 0x1BADB002
26 #define MULTIBOOT_HEADER_MODS_ALIGNED 0x00000001
27 #define MULTIBOOT_HEADER_WANT_MEMORY 0x00000002
28 #define MULTIBOOT_HEADER_HAS_VBE 0x00000004
29 #define MULTIBOOT_HEADER_HAS_ADDR 0x00010000
31 /* The magic number passed by a Multiboot-compliant boot loader. */
32 #define MULTIBOOT_BOOTLOADER_MAGIC 0x2BADB002
34 #define MBI_MEMLIMITS (1<<0)
35 #define MBI_DRIVES (1<<1)
36 #define MBI_CMDLINE (1<<2)
37 #define MBI_MODULES (1<<3)
38 #define MBI_AOUT_SYMS (1<<4)
39 #define MBI_ELF_SYMS (1<<5)
40 #define MBI_MEMMAP (1<<6)
41 #define MBI_LOADERNAME (1<<9)
43 #ifndef __ASSEMBLY__
45 /* The symbol table for a.out. */
46 typedef struct {
47 u32 tabsize;
48 u32 strsize;
49 u32 addr;
50 u32 reserved;
51 } aout_symbol_table_t;
53 /* The section header table for ELF. */
54 typedef struct {
55 u32 num;
56 u32 size;
57 u32 addr;
58 u32 shndx;
59 } elf_section_header_table_t;
61 /* The Multiboot information. */
62 typedef struct {
63 u32 flags;
65 /* Valid if flags sets MBI_MEMLIMITS */
66 u32 mem_lower;
67 u32 mem_upper;
69 /* Valid if flags sets MBI_DRIVES */
70 u32 boot_device;
72 /* Valid if flags sets MBI_CMDLINE */
73 u32 cmdline;
75 /* Valid if flags sets MBI_MODULES */
76 u32 mods_count;
77 u32 mods_addr;
79 /* Valid if flags sets ... */
80 union {
81 aout_symbol_table_t aout_sym; /* ... MBI_AOUT_SYMS */
82 elf_section_header_table_t elf_sec; /* ... MBI_ELF_SYMS */
83 } u;
85 /* Valid if flags sets MBI_MEMMAP */
86 u32 mmap_length;
87 u32 mmap_addr;
88 } multiboot_info_t;
90 /* The module structure. */
91 typedef struct {
92 u32 mod_start;
93 u32 mod_end;
94 u32 string;
95 u32 reserved;
96 } module_t;
98 /* The memory map. Be careful that the offset 0 is base_addr_low
99 but no size. */
100 typedef struct {
101 u32 size;
102 u32 base_addr_low;
103 u32 base_addr_high;
104 u32 length_low;
105 u32 length_high;
106 u32 type;
107 } memory_map_t;
110 #endif /* __ASSEMBLY__ */
112 #endif /* __MULTIBOOT_H__ */