Releases: amoldhamale1105/frostbyte
frostbyte v2.4.1
Release notes for frostbyte v2.4.1:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Bug fixes
- Security fix: Hitting enter on shell prompt after pushing stopped process waiting for key input to background dumps entire system key buffer on the console
- Signals causing spurious syscall wake-ups resulting in unexpected program behavior
- Stopped process waiting on keyboard input takes premature control of key buffer
- Error (-1) returned by waitpid syscall not handled by shell
- Job control commands fg, bg cause fatal system exception (ESR value: 0x96000004) on raspberry pi 4
- Stopping a process with Ctrl-Z prints garbage characters after process name in console on raspberry pi 4
Improvements
- Optimize process scheduler list traversal algorithm, improving performance
- Issue key combination (Ctrl-C, Ctrl-Z) generated signals from parent shell rather than current process
- Remove redundant code and optimize kernel system call implementations
- Makefile improvements and comment corrections
Open Issues
Full Changelog: v2.4.0...v2.4.1
frostbyte v2.4.0
Release notes for frostbyte v2.4.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Board support for raspberry pi 4
- New make variable
BOARDand segregation of output artifacts based on selected target - Boot time kernel logs and updated welcome banner
- New option of machine hardware in
unamecommand
Improvements
- Generic FAT16 disk image under boot, modifications made under build preventing changes to disk image on every build
- Reduce memory writes to improve performance
- Copy only required segments of a binary instead of whole page while forking to improve performance
- Optimize stack and heap size to improve performance and memory usage
- Improve shutdown logs
- Improve comments in code
- Prune readme to make it more concise and less pompous
Open Issues
Full Changelog: v2.3.0...v2.4.0
frostbyte v2.3.0
Release notes for frostbyte v2.3.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Process environment with variable name and value pairs, exportable to child processes
- Shell commands (
export,envandunset) to monitor and manage process environment - Enable
echocommand to evaluate environment variables when preceded by$ - Capability of evaluating nested environment variables in
echo,exportandunsetcommands - Login processes sets universal
USERenvironment variable for shell and its children to identify current user - Segregation and fixed quota for process stack and heap from the total allocated memory for the process
- Extended userspace virtual address space mapping for process environment
- Implementation of hash map data structure and function algorithms in the kernel
API updates
- Added
find()library function to find the index of first occurrence of a character in a given string - Added POSIX compliant
setenv()system call to set an environment variable with given value for the current process and its children - Added POSIX compliant
getenv()system call to get the value of an environment variable by its name - Added POSIX compliant
unsetenv()system call to remove a variable from the current process environment - Added
switchpenv()system call to switch to the parent environment
Caution: This system call serves special purpose within implementation of shell commands like
echoandexportand should be avoided in regular applications because it irreversibly switches to parent process environment
- Added
getfullenv()system call to get a list of all environment variables for current process
Improvements
- Shell deduces current user for its prompt using the
USERenvironment variable instead of-uoption used earlier - Usage of
USERenvironment variable enables propagation of current user to child shell instances instead of having placeholder string "user" for all shell instance prompts spawned from the main shell - Improve structure and error handling of userspace virtual memory setup and copy kernel functions
- Save process arguments to heap instead of the stack to prevent encroachment of stack space
- Accommodate process page table, kernel stack and heap within the same 2M page for efficiency
- Process table slot cleared before reallocation to prevent corruption due to residual data
- Rectify usage notation for mandatory options/arguments
Bug fixes
- Kernel macros (
container_ofandoffset_of) inaccessible when used with standard headers with missing definitions printf()function crashes when string pointer is NULL for%sformat specifierprintf()function gives erratic output when supplied empty string against%sformat specifier
frostbyte v2.2.1
Release notes for frostbyte v2.2.1:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Bug fixes
- Pressing Ctrl+C does not provide feedback on shell and takes effect only after pressing Enter key
- Pressing Ctrl+C consecutively kills the shell, logs out in case of main shell (PID 2)
- Ctrl+C does not abort currently typed command and does not renew the prompt
frostbyte v2.2.0
Release notes for frostbyte v2.2.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Job monitoring and control with
jobs,fgandbgcommands - Stop and resume processes with
SIGTSTP,SIGSTOPandSIGCONTsignals - Ctrl+Z to stop foreground process on shell and create a job
API updates
- Added
to_lower()library function to convert a character to lowercase - Added
sort()library function to sort an array of integers in ascending order get_proc_data()system call uses an additional argument to fetch job specification of a given process- Added
setjobctl()system call to set job control request for a given job specification - Added
getjpid()system call to get PID of a job specification only if it belongs to current shell session
Improvements
- Optimize key buffer management and notifications for long key sequences and special characters
- Improvements to kernel kill functionality with addition of process parameter
- Improved and optimized process control kernel methods for wait, exit and parent switching
- Process mode checked on waking up as a background process waiting for keyboard input
- Prevent dumping of residual characters from previous foreground process by flushing key buffer
- Additional methods for finding and getting the last element in a linked list
- Set up build system for debug and release build types
Bug fixes
- Key buffer pointer gets corrupted on resuming a stopped process
- PID of stopped process not returned by the wait system call
- Shell used PID returned by
fork()instead of return value fromwait()to check status of process being waited for - Zombies hijacked by init during exit even when parent waiting for them
- Termination and suspension signal handlers do not remove a process from waitlist
SIGKILLhandler does not kill childrenSIGKILLhandler does not unblock the parent if it is waiting
frostbyte v2.1.0
Release notes for frostbyte v2.1.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Cursor movement on shell with arrow keys
- Character insertion and deletion by moving cursor to edit typed commands and arguments
- Raw input processing for
scanf()and login password prompt for all key sequences - Session and system wide process information with
pscommand
API updates
sleep()system call renamed tomsleep()to reflect it's nature of sleeping at millisecond intervals than seconds and prevent prototype declaration conflict ofsleep()function in C standard header filesget_active_procs()system call uses an additional argument to determine process snapshot request type
Improvements
- Improved command line option parsing logic making command arguments sequence and position agnostic
- Command arguments can be stitched together with a single
-. For example,ps -e -fandps -efare both valid and identical - Improved usage output format on typing
<command> -hfor applicable commands
Bug fixes
- Zombies not cleaned up on user log out, persist in next user session
- Background processes spawned from the shell with
&turn into zombies after normal exit - Process exit status not tracked on delivering a
SIGKILL
frostbyte v2.0.1
Release notes for frostbyte v2.0.1:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Updates
- LICENSE update to GPL v3
- LICENSE present in source tree and notice attached to all source files
Bug fixes
- Issue #1 fixed - Serial console unresponsive on pressing arrow keys
- Login accepted if only the starting slice of the username entered matched with the name entry in passwd file
Open issues
frostbyte v2.0.0
Release notes for frostbyte v2.0.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Login shell/prompt backed by passwd file on FAT16 disk
- Standard passwd file format with password-less configuration
- Full format
psoutput with command line arguments for every process using the-foption - Enable init process (PID 1) to wait for own children and processes orphaned by exiting parents
- Respawn login shell on exit of main shell
- POSIX compliant
exitandechocommands
API updates
wait()system call can query child exit status using standard macros in sys/wait.h by passing the returned statuswaitpid()system call can wait for multiple children with-1as value ofpidargument and provide options to configure wait executionexit()system call accepts status argument and also passes the return value frommain()to the kernel as exit statuskill()system call acceptspidargument as0for sending signals to group and-1for system wide signalling as per POSIX standardget_proc_data()system call has new argument to accept process command line arguments. Used by thepsfull format command- Added POSIX compliant
waitpid()system call - Added
get_pstatus()system call to enable a process to query the parent processes current status
Improvements
- Shutdown logs printed in correct sequence as and when they are terminated rather than when the signal is delivered
- Enable
wait()function to process all child processes - Update shutdown message to make it useful than entertaining
- Restructure Makefile to supply toolchain include paths to kernel and userspace programs
Bug fixes
- Nested shell executions corrupt keyboard buffer read position pointers
- Signal handler gets reset to default with
SIG_IGNargument tosignal()system call - Default handler not set for
SIGABRT - Zombies not cleaned on exiting from nested shell
- exit command not fetching last command's status when executed without options
- tail pointer and list termination not handled correctly
Open issues
frostbyte v1.0.0
Release notes for frostbyte v1.0.0:
Note: Release notes for current version are created as a delta against previous version's release notes i.e. features, improvements and bug fixes from previous releases will be present in the current release by default unless mentioned otherwise
Features
- Kernel at EL1 and user programs at EL0
- Synchronous and asynchronous exception handling
- Interrupt handling and interrupt vector table
- Timer interrupt based FIFO scheduling
- Paging and virtual memory management
- FAT16 filesystem support and VFS
- Interactive shell on serial console
- POSIX compliant system calls and commands
- POSIX signal handling framework
- Custom standard library functions
- Custom programs with command-line arguments and user input
- Foreground and background process management