Age | Commit message (Collapse) | Author |
|
|
|
* i386/i386/fpu.c (init_fpu): Drop FXSR initialization message
|
|
* ddb/db_command.c (_longjmp): Remove prototype.
(vm_map_print): Likewise.
(vm_object_print): Likewise.
(vm_page_print): Likewise.
(vm_map_copy_print): Likewise.
(ipc_port_print): Likewise.
(ipc_pset_print): Likewise.
(db_show_all_slocks): Likewise.
(ipc_kmsg_print): Likewise.
(ipc_msg_print): Likewise.
Include <vm/vm_print.h>.
Include <ipc/ipc_print.h>.
Include <kern/lock.h>.
* i386/i386/setjmp.h [__GNUC__] (_longjmp): Add prototype.
|
|
* ddb/db_trap.c: Include <machine/setjmp.h>.
* i386/i386/setjmp.h (_setjmp): Add prototype.
|
|
* i386/i386at/model_dep.c (init_alloc_aligned): Let allocated area last
until end of memory map.
|
|
* i386/include/mach/i386/multiboot.h (multiboot_mmap): New structure
* i386/i386at/model_dep.c (mem_size_init): Parse boot_info.mmap_addr if
available.
(init_alloc_aligned): Likewise.
|
|
* i386/i386/db_interface.h [! MACH_KBD] (db_set_hw_watchpoint,
db_clear_hw_watchpoint, db_dr): Do not declare functions.
|
|
Make the `watch' command use hw debug registers whenever possible.
* ddb/db_watch.c (db_set_hw_watchpoint, db_clear_hw_watchpoint): Add
functions prototypes.
(db_set_watchpoints): Try to call db_set_hw_watchpoint.
(db_clear_watchpoints): Call db_clear_hw_watchpoint.
* i386/i386/db_interface.c: Include <ddb/db_watch.h>
(db_set_hw_watchpoint): Take a db_watchpoint_t WATCH parameter instead of
its content. Remove support for clearing a debug register.
(db_clear_hw_watchpoint): Add function.
* i386/i386/db_interface.h: Include <ddb/db_watch.h>.
(db_set_hw_watchpoint): Fix function prototype.
(db_clear_hw_watchpoint): Add function prototype.
* i386/i386/db_machdep.h: Do not include <machine/db_interface.h>
|
|
This adds using the x86 hardware debugging registers, either from the kernel
through db_set_hw_watchpoint, or from userland through i386_DEBUG_STATE.
While the kernel is using the registers, the userland values are ignored.
* i386/i386/db_interface.c (kernel_dr, ids): New variables.
(db_load_context, db_get_debug_state, db_set_debug_state, db_dr,
db_set_hw_watchpoint): New functions.
(kdb_trap): Use get_dr* instead of dr_addr[].
* i386/i386/db_interface.h (db_user_to_kernel_address, db_set_hw_watchpoint)
(db_dr, db_get_debug_state, db_set_debug_state, db_load_context): Add functions
prototypes.
(dr0, dr1, dr2, dr3): Remove functions prototypes.
* i386/i386/locore.S (dr6, dr0, dr1, dr2, dr3): Remove functions.
(dr_msk, dr_addr): Remove variables.
* i386/include/mach/i386/thread_status.h (i386_DEBUG_STATE): Add macro.
(i386_debug_state): Add structure.
(i386_DEBUG_STATE_COUNT): Add macro.
* i386/i386/thread.h: Include <mach/machine/thread_status.h>.
(i386_machine_state): Add `struct i386_debug_state ids' field.
* i386/i386/pcb.c: Include <i386/db_interface.h>.
(switch_ktss): Call db_load_context.
(thread_setstatus, thread_getstatus): Add I386_DEBUG_STATE case.
* i386/i386/proc_reg.h (get_dr0, set_dr0, get_dr1, set_dr1, get_dr2,
set_dr2, get_dr3, set_dr3, get_dr6, set_dr6, get_dr7, set_dr7): Add macros.
|
|
* i386/Makefrag.am (AM_CFLAGS): Add -mno-3dnow -mno-mmx -mno-sse -mno-sse2.
|
|
* i386/intel/pmap.c (pmap_map_mfn) [MACH_XEN && !MACH_PV_PAGETABLES]:
Implement.
|
|
* i386/xen/xen_boothdr.S (FEATURES): Mark PVH features as required.
|
|
|
|
* i386/i386/gdt.c (gdt_init) [MACH_PV_DESCRIPTORS && !MACH_PV_PAGETABLES]:
Do not enable VMASST_TYPE_4gb_segments.
* i386/i386/trap.c (user_trap): Do not handle trap 15, 4gb segment
assist notification.
|
|
* i386/i386/vm_param.h [MACH_XEN && !MACH_PV_PAGETABLES]: Do not include
<xen/public/xen.h>.
|
|
* i386/i386/vm_param.h (VM_MAX_KERNEL_ADDRESS) [MACH_XEN &&
!MACH_PV_PAGETABLES]: Remove hypervisor area from VM_MAX_KERNEL_ADDRESS
restriction.
|
|
* i386/i386/idt_inittab.S: Turn MACH_XEN test into MACH_PV_DESCRIPTORS test.
* i386/i386/fpu.c: Turn appropriate MACH_HYP/XEN tests into MACH_RING1 tests.
* i386/i386/ktss.c: Likewise.
* i386/i386/locore.S: Likewise.
* i386/i386/mp_desc.c: Likewise.
* i386/i386/pcb.c: Likewise.
* i386/i386/proc_reg.h: Likewise.
* i386/i386/trap.c: Likewise.
|
|
* xen/configfrag.ac (--disable-pv-pagetables): Add option.
* i386/xen/xen_boothdr.S (XEN_ELFNOTE_FEATURES) [!MACH_PV_PAGETABLES]: Add
writable_page_tables.
* i386/i386/gdt.c: Turn appropriate MACH_XEN/MACH_HYP tests into
MACH_PV_PAGETABLES tests.
* i386/i386/i386asm.sym: Likewise
* i386/i386/ldt.c: Likewise
* i386/i386/locore.S: Likewise
* i386/i386/proc_reg.h: Likewise
* i386/i386/user_ldt.c: Likewise
* i386/i386/vm_param.h: Likewise
* i386/i386/xen.h: Likewise
* i386/i386at/model_dep.c: Likewise
* i386/intel/pmap.h: Likewise
* include/mach/xen.h: Likewise
* xen/console.c: Likewise
* xen/store.c: Likewise
* i386/intel/pmap.c: Likewise. Define pmap_map_mfn as TODO stub.
|
|
|
|
* i386/i386/i386asm.sym (PFN_LIST) [!MACH_PSEUDO_PHYS]: Do not define.
|
|
* xen/configfrag.ac (--disable-ring1): Add option.
* i386/xen/xen_boothdr.S (XEN_ELFNOTE_FEATURES) [!MACH_RING1]: Add
supervisor_mode_kernel.
* i386/i386/seg.h (KERNEL_RING) [!MACH_RING1]: Set macro to 0.
|
|
* xen/configfrag.ac (--disable-pv-descriptors): Add option
* i386/xen/xen_boothdr.S (XEN_ELFNOTE_FEATURES) [!MACH_PV_DESCRIPTORS]: Add
writable_descriptor_tables.
* i386/i386/gdt.c: Turn appropriate MACH_XEN/MACH_HYP tests into
MACH_PV_DESCRIPTORS tests.
* i386/i386/gdt.h: Likewise.
* i386/i386/i386asm.sym: Likewise.
* i386/i386/idt.c: Likewise.
* i386/i386/idt_inittab.S: Likewise.
* i386/i386/ldt.c: Likewise.
* i386/i386/pcb.c: Likewise.
* i386/i386/seg.h: Likewise.
* i386/i386/user_ldt.c: Likewise.
* i386/i386/user_ldt.h: Likewise.
|
|
* i386/intel/pmap.c (pmap_bootstrap): Interate over linear addresses and compute
l3 and l2 offsets from it instead of assuming nul l3 offset.
|
|
This permits better trace support in kdb.
* i386/i386/vm_param.h (VM_MIN_KERNEL_ADDRESS): Set to 0xC0000000
* i386/Makefrag.am (_START): Set to 0xC0100000.
|
|
* i386/i386/vm_param.h (VM_MIN_KERNEL_ADDRESS): Document that it can be
changed, but _START has to be offset too.
(INIT_VM_MIN_KERNEL_ADDRESS): Document that it should remain 0.
|
|
* i386/i386/pcb.c (switch_ktss): Check value returned by hyp_stack_switch.
|
|
* i386/Makefrag.am (_START_MAP): Define symbol to 0x100000.
* i386/xen/Makefrag.am (_START_MAP): Define symbol to 0xC0000000.
* i386/ldscript: Use _START_MAP instead of hardcoding 0x100000.
|
|
Grub is not able to map us at high addresses. We can however make it load us at
low addresses (through the linker script mapping), then use segmentation to move
ourselves to high addresses, and switch to C which uses high addresses
(through _START definition).
* i386/ldscript: Force mapping kernel at 0x100000, regardless of the value
of _START.
* i386/i386at/boothdr.S (boot_entry): Set up initial segments to project the
bootstrap linear space to high addresses.
|
|
* i386/i386at/model_dep.c (i386at_init): Map BIOS memory at 0.
* i386/intel/pmap.c (pmap_create): Do not map BIOS memory in user tasks.
|
|
The former is the initial value set by the bootloader. It may not be the
same as what Mach will set up.
* i386/i386/vm_param.h (INIT_VM_MIN_KERNEL_ADDRESS): New macro.
* i386/i386at/model_dep.c (i386at_init): Use INIT_VM_MIN_KERNEL_ADDRESS
instead of VM_MIN_KERNEL_ADDRESS.
|
|
* i386/i386/vm_param.h [!MACH_XEN]: Do not include <xen/public/xen.h>.
* i386/i386at/model_dep.c (init_alloc_aligned): Use phystokv to compare physical
memory addresses with kernel start, end, and symbol table.
* i386/intel/pmap.c (pmap_enter): Use kvtophys to convert ptp pointer to pte
entry.
* linux/dev/init/main.c (alloc_contig_mem, linux_init): Use phystokv to convert
allocated pages to virtual pointer.
* linux/src/include/asm-i386/io.h: Include <machine/vm_param.h>.
(virt_to_phys): Call _kvtophys.
(phys_to_virt): Call phystokv.
* linux/src/include/linux/compatmac.h: Include <asm/io.h>.
(ioremap): Use phys_to_virt to convert physical address to virtual pointer.
(my_iounmap): Likewise.
* linux/dev/include/asm-i386/page.h: Include <mach/vm_param.h>.
(PAGE_SHIFT, PAGE_SIZE, PAGE_MASK): Remove macros.
* linux/src/drivers/scsi/ncr53c8xx.c (vm_size_t): Remove type.
* linux/dev/glue/net.c: Include <machine/vm_param.h>
(device_write): Call phystokv to convert from physical page address to
virtual pointer.
* linux/dev/glue/block.c (alloc_buffer, free_buffer, rdwr_full): Likewise.
|
|
* i386/intel/pmap.c (pmap_bootstrap): Check against `va' wrap around
0xffffffff.
|
|
When _start is not close to 0, just using init_alloc_aligned() is not enough
to know how much should be duplicated between linear and virtual mappings.
Just mapping everything that can be is not very costly and should just work
when it can work.
* i386/i386at/model_dep.c (i386at_init) [VM_MIN_KERNEL_ADDRESS !=
LINEAR_MIN_KERNEL_ADDRESS]: Extend `nb_direct' to VM_MIN_KERNEL_ADDRESS -
LINEAR_MIN_KERNEL_ADDRESS.
|
|
* i386/i386/i386asm.sym (PFN_LIST): Enclose in #ifdef MACH_XEN. Thanks
to Samuel Thibault for the suggestion.
|
|
* ddb/db_examine.c (db_xcdump): Do not cast addr before passing to
db_read_bytes.
* ddb/db_macro.c (db_arg_variable): Return long.
* ddb/db_macro.h (db_arg_variable): Likewise.
* ddb/db_sym.c (db_maxoff): Set type to unsigned long.
* ddb/db_task_thread.c (db_set_default_thread, db_get_task_thread): Return
long.
* ddb/db_variables.h (db_variable): Make fcn function field to return long.
(FCN_NULL): Make function type return long.
* i386/i386/db_interface.c (int_regs): Set field sizes to long.
* i386/i386/db_machdep.h (db_expr_t): Set type to long.
* i386/i386/db_trace.c (db_i386_reg_value): Return long. Use long types.
(i386_frame, i386_kregs, interrupt_frame, db_nextframe): Set field sizes to
long.
(db_regs, i386_kregs): Use long * pointers.
(db_lookup_i386_kreg): Return long *.
(db_numargs, db_nextframe, db_stack_trace_cmd, db_i386_stack_trace): Use long
types.
* i386/i386/debug_i386.c (dump_ss): Fix format.
* i386/i386/ktss.c (ktss_init): Use long type.
* i386/i386/pcb.c (set_user_regs): Likewise.
* i386/i386/thread.h (i386_saved_state, v86_segs, i386_kernel_state,
i386_interrupt_state): Set field sizes to long.
* i386/i386/trap.c (kernel_trap, user_trap): Fix formats.
* kern/ast.h (ast_t): Set type to long.
* kern/boot_script.c (create_task, resume_task, prompt_resume_task,
boot_script_set_variable): Use long types.
* kern/boot_script.h (boot_script_set_variable): Use long type.
* kern/bootstrap.c (bootstrap_create): Pass long type.
* kern/lock.c (simple_lock, simple_lock_try): Use long type.
* linux/dev/kernel/softirq.c (linux_soft_intr): Fix format.
|
|
* i386/i386/xen.h (xchgl): Use xchg instruction instead of xchgl, so the
assembler can detect unsigned long size.
|
|
* i386/configfrag.ac (i386): Remove definition.
* i386/intel/pmap.c (pmap_update_interrupt): Rename i386 to __i386__.
* i386/intel/pmap.h: Likewise.
* kern/debug.c (Debugger): Likewise.
* kern/lock.c (simple_lock, simple_lock_try, db_show_all_slocks): Likewise.
|
|
* i386/i386at/com.c (comgetstat): Use natural_t instead of `unsigned int'.
(comsetstat): Likewise.
* i386/i386at/kd.c (kdgetstat, kdsetstat): Likewise.
* i386/i386at/lpr.c (lprgetstat, lprsetstat): Likewise.
|
|
* i386/include/mach/i386/exec/elf.h (Elf32_Addr, Elf32_Off, Elf32_Sword,
Elf32_Word): Use int type instead of long.
|
|
* i386/include/mach/i386/vm_param.h (i386_btop, i386_ptob, i386_round_page,
i386_trunc_page): Cast to unsigned long.
|
|
* i386/i386/proc_reg.h (get_eflags, get_esp, get_eflags, get_cr0, get_cr2,
get_cr3, get_cr4): Return unsigned long type.
(set_eflags, set_cr0, set_cr3, set_cr4): Take unsigned long type.
|
|
* i386/i386/i386asm.sym (R_EDI): Define macro.
* i386/i386/locore.S (t_page_fault): Use R_CR2-R_EDI instead of hardcoded
12.
|
|
That makes the virtual addressing equal to linear addressing, thus optimizing
some computations away.
* i386/i386/vm_param.h (VM_MIN_KERNEL_ADDRESS) [MACH_XEN]: Set to
0xC0000000UL.
* i386/xen/Makefrag.am (gnumach_LINKFLAGS): Set _START to 0xC0000000.
* i386/xen/xen_boothdr.S (VIRT_BASE, ELF_PADDR_OFFSET): Set to 0xC0000000.
|
|
* i386/intel/pmap.c (pmap_set_page_readonly_init) [PAE]: Access the bootstrap
dirbase with PTEMASK (1 page) instead of PDEMASK (4 pages) through pmap_pde.
|
|
* i386/i386/spl.S (splx): Use S_ARG0 instead of reimplementing it.
|
|
* i386/ldscript: Reformat to follow binutils version
|
|
* i386/intel/pmap.h (INTEL_PTE_PFN): Keep only 47bits, others are not usable.
|
|
* i386/intel/pmap.h (lin2pdpnum): New macro.
* i386/intel/pmap.c (pmap_set_page_readonly_init): Use lin2pdpnum macro
instead of hardcoding 0.
|
|
* i386/i386at/model_dep.c (i386at_init): Do not copy linear into virtual kernel
mapping when they are equal, and do not drop the former either. Use the
function `i' variable.
|
|
* i386/i386/phys.c (kvtophys): Use pte_to_pa macro instead of reimplementing
it.
|