From: Itsuro O. <od...@us...> - 2006-02-14 05:30:35
|
Update of /cvsroot/mkdump/mkexec/3.0/2.6/include/asm-i386 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12378/3.0/2.6/include/asm-i386 Added Files: minik_dump.h mkexec-x86.h mkexec.h mkexec_import.h x86-linux.h Log Message: register for 3.0: based on 2.1 mkexec-2_0-linux-2_6-2_r --- NEW FILE: mkexec_import.h --- /* * include/asm-i386/mkexec_import.h * * $Id: mkexec_import.h,v 1.1 2006/02/14 05:30:26 odaodab Exp $ * * Portions Copyright (C) 2004-2005 NTT DATA CORPORATION. * Portions Copyright (C) 2004-2005 VA Linux Systems Japan K.K. * * This file is part of Mkdump. * * Mkdump is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation (version 2 of the License). * * Mkdump is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Mkdump; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #define IMPORT_SYMBOL(x) /* dummy */ pte_t *pte_alloc_kernel(struct mm_struct *, pmd_t *, unsigned long); IMPORT_SYMBOL(pte_alloc_kernel); IMPORT_SYMBOL(bust_spinlocks); IMPORT_SYMBOL(e820); IMPORT_SYMBOL(disable_local_APIC); IMPORT_SYMBOL(stop_this_cpu); IMPORT_SYMBOL(disable_IO_APIC); IMPORT_SYMBOL(ioapic_lock); IMPORT_SYMBOL(pgdat_list); IMPORT_SYMBOL(saved_command_line); IMPORT_SYMBOL(crashmem_get); IMPORT_SYMBOL(kallsyms_lookup_name); --- NEW FILE: mkexec.h --- /* * include/asm-i386/mkexec.h * * $Id: mkexec.h,v 1.1 2006/02/14 05:30:26 odaodab Exp $ * * Portions Copyright (C) 2004-2005 NTT DATA CORPORATION. * Portions Copyright (C) 2004-2005 VA Linux Systems Japan K.K. * * This file is part of Mkdump. * * Mkdump is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation (version 2 of the License). * * Mkdump is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Mkdump; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef MKEXEC_H #define MKEXEC_H struct memory_range { unsigned long long start, end; unsigned type; #define RANGE_RAM 0 #define RANGE_RESERVED 1 #define RANGE_ACPI 2 #define RANGE_ACPI_NVS 3 }; extern int pimage_create(struct kimage *image); extern int machine_mkexec_prepare(struct kimage *image); #endif /* MKEXEC_H */ --- NEW FILE: x86-linux.h --- /* * include/asm-i386/x86-linux.h * * $Id: x86-linux.h,v 1.1 2006/02/14 05:30:26 odaodab Exp $ * * Portions Copyright (C) 2004-2005 NTT DATA CORPORATION. * Portions Copyright (C) 2004-2005 VA Linux Systems Japan K.K. * * This file is part of Mkdump. * * Mkdump is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation (version 2 of the License). * * Mkdump is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Mkdump; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef MKEXEC_X86_LINUX_H #define MKEXEC_X86_LINUX_H #define TENATIVE 1 /* Code that is tenatively correct but hasn't yet been officially accepted */ #include <asm/e820.h> #ifndef __ASSEMBLY__ /* FIXME expand on drive_info_)struct... */ struct drive_info_struct { uint8_t dummy[32]; }; struct sys_desc_table { uint16_t length; uint8_t table[318]; }; struct apm_bios_info { uint16_t version; /* 0x40 */ uint16_t cseg; /* 0x42 */ uint32_t offset; /* 0x44 */ uint16_t cseg_16; /* 0x48 */ uint16_t dseg; /* 0x4a */ uint16_t flags; /* 0x4c */ uint16_t cseg_len; /* 0x4e */ uint16_t cseg_16_len; /* 0x50 */ uint16_t dseg_len; /* 0x52 */ uint8_t reserved[44]; /* 0x54 */ }; struct x86_linux_param_header { uint8_t orig_x; /* 0x00 */ uint8_t orig_y; /* 0x01 */ uint16_t ext_mem_k; /* 0x02 -- EXT_MEM_K sits here */ uint16_t orig_video_page; /* 0x04 */ uint8_t orig_video_mode; /* 0x06 */ uint8_t orig_video_cols; /* 0x07 */ uint16_t unused2; /* 0x08 */ uint16_t orig_video_ega_bx; /* 0x0a */ uint16_t unused3; /* 0x0c */ uint8_t orig_video_lines; /* 0x0e */ uint8_t orig_video_isVGA; /* 0x0f */ uint16_t orig_video_points; /* 0x10 */ /* VESA graphic mode -- linear frame buffer */ uint16_t lfb_width; /* 0x12 */ uint16_t lfb_height; /* 0x14 */ uint16_t lfb_depth; /* 0x16 */ uint32_t lfb_base; /* 0x18 */ uint32_t lfb_size; /* 0x1c */ uint16_t cl_magic; /* 0x20 */ #define CL_MAGIC_VALUE 0xA33F uint16_t cl_offset; /* 0x22 */ uint16_t lfb_linelength; /* 0x24 */ uint8_t red_size; /* 0x26 */ uint8_t red_pos; /* 0x27 */ uint8_t green_size; /* 0x28 */ uint8_t green_pos; /* 0x29 */ uint8_t blue_size; /* 0x2a */ uint8_t blue_pos; /* 0x2b */ uint8_t rsvd_size; /* 0x2c */ uint8_t rsvd_pos; /* 0x2d */ uint16_t vesapm_seg; /* 0x2e */ uint16_t vesapm_off; /* 0x30 */ uint16_t pages; /* 0x32 */ uint8_t reserved4[12]; /* 0x34 -- 0x3f reserved for future expansion */ struct apm_bios_info apm_bios_info; /* 0x40 */ struct drive_info_struct drive_info; /* 0x80 */ struct sys_desc_table sys_desc_table; /* 0xa0 */ uint32_t alt_mem_k; /* 0x1e0 */ uint8_t reserved5[4]; /* 0x1e4 */ uint8_t e820_map_nr; /* 0x1e8 */ uint8_t reserved6[8]; /* 0x1e9 */ uint8_t setup_sects; /* 0x1f1 */ uint16_t mount_root_rdonly; /* 0x1f2 */ uint16_t syssize; /* 0x1f4 */ uint16_t swapdev; /* 0x1f6 */ uint16_t ramdisk_flags; /* 0x1f8 */ #define RAMDISK_IMAGE_START_MASK 0x07FF #define RAMDISK_PROMPT_FLAG 0x8000 #define RAMDISK_LOAD_FLAG 0x4000 uint16_t vid_mode; /* 0x1fa */ uint16_t root_dev; /* 0x1fc */ uint8_t reserved9[1]; /* 0x1fe */ uint8_t aux_device_info; /* 0x1ff */ /* 2.00+ */ uint8_t reserved10[2]; /* 0x200 */ uint8_t header_magic[4]; /* 0x202 */ uint16_t protocol_version; /* 0x206 */ uint16_t rmode_switch_ip; /* 0x208 */ uint16_t rmode_switch_cs; /* 0x20a */ uint8_t reserved11[4]; /* 0x20c */ uint8_t loader_type; /* 0x210 */ #define LOADER_TYPE_LOADLIN 1 #define LOADER_TYPE_BOOTSECT_LOADER 2 #define LOADER_TYPE_SYSLINUX 3 #define LOADER_TYPE_ETHERBOOT 4 #define LOADER_TYPE_UNKNOWN 0xFF uint8_t loader_flags; /* 0x211 */ uint8_t reserved12[2]; /* 0x212 */ uint32_t kernel_start; /* 0x214 */ uint32_t initrd_start; /* 0x218 */ uint32_t initrd_size; /* 0x21c */ uint8_t reserved13[4]; /* 0x220 */ /* 2.01+ */ uint16_t heap_end_ptr; /* 0x224 */ uint8_t reserved14[2]; /* 0x226 */ /* 2.02+ */ uint32_t cmd_line_ptr; /* 0x228 */ /* 2.03+ */ uint32_t initrd_addr_max; /* 0x22c */ #if TENATIVE /* 2.04+ */ uint16_t entry32_off; /* 0x230 */ uint16_t internal_cmdline_off; /* 0x232 */ uint32_t low_base; /* 0x234 */ uint32_t low_memsz; /* 0x238 */ uint32_t low_filesz; /* 0x23c */ uint32_t real_base; /* 0x240 */ uint32_t real_memsz; /* 0x244 */ uint32_t real_filesz; /* 0x248 */ uint32_t high_base; /* 0x24C */ uint32_t high_memsz; /* 0x250 */ uint32_t high_filesz; /* 0x254 */ uint8_t reserved15[0x2d0 - 0x258]; /* 0x258 */ #else uint8_t reserved15[0x2d0 - 0x230]; /* 0x230 */ #endif struct e820entry e820_map[E820MAX]; /* 0x2d0 */ /* 0x550 */ #define COMMAND_LINE_SIZE 256 }; struct x86_linux_header { uint8_t reserved1[0x1f1]; /* 0x000 */ uint8_t setup_sects; /* 0x1f1 */ uint16_t root_flags; /* 0x1f2 */ uint16_t syssize; /* 0x1f4 */ uint16_t swapdev; /* 0x1f6 */ uint16_t ramdisk_flags; /* 0x1f6 */ uint16_t vid_mode; /* 0x1fa */ uint16_t root_dev; /* 0x1fc */ uint16_t boot_sector_magic; /* 0x1fe */ /* 2.00+ */ uint8_t reserved3[2]; /* 0x200 */ uint8_t header_magic[4]; /* 0x202 */ uint16_t protocol_version; /* 0x206 */ uint32_t realmode_swtch; /* 0x208 */ uint16_t start_sys; /* 0x20c */ uint16_t kver_addr; /* 0x20e */ uint8_t type_of_loader; /* 0x210 */ uint8_t loadflags; /* 0x211 */ uint16_t setup_move_size; /* 0x212 */ uint32_t code32_start; /* 0x214 */ uint32_t ramdisk_image; /* 0x218 */ uint32_t ramdisk_size; /* 0x21c */ uint8_t reserved4[4]; /* 0x220 */ /* 2.01+ */ uint16_t heap_end_ptr; /* 0x224 */ uint8_t reserved5[2]; /* 0x226 */ /* 2.02+ */ uint32_t cmd_line_ptr; /* 0x228 */ /* 2.03+ */ uint32_t initrd_addr_max; /* 0x22c */ #if TENATIVE /* 2.04+ */ uint16_t entry32_off; /* 0x230 */ uint16_t internal_cmdline_off; /* 0x232 */ uint32_t low_base; /* 0x234 */ uint32_t low_memsz; /* 0x238 */ uint32_t low_filesz; /* 0x23c */ uint32_t real_base; /* 0x240 */ uint32_t real_memsz; /* 0x244 */ uint32_t real_filesz; /* 0x248 */ uint32_t high_base; /* 0x24C */ uint32_t high_memsz; /* 0x250 */ uint32_t high_filesz; /* 0x254 */ uint32_t tail[32*1024 - 0x258]; /* 0x258 */ #else uint8_t tail[32*1024 - 0x230]; /* 0x230 */ #endif } __attribute__ ((packed)); #endif /* ASSEMBLY */ #endif /* MKEXEC_X86_LINUX_H */ --- NEW FILE: mkexec-x86.h --- /* * include/asm-i386/mkexec-x86.h * * $Id: mkexec-x86.h,v 1.1 2006/02/14 05:30:26 odaodab Exp $ * * Portions Copyright (C) 2004-2005 NTT DATA CORPORATION. * Portions Copyright (C) 2004-2005 VA Linux Systems Japan K.K. * * This file is part of Mkdump. * * Mkdump is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation (version 2 of the License). * * Mkdump is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Mkdump; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef MKEXEC_X86_H #define MKEXEC_X86_H extern unsigned char setup32_start[]; extern uint32_t setup32_size; extern struct { uint32_t eax; uint32_t ebx; uint32_t ecx; uint32_t edx; uint32_t esi; uint32_t edi; uint32_t esp; uint32_t ebp; uint32_t eip; } setup32_regs; #endif /* MKEXEC_X86_H */ --- NEW FILE: minik_dump.h --- /* * include/asm-i386/minik_dump.h * * $Id: minik_dump.h,v 1.1 2006/02/14 05:30:26 odaodab Exp $ * * Portions Copyright (C) 2004-2005 NTT DATA CORPORATION. * Portions Copyright (C) 2004-2005 VA Linux Systems Japan K.K. * * This file is part of Mkdump. * * Mkdump is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation (version 2 of the License). * * Mkdump is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Mkdump; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ #ifndef MINIK_DUMP_H #define MINIK_DUMP_H #include <linux/utsname.h> #define DUMP_NR_CPUS 32 /* 'vmlinux.bin' validity identification. */ #define MINIK_SIGNATURE_OFFSET 4 #define MINIK_SIGNATURE_HEAD "minik001" /* * dump header for i386 */ #define DUMP_PANIC_LEN 128 struct dump_header_i386 { struct dump_version dh_version; /* common info */ u32 dh_dump_cpu; /* cpu id which dump run */ u32 dh_tasks[DUMP_NR_CPUS]; /* current on each cpu */ struct pt_regs dh_regs[DUMP_NR_CPUS]; /* context on each cpu */ char dh_panic_string[DUMP_PANIC_LEN]; struct timespec dh_time; struct new_utsname dh_utsname; }; #ifdef __KERNEL__ #define dump_header dump_header_i386 #endif #endif /* MINIK_DUMP_H */ |