-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathChanges
591 lines (575 loc) · 32 KB
/
Changes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
1.7.0 - DD-MMM-2025
===================
- Added the member s_blocksize_bits in the superblock struct to use bitwise
shift instead of division in ext2_bmap() and ext2_truncate().
- Changed modulo operations by bitwise (where possible) to reduce dependency
from libgcc.
- Removed some flags from LDFLAGS in the main Makefile that prevented compile
the kernel with newer GCC versions. [#97]
- Fixed ext2_balloc() and ext2_ialloc() to return -ENOSPC when there is not
space on device.
- Fixed fs.h to include fd.h when CONFIG_NET is not set.
- Fixed some kernel crashes with the message 'WARNING: page_head returned NULL!
(free_pages = 0)' when using a RAMdisk drive as the root filesystem. [#98]
1.6.0 - 15-Nov-2024
===================
- Added support for UNIX-domain sockets (with the Berkeley socket API). [#36]
- Added support for sys_truncate64, sys_ftruncate64, sys_stat64, sys_lstat64,
sys_fstat64 and sys_fcntl64 system calls. [#49]
- Added support for sys_getdents64. [#51]
- Added support for sys_chown32. [#53]
- Added support for sys_utimes. [#57]
- Added support for building Fiwix with the TCC compiler. [#63]
- Added support for the Linux boot protocol in kexec. [#65]
- Added support for the PS/2 mouse with the new device /dev/psaux. [#94]
- Added the new configuration option PAGE_HASH_PERCENTAGE (0.1% by default) to
set the size of the page_hash_table relative to the number of physical memory
pages, with a mininum of 1 page and a maximum of 16 pages. The kernel now
shows the hash tables sizes during the boot.
- Added to sync drives when kernel stops because no more user processes exist.
[#70]
- Added the flag PF_NOTINTERRUPT to avoid waking up a process sleeping in the
non-interruptible mode.
- Added a consistency check on every directory entry during ext2_lookup().
- Added a call to invalidate_buffers() before reread the partition table in the
ioctl BLKRRPART.
- Rewritten how multiple I/O block requests are managed. Now the new I/O block
layer enqueues a block request group with all the buffers needed in a read or
write operation, and keeps sleeping until the whole transaction has been
completed. This improves dramatically the disk accesses, reduces a lot the
number of context switches, and it overall boosts the performance of the
system.
- Changed the file position for reads to be set to zero when a file is opened
with O_APPEND. [#76]
- Implement mapping framebuffer physical address to user space using mmap. [#79]
- Changed the inode cache mechanism to avoid caching inodes from
pseudo-filesystems.
- Changed count_active_procs() to also count processes that are sleeping as
non-interruptible.
- Changed the tty sleeping address to be process specific in order to reduce
the wakeup latency.
- Moved the values sb->dirty, inode->locked and inode->dirty to flags.
- Moved the call to sysrq() into the keyboard interrupt bottom half.
- Improved code compaction and efficiency in ATA disk read/write.
- Improved the efficiency of the buffer cache.
- Improved ext2_file_write() to use a multiblock request with gbread() when the
count is greater than the blocksize.
- Reorganized and improved the system console related code.
- Pass through 64-bit PAE memory entries as part of kexec. [#67]
- Make sure that the early system log will be shown in all system consoles.
- Removed unneeded low memory kernel virtual address mappings. [#88]
- Reduced a number of functions in the timer interrupt by moving them to the
bottom half.
- Reorganized the code of the keyboard driver.
- Renamed and reorganized tty_queue into charq to make it more generic.
- Fixed sys_mount() to avoid mounting a device already mounted.
- Fixed compilation errors when CONFIG_PCI is not defined.
- Fixed to allow removing a directory in use. [#59]
- Fixed in sys_getcwd() to check 'diff_dev' variable before accessing
'tmp_inode'. [#61]
- Fixed vconsole_select() to not switch to an unexistent vconsole.
- Fixed ata_hd_init() to make sure that the command SET_FEATURES is sent in all
cases.
- Fixed the kernel stack backtrace to skip the first 5 stack values.
- Fixed an scrolling bug with 'vi' in fbcon_scroll_screen(). [#81]
- Fixed UNIX sockets working with select(). [#83]
- Fixed serial system console table overindex. [#87]
- Fixed a major problem in do_switch routine. [#89]
- Fixed incorrect passing of e820 memory map to Linux kexec guests. [#72]
- Fixed EXT2_DESC_PER_BLOCK() to avoid redundant calculations.
- Fixed kswapd() to enable interrupts after initializing devices.
- Fixed a long standing bug during bitmap calculation in the ext2 filesystem.
- Fixed CHECK_IF_NESTED_INTERRUPT by comparing KERNEL_CS against CS.
- Fixed a kernel crash on boot when PCI is disabled and the kernel parameter
'bga=' is supplied.
- Fixed sleep() to avoid race conditions by executing CLI() earlier.
- Fixed a bug introduced in 4317cbe that prevented from continuing to the next
running process in stop_kernel().
- Fixed read_msdos_partition() to use the default device block size instead of
BLKSIZE_1K.
- Fixed to flag the superblock as dirty in ext2_ialloc(), ext2_ifree(),
ext2_balloc() and ext2_bfree().
- Fixed fbcon_blank_screen() to not show cursor. [#94]
- Fixed a lack of schedule randomization introduced in b935b3d.
- Fixed reclaim_buffers() to run with interrupts enabled.
- Fixed to initialize the new vma struct in merge_vma_regions().
- Fixed to reset the flag before calling some functions to avoid reentrancy
in irq_keyboard_bh().
- Fixed a long standing bug in vconsole_select() that prevented from switching
between consoles in VT_PROCESS mode.
- Fixed permissions in the ioctl VT_WAITACTIVE.
- Fixed a long standing bug in wakeup() that put as running one in two processes
sleeping, leading to frequent cases where some processes keep sleeping.
- Small fixes and cosmetic changes.
1.5.0 - 15-Nov-2023
===================
- Added a kernel memory allocator that uses the buddy algorithm to manage
requests smaller than PAGE_SIZE (4KiB).
- Added the new file /proc/buddyinfo to view buddy algorithm statistics.
- Added the new configuration option FREE_PAGES_RATIO (with a default value of
5), as the minimum percentage of free memory pages before calling the swapper
to reclaim memory from the buffer cache.
- Added the buffer-dirty-flush kernel daemon 'kbdflushd'. This also includes the
new configuration option BUFFER_DIRTY_RATIO to limit the percentage of dirty
buffers.
- Added the new file '/proc/sys/vm/dirty_background_ratio' to show the current
value of the option BUFFER_DIRTY_RATIO.
- Added support for the Bochs Graphics Adapter with the configuration option
CONFIG_BGA, and introducing the new kernel parameter 'bga=' to set the screen
resolution (width x height x bpp). Refer to 'docs/kernel-parameters.txt' to
know all the screen resolutions supported.
- Added 32bit I/O transfers support to the ATA/ATAPI driver.
- Added DMA (Multi-word) transfers support to the ATA disk driver.
- Added overall improvements in the ATA disk driver.
- Added a check in psig() to terminate the process if it doesn't have the stack
region in its vma table.
- Added PCI BARs handling in the serial driver.
- Added the files 'buffer_max' and 'buffer_nr' in '/proc/sys/kernel/'.
- Added more checks on data received during ATA drive identify to make sure it
makes sense.
- Added the magic SysRq key 'm' to show current memory information.
- Added the Multiboot magic value as a new parameter in get_last_boot_addr() to
avoid a kernel panic when it is booted without the Multiboot structure.
- Added a check if flag MULTIBOOT_INFO_ELF_SHDR is set before reading the ELF
section header table to avoid possible kernel panics.
- Added support in parse_cmdline() to recognize values enclosed in double
quotes.
- Added support for multiple RAMdisk drives.
- Added kexec implementation (see 'docs/kexec.txt') which introduces the new
configuration option CONFIG_KEXEC (disabled by default).
- Added microsecond resolution to sys_gettimeofday().
- Added the /proc/<PID>/fd/ subdirectory containing symbolic links named by its
file descriptor.
- Added support for 64bit offsets and introduced the new option CONFIG_OFFSET64
(enabled by default).
- Added the linkage of libgcc into the kernel in order to have functions like
__divdi3() and friends, necessary when doing certain arithmetic operations
with 64bit offsets on an i386 architecture.
- Added support for the O_DIRECTORY flag to sys_open(). [#32]
- Added support for the virtual memory split 2GiB(user)/2GiB(kernel), by
introducing the new option CONFIG_VM_SPLIT22 (disabled by default). [#34]
- Added support for large initrd images (see 'docs/initrd.txt'). [#34]
- Added the ability to have different blksize values for each device minor.
- Added the new system call sys_lchown by renaming the old sys_chown (number 16)
to sys_lchown, and creating the new sys_chown (number 182) which will follow
(dereference) symbolic links. This might break the compatibility with Linux
2.0 ABI.
- Added support for F_DUPFD_CLOEXEC in sys/fcntl.h. [#40]
- Added support for sys_readv() and sys_writev() system calls. [#42]
- Added support for sys_mmap2() system call. [#47]
- Added the length modifier 'l' for long long int arguments in printk().
- Changed the mode how the kernel mounts the root filesystem. From now on, it
will be mounted in read/write mode by default. This introduces the new kernel
parameter 'ro' to force to mount it in read-only mode.
- Changed the vma table from static to dynamically allocated array and removed
the option VMA_REGIONS.
- Changed lots of fixed-size arrays to dynamically allocated arrays.
- Changed malloc_name() and free_name() to use the new memory allocator.
- Changed do_namei() to use the new memory allocator.
- Changed the generic llseek() method to support 64bit offsets.
- Changed the location of the kernel stack address to be right after the BSS
section. [#34]
- Rewritten reclaim_buffers() to be more efficient and also to free up unused
buffers and shrink the buffer table.
- Modified the Makefile to disable compiling with PIE option enabled by some
builds of GCC. [#6]
- Reverted 40bf18b because some signals weren't caugth and created malfunction
in cron jobs.
- Reverted 082b316 as it created a kernel panic when using IPC shared memory.
- Reverted ad3fc56 so malloc_name() and free_name() will always request
PAGE_SIZE bytes. This is more efficient as it helped to remove the call to
strlen() and even can return now a proper ENAMETOOLONG error.
- Disabled interrupts in runnable() and not_runnable() to avoid race conditions.
- Removed the option RAMDISK_MAXSIZE from the RAMdisk drives.
- Bar addresses of PCI devices are now discovered by the driver.
- Reorganized _init() functions in start_kernel().
- Disk drives now show the ATA major version number.
- Reorganized the steps to do on a page fault in kernel mode.
- The kernel parameter 'ramdisksize=' no longer controls the size of the initrd
image. [#34]
- The build of the Minix filesystem depends on the new option CONFIG_FS_MINIX
(disabled by default).
- Fixed a bug in syscalls/wait4.c introduced in 9cfe372 that created malfunction
in control jobs.
- Fixed to call sleep_init(), buffer_init(), sched_init() and inode_init()
before initializing devices.
- Fixed the offset value in elf_load_interpreter() and elf_load().
- Fixed in pci_add_device() to use pci_read_short() instead of pci_read_char()
for Command and Status registers.
- Fixed in do_execve() to reuse tmp_name allocated in sys_execve().
- Fixed a number of common variable definitions that prevented from build Fiwix
with the newest GCC cross-compiler. [#10]
- Fixed in fs/namei.c to return ENOENT for missing directory. [#12]
- Fixed a bug in ext2_bmap() that prevented large files from persist on an ext2
filesystem. [#14]
- Fixed a bug in v2_minix_bmap() that prevented large files from persist on a
minix v2 filesystem. [#14]
- Fixed do_page_fault() to handle better a faulty address outside the user
address space in kernel mode.
- Fixed the I/O address size in the ISA serial driver.
- Fixed a missing iput() in ext2_followlink() when there are too many nested
symbolic links.
- Fixed a missing iput() in minix_followlink() when there are too many nested
symbolic links.
- Fixed the hexadecimal values of /dev/tty10, /dev/tty11 and /dev/tty12 in
kparms.h.
- Fixed some possible race conditions in buffer cache.
- Fixed a bug in mmap that prevented overlapped VMA regions from merging
correctly. [#16]
- Fixed to terminate properly a read or write request on hdd timeout.
- Fixed a race condition in sys_nanosleep() when setting the processs sleeping
time.
- Fixed merge_vma_regions() to free memory pages in overlapped segments. [#16]
- Fixed memory mapped files not written to disk correctly. [#18]
- Fixed sys_execve() to make sure arguments and environment do not exceed the
maximum length. [#20]
- Fixed sys_mount() to use malloc_name() and free_name() to validate the
argument 'fstype'.
- Fixed do_page_fault() to handle a page fault when trying to access a
non-existent user stack address in kernel mode when
CONFIG_LAZY_USER_ADDR_CHECK is enabled. [#22]
- Fixed verify_address() to accept a possible non-existent user stack address
when CONFIG_LAZY_USER_ADDR_CHECK is disabled, since do_page_fault() will do
the rest of the job. [#22]
- Fixed the logic in parse_arg() to support kernel parameters without arguments.
- Fixed a long standing bug where after removing an inode there was not a call
to invalidate all its pages from the cache. [#24]
- Fixed a missing initialization in the PCI structure during scan_bus(). [#25]
- Fixed bread() to check if the bytes read matches with what was requested.
- Fixed premature output of information from the serial driver when acting as
the remote console.
- Fixed frame buffer memory spaces to be marked as reserved if they conflict
with available memory.
- Fixed sys_select() to return in the timeout argument the amount of time not
slept. This is Linux specific but POSIX permits this behavior.
- Fixed Magic SysRq key 't' to also list zombie processes.
- Fixed Magic SysRq keys to work even when the tty has not been opened yet.
- Fixed get_free_page() to reduce the excessive number of iterations with
reclaim_buffers() when running out of memory pages.
- Fixed the mechanism to sleep all processes in stop_kernel().
- Fixed the sleep address in page_lock() to match with page_unlock().
- Fixed a kernel panic if irq_keyboard() receives an unrecognized function key.
- Fixed to correctly disable the RAMdisk device if there is not enough physical
memory.
- Fixed an inode-related race condition in iget() and iput().
- Fixed to not use the buffer after failed to be synced in sync_one_buffer().
- Fixed in ext2_symlink(), ext2_mkdir(), ext2_mknod() and ext2_create() to make
sure the inode doesn't exist.
- Fixed in minix_symlink(), minix_mkdir(), minix_mknod() and minix_create() to
make sure the inode doesn't exist.
- Fixed a deadlock between getblk() and kbdflushd(). [#27]
- Fixed a missing lock that led to a possible memory page corruption bug in
bread_page(). [#27]
- Fixed atapi_cd_init() to setup the correct block size in the device structure.
- Fixed sys_ftruncate() to return EINVAL if its method does not exist.
- Fixed sync_superblocks() to sync all superblocks if argument is zero.
- Fixed the size on every symlink in procfs to 64 bytes.
- Fixed iget() to avoid locking when read_inode() returns an error.
- Fixed a missing call to sync_buffers() in close() methods of RAMdisk drive and
floppy drive.
- Fixed serial_set_termios() to avoid a division by zero.
- Fixed script_load() with || instead of && that led to incorrectly recognize as
script when there is an incomplete shebang.
- Fixed a linked list corruption when messages are retrieved not sequentially in
sys_msgrcv().
- Fixed ata_hd_init() to not fail build if CONFIG_PCI is #undef.
- Fixed padding in fbcon_insert_char() to use character 0x20 instead of 0x00.
- Fixed vgacon_scroll_screen() to use double-buffering.
- Small fixes and cosmetic changes.
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.
- Fixed a bug introduced in 8eaed51 that prevented initrd images from
working. [#7]
- 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.
1.0.0 - 23-Apr-2018
===================
- Fixed a bug in reclaim_buffers() to avoid kernel freeze.
- Fixed a corruption bug when creating the dirent structure in the dir_readdir()
functions.
- Massive code cleaning.
- New system calls:
sys_select