Fork me on GitHub

root/Changes

/* [previous][next][first][last][top][bottom][index][help] */
1.4.0 - 15-Nov-2022
===================
- Added support for the PCI local bus.
- Added support for the UNIX System V IPC mechanisms (semaphores, message queues
  and shared memory).
- Added the character device /dev/full.
- Added the character device /dev/port.
- Added the system call sys_getcwd. [#4]
- Added the configuration option CONFIG_QEMU_DEBUGCON to include support for the
  QEMU Bochs-style debug console.
- Improved the serial driver to support QEMU PCI serial devices.
- Removed the extra lock when dispatching the bottom halves.
- Mask the interrupt during the execution of the interrupt handler.
- Reorganized the code to separate interrupt related functions from specific pic
  functions.
- Moved set_leds() into the bottom half of the keyboard interrupt.
- Moved the start and stop tty functions into the bottom half of the keyboard
  interrupt.
- Removed the command to detect the interface type of the keyboard.
- Removed the kernel parameter 'noramdisk', so from now on the RAM disk driver
  is disabled by default. Use the kernel parameter 'ramdisksize=' to configure
  and enable it.
- Reversed the check order of schedule and signals before leaving the kernel
  space.
- Improved the cooperation with reclaim_buffers() when kernel runs out of memory
  pages.
- Added the functions inport_l() and outport_l() in core386.S.
- Added the sleeping address value in the SysRq process listing.
- Added the configuration option CONFIG_SYSCALL_6TH_ARG (disabled by default),
  to enable the 6th argument in the system calls.
- Added the configuration option CONFIG_LAZY_USER_ADDR_CHECK to relax the number
  of checks in the linear address of a system call parameter.
- Reorganized the signal functions to avoid that signals sent by the kernel have
  to use the same checking mechanism as if they were sent by a user process.
  This also fixes a permission problem when sending the SIGCHLD signal to a
  parent process owned by a different user, during the context of sys_exit().
- IDE driver now shows the PIO mode instead of UDMA mode, since the later is not
  supported yet.
- IDE driver now will use the current logical values if they are valid in the
  identify field.
- Changed the bios memory map functions to show that the ending address is
  inside each range.
- Changed sys_execve() to use the first argument instead of argv[0].
- Reverted 75bb49d and 4ecf9dd, as the PC emulator 'copy.sh/v86' (maybe others)
  requires to select the drive on every command.
- Fixed the slowness during the system boot-up caused by the keyboard driver not
  using interrupts during its own initialization.
- Fixed ext2_truncate() to return the error code after calling free_dblock().
- Fixed v1_minix_truncate() and v2_minix_truncate() to return the error code
  after calling free_zone().
- Fixed ext2_truncate() to correctly free doubly-indirect blocks.
- Fixed v1_minix_truncate() and v2_minix_truncate() to correctly free
  doubly-indirect blocks.
- Fixed ext2_truncate() to free triply-indirect blocks.
- Fixed v2_minix_truncate() to free triply-indirect blocks.
- Fixed the way how the I/O permission bitmap in TSS is implemented.
- Fixed the implementation of the sys_ioperm() system call.
- Fixed the execution permission logic that let root user execute any file.
- Fixed to handle SysRq key inside keyboard interrupt instead of in its bottom
  half.
- Fixed a missing inode release in elf_load() when argument list exceeds ARG_MAX
  on an ELF binary that requires an interpreter.
- Fixed a possible NULL pointer dereference with elf32_ph in elf_load() and
  elf_load_interpreter().
- Fixed the type of the user file descriptor (to unsigned int) in a number of
  system calls.
- Fixed a possible index out of bounds in bios_map_add().
- Fixed a missing validation in the arguments of sys_execve().
- Fixed an inefficiency in the mechanism of ext2_dir_readdir() and
  minix_dir_readdir().
- Fixed the function get_last_boot_addr() to return a proper address even when
  there are no ELF header tables. This mostly happens when the kernel is loaded
  using the QEMU argument '-kernel'.
- Fixed a possible out of bounds access in CHECK_UFD() macro.
- Fixed a possible out of bounds in utsname structures.
- Fixed UTS_MACHINE to return always 'i386' in all processor types on the i386
  architecture.
- Fixed do_printk() to show correctly the value of the second identifier when
  there are two consecutive identifiers
- Fixed to show the size of an ATA drive in KB if it's less than 1MB.
- Fixed to use the standard algorithm to convert LBA to CHS in the ATA driver.
- Fixed the TCSETSW, TCSETSF, TCSETAW and TCSETAF ioctl functions, so now they
  wait output buffer to drain before apply the new settings.
- Fixed a missing update of the termios structure during the ioctl functions:
  TCSETA, TCSETAW and TCSETAF
- Fixed sys_open() to check directory permissions only if the file does not
  exist and O_CREAT has been specified.
- Fixed callouts bottom half to avoid nesting.
- Small fixes and cosmetic changes.
- Cleaned up a lot of code.


1.3.0 - 08-Dec-2021
===================
- Added support for interrupt nesting.
- Added framebuffer device support for VESA VBE 2.0+ compliant graphics cards.
- Added support for the framebuffer console (fbcon).
- Completely rewrite the console to support VGA text and framebuffer screens.
- Improved the speed of VGA text consoles by using double-buffering and fixing
  also a fair number of bugs.
- Updated the header file to support the latest GRUB Multiboot Specification v1.
- Moved 'cpu_idle()' to a C function to include more easily some tasks to do.
- Isolated the multiboot code in order to prepare the kernel to support multiple
  bootloader protocols.
- Arrange boot.S to be compatible only with GRUB Multiboot Specification v1.
- Changed from 0x90000 to 0x50000 the memory location of the 4MB temporary Page
  Directory to be able to hold bigger initrd images.
- Changed from 5% to 1% the amount of memory that will use the inode table.
- Added the ability to insert extra regions to the memory map provided by the
  boot loader.
- Added support to detect non-contiguous areas of available memory in the BIOS
  memory map.
- Added support for the 'magic SysRq key' to help to know the cause of a kernel
  freeze on a disaster situation.
- Added some basic checks on data received during IDE identify to make sure it
  makes sense.
- Added support to handle two ATA/ATAPI devices in the same IDE controller.
- Reduced the size of the buffer area used in floppy I/O operations.
- Increased to 50 the maximum of BIOS memory map entries.
- Removed CLI() functions in ide_hd and ide_cd.
- Improved the handling of the inode free list and the locking mechanism.
- Improved the handling of buffer and memory page free lists.
- Improved the way how is counted the first megabyte of memory.
- Changed bread_page() to reuse buffers and reduce disk I/O activity.
- Honour POSIX.1-2008 by returning ELOOP if flag O_NOFOLLOW is set and the
  trailing component (basename) of the pathname in open() is a symbolic link.
- Disabled interrupts during the context switch.
- Moved the values buffer->valid, buffer->locked and buffer->dirty to flags.
- Moved the value pg->locked to a flag.
- Changed kernel_process() to accept also the name of the process.
- Removed a sizeof(void) in sys_signal() as it is not covered by the C standard.
- Disabled interrupts during early boot up.
- Added the configure option CONFIG_VERBOSE_SEGFAULTS (disabled by default).
- Added a separate queue for all running processes.
- Disabled default screen blanking.
- Added a new linked list in the buffer structure to better handle the dirty
  buffers.
- Added the 'Dirty' line in '/proc/meminfo' to keep track the amount of memory
  waiting to be written back to the disk.
- Wakeup the INIT process (if it's sleeping on sys_wait4()) if one of the new
  processes inherited during the sys_exit() call is a zombie.
- Saved some CPU cycles in irq_handler() by isolating unused IRQs.
- Fixed the RAMdisk driver to not access blocks beyond its size.
- Fixed a race condition in floppy drive when the interrupt occurred right
  before going to sleep.
- Fixed a bug during the RAMdisk memory initialization that reserved twice the
  size of the initrd image.
- Fixed to return EISDIR when trying to read a directory in procfs.
- Fixed a memory corruption bug in procfs_readlink() that was leading to
  instability in user programs that read the procfs.
- Fixed to use a simple assignment in elf_create_stack() instead of using a
  function to copy a numeric value.
- Fixed a long standing memory corruption bug when returning the contents of the
  '/proc/<PID>/cmdline' file.
- Fixed a possible memory corruption bug when returning the contents of the
  '/proc/<PID>/environ' file.
- Fixed a missing queue handling in the serial driver.
- Fixed to remove the calls to reset termios and tty on tty_close().
- Fixed an extra buffer_head assignment in get_free_buffer() which reduced to
  50% the buffer space, and could also potentially use an already locked buffer.
- Fixed a very long standing buffer corruption bug, in rename functions of ext2
  and minix filesystems, that led to crashes with the message 'getblk(): no more
  buffers on free list!' after a heavy filesystem use.
- Fixed the tty_queue_room() function and aligned to 8 the number of cblocks per
  queue.
- Fixed the way how release_page() and reclaim_buffers() cooperate when there
  are no more free memory pages, in order to avoid killing the current process
  prematurely.
- Fixed to avoid sleeping during console_flush_log_buf().
- Fixed to return ENOSPC when trying to write beyond the size of a block device.
- Fixed get_proc_by_pid() to not PANIC anymore if the process didn't exist.
- Fixed to avoid multiple calls to tty_queue_init().
- Fixed to return ENXIO when the device does not exist.
- Fixed the CSI J Erase in Display (ED) and other sequences in console.
- Fixed /dev/kmem to not access beyond the end of the virtual memory.
- Fixed to make sure that disk partitions with status value other than 0x00 and
  0x80 are invalid.
- Fixed a race condition in ATA identify/read when the interrupt occurred right
  before going to sleep.
- Fixed a buffer overrun in iso9660_dir_readdir().
- Fixed a bug in iso9660_dir_readdir() that prevented from including some files
  in the user dirent structure under certain conditions.
- Fixed a very long standing bug in the memory page hashing mechanism that led
  to kernel freezes after a long use.
- Fixed a very long standing bug in all inode lookup functions that ate an extra
  inode on every call, leading to the premature message "WARNING: no more inodes
  on free list!".
- Fixed certain values to be signed instead of unsigned in kstat structure.
- Fixed a bug in tty->canon_data that corrects a bad behavior in select().
- Fixed to decrease rss memory from the zombie process instead from its parent
  in remove_zombie().
- Fixed to name correctly the IDLE process by assigning 'idle' to argv0.
- Fixed to honour the select() function when handling pipes.
- Fixed to reduce over-scheduling in tty_write() by calling do_sched() only if
  needed.
- Fixed a long standing bug in do_exit() that made some processes returning from
  the death.
- Fixed the inode reference counter when moving directories (sys_rename) in ext2
  and minix filesystems.
- Fixed to update the parent directory when moving directories (sys_rename) in
  ext2 and minix filesystems.
- Fixed to wake up all processes in select() after a console_write().
- Fixed an incomplete copy of in-memory superblock data during a remount from RO
  to RW, in ext2 and minix filesystems, that led to not save all changes in
  superblock.
- Fixed to decrease the number of children either when the process is exiting,
  and from the correct parent after reaping a zombie process.
- Fixed a long standing bug, in ext2_dir_readdir() and minix_dir_readdir(), that
  prevented from listening directory entries if there were blank blocks in the
  middle.
- Small fixes and cosmetic changes.
- Cleaned up a lot of code.


1.2.0 - 12-Dec-2020
===================
- Added support for serial (RS-232) devices.
- Completely rewritten the way how the device table is handled.
- Completely rewritten the way how the interrupt table is handled.
- Added the ability to share the same IRQ between multiple devices.
- Completely rewritten the way how bottom halves are managed.
- Added the 'doc/devices.txt' document.
- Added basic functionality of OPOST functions to tty.
- Added to reschedule the keyboard bottom-half if it was busy.
- Added support of O_NONBLOCK in tty_write().
- Added remote serial console support.
- Added support for K_RAW and K_MEDIUMRAW keyboard modes.
- Added and fixed some ECMA-48 CSI sequences in console.
- Improved termios and other aspects of the tty driver to accomodate the new
  serial driver.
- Small optimizations and bug fixes in console.
- Improved the macros that build the interrupt service routines.
- Fixed to force some signals that a process cannot ignore by changing their
  dispositions to SIG_DFL.
- Fixed a bug in tty_read and tty_write that caused to send the SIGTTIN signal
  to the foreground process.
- Fixed nanosleep() to force to 10ms any request lower than 10ms.
- Fixed a signedness bug in setreuid() and setregid().
- Fixed to delimitate better the stack-related page faults in the vma region.
- Fixed a NULL pointer dereference when __DEBUG__ is enabled in sys_waitpid().
- Fixed to avoid freeing an invalid page that generated PANICs in SVGAlib
  programs.
- Fixed a bug that, under certain conditions, page_not_present() unmapped a
  wrong page number.
- Fixed to not clone MAP_SHARED pages during fork().
- Saved twice the 'signum' value before calling the signal handler.
- Small fixes and cosmetic changes.


1.1.0 - 24-Mar-2020
===================
- Added support for an initial RAMdisk (initrd) image.
- Added full support for the ext2 filesystem.
- Added support to execute scripts.
- Limit the number of messages on spurious interrupts.
- RAMdisks initialization now shows the range of the memory addresses of each
  RAMdisk created.
- Added VMA_REGIONS as a general configurable option (default: 150 entries).
- Changed the default kernel filesystem to ext2.
- Renamed the sleep addresses in tty.c.
- Added the ability to pass arguments to init from the kernel's command line.
- Included memory values in /proc/PID/stat and /proc/PID/status.
- Included the file /proc/PID/statm to provide more information about memory
  usage.
- Changed the ATA's SET MULTIPLE MODE command to do all I/O with 4KB block size
  (8 sectors) by default.
- Fixed to prevent from using an unexistent floppy type, in the fdd_type
  structure, if CMOS returns a value bigger than 0x04.
- Fixed a misplaced bitwise operator AND that was not ensuring the limitation
  to 1GB as the amount of physical memory supported.
- Fixed some bugs in *_minix_ialloc() and minix_balloc() when they fail.
- Fixed a malfunction in the job control.
- Fixed in sys_getgroups() to return the number of group IDs when the argument
  size is zero.
- Fixed the DEC Set Top and Bottom Margins (DECSTBM) sequence, which affected
  the scroll up mechanism in consoles.
- Fixed to set properly the timestamp on every read and write in all ttys.
- Fixed the start time value in /proc/PID/stat of every single process.
- Fixed to use a long long variable type to be able support block devices bigger
  than 4GB.
- Fixed a memory corruption bug processing the VT100 'CSI n J' sequence.
- Small fixes and cosmetic changes.


1.0.1 - 04-Aug-2018
===================
- Added a basic implementation of a Pseudo-Random Number Generator using the
  character devices /dev/random and /dev/urandom.
- Improved the mechanism in procfs_dir_readdir() to fix a memory corruption bug.
- Fixed a bug in procfs_dir_readdir() that prevented from reading correctly the
  entire procfs root directory.
- Fixed a bug in iso9660_dir_readdir() that prevented from reading correctly any
  directory.
- Fixed to show the complete pathname in the argv[0] of the init process.
- Fixed to protect INIT process from unexpected signals.


/* [previous][next][first][last][top][bottom][index][help] */