Age | Commit message (Collapse) | Author |
|
CGA and MONO cards are more than hard to find nowadays, and some buggy BIOSes
claim running them nowadays...
* i386/i386at/kd.c (kd_xga_init): Do not handle CGA and MONO cases any
more, which thus default to EGA/VGA.
|
|
* i386/i386at/kd.c (kd_xga_init): Use CM_EGA_VGA behavior as default
case for unknown values of CMOS data.
|
|
Previously, bootstrap_create would print the multiboot modules with
padding applied to the end of the line. As multiboot modules as used
by the Hurd span more than one line. This makes the list of modules
hard to read and it looks unclean, more like an accident.
Furthermore, it is not clear what the intend of this was, as the
padding is applied at the end of the line, with no further information
printed thereafter.
* kern/bootstrap.c (bootstrap_create): Remove variable maxlen and len,
update printfs.
|
|
Make the intran, outtran and destructor functions mutable using
preprocessor macros. Make it possible to inject imports using the
MEMORY_OBJECT_IMPORTS macro. This way, userspace servers can provide
their own translation functions.
* include/mach/mach_types.defs (memory_object_t): Make the translation
mutable using preprocessor macros.
* include/mach/memory_object.defs: Likewise for the inlined type declarations.
Honor MEMORY_OBJECT_IMPORTS.
* include/mach/memory_object_default.defs: Likewise.
|
|
|
|
We were filling much more than the mapwindows array, thus overwriting in
at least debugger variables.
* i386/intel/pmap.c (pmap_bootstrap): Make sure to limit mapwindows
initialization within PMAP_NMAPWINDOWS.
|
|
Previously, the error KERN_RESOURCE_SHORTAGE was not properly
propagated.
Found using the Clang Static Analyzer.
* xen/block.c (device_open): Fix error handling, remove unused label.
* xen/net.c (device_open): Likewise.
|
|
* xen/console.c (hypputc): Make `complain' variable static.
|
|
by reducing possible number of partitions to 32.
* linux/dev/drivers/block/ahci.c (MAX_PORTS): Set to 8.
(PARTN_BITS): Set to 5.
|
|
|
|
PCI devices expose their memory etc. way beyond last_phys_addr. Userland
drivers opening /dev/mem need to open those too, even if phystokv() will
not work for them.
* i386/intel/pmap.h (pmap_mapwindow_t): New type.
(pmap_get_mapwindow, pmap_put_mapwindow): New prototypes.
(PMAP_NMAPWINDOWS): New macro.
* i386/intel/pmap.c (mapwindows): New array.
(pmap_get_mapwindow, pmap_put_mapwindow): New functions.
(pmap_bootstrap, pmap_virtual_space): Reserve virtual pages for the mapping
windows.
* i386/i386/phys.c: Include <i386/model_dep.h>
(INTEL_PTE_W, INTEL_PTE_R): New macros
(pmap_zero_page, pmap_copy_page, copy_to_phys, copy_from_phys): Use
`pmap_get_mapwindow' to temporarily map physical pages beyond last_phys_addr.
|
|
Previously, the function mig_strncpy would always zero-terminate the
destination string. Make mig_strncpy behave like mig_strncpy and
strncpy in the glibc. Also fix the implementation of mig_strncpy to
return the length of the written string to align the implementation
with the declaration in include/mach/mig_support.h.
* kern/ipc_mig.c (mig_strncpy): Do not zero-terminate the destination
string. Return length of destination string.
|
|
|
|
* linux/dev/drivers/block/ahci.c (struct port): Add id and is_cd fields.
(ahci_end_request): Only print error if quiet flag of the request is not
set.
(ahci_do_port_request): Upgrade sector parameter to 64 bit. Include
those bits in the LBA48 request.
(ahci_do_request): Upgrade sector count to 64bit. Only print errors if
quiet flag of the request is not set.
(ahci_probe_port): Move identify code...
(ahci_identify): ... to new function. Handle WIN_PIDENTIFY case to
recognize ATAPI devices.
(ahci_probe_port): Also try WIN_PIDENTIFY command.
(ahci_geninit): Avoid checking partition table on empty devices.
|
|
* include/mach/mach_port.defs: Skip the routines mach_port_set_rpcinfo
and mach_port_create_act if MIGRATING_THREADS is not defined.
|
|
* kern/slab.c (KMEM_MAP_SIZE): Decrease from 128MiB to 96MiB.
|
|
* linux/src/drivers/block/ide-cd.c (ide_cdrom_open): Return -ENXIO when
CD sense failed.
|
|
* linux/src/drivers/block/ide-cd.c (cdrom_queue_packet_command): Add `quiet'
parameter, copied into the request.
(cdrom_decode_status): Do not print I/O error when `quiet' field of
request is non-zero.
(cdrom_end_request): Do not print sense results when `quiet' field of
request is non-zero.
(cdrom_check_status, cdrom_read_capacity, cdrom_read_tocentry): Pass 1 to
`cdrom_queue_packet_command''s `quiet' parameter.
(cdrom_lockdoor, cdrom_eject, cdrom_pause, cdrom_startstop,
cdrom_read_subchannel, cdrom_mode_sense, cdrom_mode_select,
cdrom_play_lba_range_1, cdrom_read_block, cdrom_load_unload,
ide_cdrom_ioctl): Pass 0 to `cdrom_queue_packet_command''s `quiet' parameter.
|
|
* linux/src/drivers/block/ide.c (ide_init_drive_cmd): Initialize `quiet'
field of request to 0;
|
|
|
|
This avoids grub & such making Mach print flurries of floppy errors.
* linux/dev/include/linux/blkdev.h (request): Add `quiet' field.
* linux/dev/include/linux/blk.h (end_request): Print I/O error only if
the `quiet' field of the request is 0.
* linux/dev/include/linux/fs.h (ll_rw_block): Add `quiet' parameter.
* linux/dev/glue/block.c (ll_rw_block): Add `quiet' parameter, copied into
the request.
(bread, rdwr_partial, rdwr_full): Pass 0 to `ll_rw_block''s `quiet' parameter.
* linux/dev/drivers/block/floppy.c (floppy_revalidate): Pass 1 to
`ll_rw_block''s `quiet' parameter.
|
|
In addition to physical pages, the slab allocator also consumes kernel
virtual memory, so reclaim pages on failure to allocate from a kernel map.
This method isn't foolproof but helps alleviate fragmentation.
* vm/vm_kern.c (kmem_alloc): Call slab_collect and retry allocation
once on failure.
(kmem_realloc): Likewise.
(kmem_alloc_wired): Likewise.
(kmem_alloc_wired): Likewise.
(kmem_alloc_aligned): Likewise.
|
|
* device/net_io.c (net_rcv_port_t, net_hash_entry_t, net_hash_header_t):
Remove duplicate typedefs.
|
|
* doc/mach.texi (Task Information): Document the new task_set_name
procedure.
|
|
task_set_name sets the name of a task. This is a debugging aid. The
name will be used in error messages printed by the kernel.
* include/mach/gnumach.defs (task_set_name): New procedure.
|
|
task_set_name sets the name of a task. This is a debugging aid. The
name will be used in error messages printed by the kernel.
* kern/task.c (task_set_name): New function.
* kern/task.h (task_set_name): New declaration.
|
|
Found by Coverity
* i386/i386at/com.c (comstart): Make `nch' an int. When `getc' returns
-1, just return.
|
|
Found by Coverity
* i386/i386/user_ldt.c (i386_get_ldt): Fetch `pcb' field of `thread'
only after looking for `thread' being NULL.
|
|
* vm/vm_kern.c (projected_buffer_deallocate): Look for `map' being NULL
or kernel_map before locking it.
|
|
Found by Coverity
* i386/i386/db_trace.c (db_find_kthread): Handle case when task is NULL.
|
|
Found by Coverity.
* i386/i386at/com.c (comopen): On com_reprobe() returning success, check
for `isai' again.
|
|
Previously, only strlen(device_name) bytes were allocated, missing one
byte for the terminating zero.
* xen/block.c (hyp_block_init): Fix buffer size.
|
|
Use strncpy instead of strcpy to copy the name of a symbol into the
symtab structure. Make sure that the string is properly terminated.
Found using Coverity.
* ddb/db_sym.c (db_add_symbol_table): Use strncpy instead of strcpy,
ensure string termination.
|
|
The slab allocator relies on the fact that kmem_cache_error does not
return. Previously, kmem_error was using printf. Use panic instead.
Found using the Clang Static Analyzer.
* kern/slab.c (kmem_error): Use panic instead of printf.
|
|
* kern/slab.c (kmem_cache_error): Use kmem_warn instead of kmem_error
to print the cache name and its address.
|
|
* i386/i386/fpu.c (fpu_set_state, fpu_get_state): Fix size of
`user_fp_regs' access.
|
|
* i386/i386at/kd.c (kdintr, kd_senddata, kd_sendcmd, kd_getgata,
kd_cmdreg_read, kd_cmdreg_write, kd_mouse_drain): Move semi colon of
empty while loops on a single line to make it more visible.
|
|
Found by coverity.
* i386/i386/fpu.c (fpu_set_state, fpu_get_state): Fix out of bound
`user_fp_regs' access.
|
|
* i386/i386at/kd_mouse.c (mouseopen): Fix typo.
|
|
|
|
Found by Coverity
* i386/i386at/kd_mouse.c (mouseopen): Add missing break.
|
|
* include/mach/debug.defs: New file.
* include/mach/debug.h: Likewise.
|
|
* ipc/mach_port.c (mach_port_destroy): Use the name of the task for
error messages.
(mach_port_deallocate): Likewise.
|
|
* kern/task.c (task_create): Initialize name with the address of the task.
* kern/task.h (TASK_NAME_SIZE): New definition.
(struct task): Add field name.
|
|
* kern/printf.c (snprintf): New function.
* kern/printf.h (snprintf): New declaration.
|
|
GNU MIG recently gained support for emitting x_server_routine
declarations in the generated server header file. Using this
declaration, the x_server_routine functions can be inlined into the
ipc_kobject_server function.
* kern/ipc_kobject.c: Include the mig-generated server headers.
|
|
It is not clear to me why the declaration was put there in the first
place. It is not used anywhere, and it conflicts with the declaration
generated by mig.
* vm/memory_object_proxy.h (memory_object_create_proxy): Remove declaration.
|
|
* kern/slab.h (struct kmem_cache): Align kmem_cache objects using
__cacheline_aligned.
|
|
* include/cache.h (__cacheline_aligned): This macro can be used to
align statically allocated objects so that they start at a cache line.
|
|
* kern/slab.h (struct kmem_cache): Reorder the fields so that all hot
fields are within the first cache line.
|