system/docs: update docs and SF constants to match actual kernel #306
Dismiss Review
Are you sure you want to dismiss this review?
Labels
Clear labels
Eolite
FS
Good First PR
GSoC
HardwareTested
HLL
Influence/Settings
Influence/Text/TYPO
IRCC
Lang/C
Lang/FASM
Pay for the code
Subsystem/API
Subsystem/Audio
Subsystem/Graphics
Subsystem/IPC and events
Subsystem/Memory
Subsystem/Network
Subsystem/Services(daemon)
Subsystem/Taskmanager
Subsystem/VFS
Subsystem/Window
Category
Applications
Category
Drivers
Category
General
Category
Kernel
Category
Libraries
The issue is suitable to beginners
This issue or PR in the Google Source of Code program
Kind
Breaking
Breaking change that won't be backward compatible
Kind
Bug
Something is not working
Kind
Build
Kind
Documentation
Documentation changes
Kind
Enhancement
Improve existing functionality
Kind
Feature
New functionality
Kind
Security
This is security issue
Kind
Testing
Issue or pull request related to testing
Paid task
PR
Conflicts
PR conflicts with main
PR
Dependent
This PR is dependent on another PR
Priority
Critical
1
The priority is critical
Priority
High
2
The priority is high
Priority
Low
4
The priority is low
Priority
Medium
3
The priority is medium
PR
Ready to merge
Pull request is ready for merge
PR
Request changes
Changes requested in pull request
PR
Review required
Reviewed
Confirmed
Issue has been confirmed
Reviewed
Duplicate
This issue or pull request already exists
Reviewed
Invalid
Invalid issue
Reviewed
Won't Fix
This issue won't be fixed
Status
Abandoned
Somebody has started to work on this but abandoned work
Status
Blocked
Something is blocking this issue or pull request
Status
Need More Info
Feedback is required to reproduce issue or to continue work
infinity service, audio drivers, midi, speacker, audio programs
vesa, vga, framebuffer, cursors, blitter, and video drivers
pipes, signals, events, shared memory
virt and phys memory allocators, malloc and other
userspace and kernel(for example: serial) services
process, threads, run apps, scheduler
drivers from filesystem, fs api, blkdev, programs that work with the file system
windows, skins, buttons, mouse and keyboard code for windows (not the base code)
Milestone
No items
No Milestone
Projects
Clear projects
No projects
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: KolibriOS/kolibrios#306
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
I don't think new aliases are necessary. It just clutter the code. Except:
SF_THREAD_CONTROL@@ -3691,0 +3695,4 @@* ecx = требуемый размер в байтахВозвращаемое значение:* eax = 0 - неудача* eax = указатель на выделенное кольцо"Кольцевой буфер/кольцевую память" maybe?
@@ -4517,3 +4548,3 @@eax - SF_BLITTER (73)========================================================================================= Функция 74, подфункция -1 =========================================== Функция 74, подфункция 255 ========================Is this really necessary?
@@ -5095,2 +5164,3 @@Возвращаемое значение:* eax = 0 если успех, иначе ошибка.* eax = 0 если успех, иначе отрицательный код ошибки:-EFAULT, -EINVAL, -EMFILE, -ENFILE.I'm not sure if this is specifically stated somewhere in the documentation (error codes).
@@ -5098,3 +5168,3 @@---------------------- Константы для регистров: ----------------------eax - SF_FUTEX (77)ebx - ...ebx - 13Why is there no constant?
@@ -3619,3 +3681,3 @@---------------------- Constants for registers: ----------------------eax - SF_SYS_MISC (68)ebx - SSF_MEM_ALLOC_RING (29)ebx - 30Why is there no constant?
@@ -3834,3 +3896,3 @@ebx - SSF_RESUME (5)======================================================================= Fucntion 69, subfunction 6 - read from memory of debugged process. === Function 69, subfunction 6 - read from memory of debugged process. ==Seems extra =
@@ -4452,3 +4514,3 @@---------------------- Constants for registers: ----------------------eax - SF_NETWORK_GET (74)eax - SF_NETWORK_GET (74) / SF_NETWORK_DEVICE (74)I suspect this is a little-used thing, let's not make aliases and just replace it with something that is often used
@@ -5251,0 +5327,4 @@* Subfunctions 4-7 are reserved and currently return -1.* Subfunctions 8, 9 and 12 are not implemented and return -EBADF.================================================================================= Function 77, Subfunction 10, Read from pipe. ============Maybe
-instead of,?@@ -5251,0 +5342,4 @@---------------------- Constants for registers: ----------------------eax - SF_FUTEX (77)ebx - 10Const?
@@ -5251,0 +5377,4 @@---------------------- Constants for registers: ----------------------eax - SF_FUTEX (77)ebx - 13Const?
New commits pushed, approval review dismissed automatically according to repository settings
@@ -5074,3 +5141,4 @@* esi = сколько байт записатьВозвращаемое значение:* eax = количество записанных байт-EBADF при ошибкеAre these constants documented somewhere?
@@ -132,6 +132,11 @@ SF_STYLE_SETTINGS=48SF_APM=49SF_SET_WINDOW_SHAPE=50SF_CREATE_THREAD=51SF_THREAD_CONTROL=51I suggest getting rid of this
SF_CREATE_THREADconstant and not creating aliases.SF_CREATE_THREADis used in some programs.It should be changed everywhere in a separate PR.
I deleted alias
SF_THREAD_CONTROLfor now,It will be decided here: #321
@@ -187,3 +192,1 @@SSF_WAIT_SIGNAL=14 ; wait for signal from another program/driverSSF_LOAD_DRIVER=16SSF_CONTROL_DRIVER=17SSF_WAIT_SIGNAL=14 ; GetEvent wrapper (wait for kernel event)What is
GetEvent?@@ -190,0 +192,4 @@SSF_WAIT_SIGNAL=14 ; GetEvent wrapper (wait for kernel event)SSF_GET_SERVICE=16SSF_CALL_SERVICE=17SSF_LOAD_DRIVER=16 ; alias (deprecated name)What's the problem with old names?
@@ -70,11 +70,11 @@ SF_SYSTEM=18SSF_WINDOW_BEHAVIOR=25 ; window focus relation with other windowsLet's not touch this file. Fix it as part of this task: #317
Please roll back this file!
@@ -5054,4 +5117,3 @@Параметры:* eax = 77 - номер функции* ebx = 10 - номер подфункции* ecx = дескриптор файлаThere is no mistake here. Reverse this change
@@ -5049,20 +5108,28 @@ Remarks:eax - SF_FUTEX (77)ebx - SSF_WAKE (3)============================================================================= Функция 77, подфункция 10, Прочитать из файла в буфер. =======There is no mistake here. Reverse this change.
@@ -3369,3 +3375,3 @@* буфер, на который указывает ecx, содержит следующую информацию:* +0: dword: идентификатор последующих данных сигнала* +4: данные принятого сигнала (20 байт), формат которых* +4: 5 dword: данные принятого сигнала, формат которыхIn my opinion, 20 bytes is more obvious than 5 dword
In all other similar places, dwords are used, not bytes.
So it is better for consistency.
@@ -3395,3 +3405,3 @@---------------------- Константы для регистров: ----------------------eax - SF_SYS_MISC (68)ebx - SSF_LOAD_DRIVER (16)ebx - SSF_LOAD_DRIVER (16) / SSF_GET_SERVICE (16)In my opinion, services can be confused with daemons. The old name reflects the essence more.
@@ -3418,3 +3430,3 @@---------------------- Константы для регистров: ----------------------eax - SF_SYS_MISC (68)ebx - SSF_CONTROL_DRIVER (17)ebx - SSF_CONTROL_DRIVER (17) / SSF_CALL_SERVICE (17)The same: https://git.kolibrios.org/KolibriOS/kolibrios/pulls/306/files#issuecomment-3987
@@ -4522,3 +4553,3 @@Параметры:* eax = 74 - номер функции* bl = -1 - номер подфункции* bl = -1 (или 255) - номер подфункцииThis should be obvious to the developer. Why explain this?
@@ -4946,3 +4978,3 @@---------------------- Константы для регистров: ----------------------eax - SF_NETWORK_SOCKET (75)bl - SSF_GET_PAIR (10)bl - SSF_GET_PAIR (10) / SSF_SOCKET_PAIR (10)If this is needed for "getting" why change it?
@@ -5033,3 +5091,4 @@-2 - контрольное значение не соответствует---------------------- Константы для регистров: ----------------------eax - SF_FUTEX (77)Since in function 77 it is now better to replace not only futexes with
SF_POSIX. And add prefixes for subfunctions likeSF_FUTEX_CREATE, etc.As these constants are used in some programs, that should be changed in a separate PR.
Will be fixed as part of this task: #321
@@ -5051,2 +5110,3 @@============================================================================= Функция 77, подфункция 10, Прочитать из файла в буфер. =======Замечания:* Подфункции 4-7 зарезервированы и сейчас возвращают -1.Add here that for now only pipe file descriptors are supported
@@ -5063,3 +5129,3 @@---------------------- Константы для регистров: ----------------------eax - SF_FUTEX (77)ebx - ...ebx - SSF_PIPE_READ (10)It is assumed that reading will be in the future on file descriptors. It is better to remove the
PIPEprefix if the constant names are not taken.@@ -5078,3 +5147,3 @@---------------------- Константы для регистров: ----------------------eax - SF_FUTEX (77)ebx - ...ebx - SSF_PIPE_WRITE (11)Same: https://git.kolibrios.org/KolibriOS/kolibrios/pulls/306/files#issuecomment-3992
@@ -5025,4 +5083,2 @@* eax = 77 - номер функции* ebx = 2 - номер подфункции* ecx = дескриптор фьютекса* edx = контрольное значениеIt was written correctly. It is a control value and not a pointer. Please roll back
@Burer Control value. NOT a pointer. Please note:
@@ -4997,3 +5055,3 @@* eax = 77 - номер функции* ebx = 0 - номер подфункции* ecx = указатель на контрольное значение фьютекса (dword)* ecx = указатель на контрольное значение фьютексаIt’s true that this is a pointer to dword. Anything larger than dword will probably be ignored.
@@ -5000,2 +5057,3 @@* ecx = указатель на контрольное значение фьютексаВозвращаемое значение:* eax = дескриптор фьютекса, 0 при ошибке* eax = указатель на дескриптор фьютекса, 0 при ошибкеI apologize, it seems I expressed myself incorrectly. Everything here is correct; it is a descriptor and not a pointer (it doesn’t matter to us how this is implemented in the kernel); even just a pointer can be considered a “descriptor”. Please roll back
@@ -5010,3 +5068,3 @@* eax = 77 - номер функции* ebx = 1 - номер подфункции* ecx = дескриптор фьютекса* ecx = указатель на дескриптор фьютексаPlease roll back. See message above
@@ -5026,3 +5084,2 @@* ebx = 2 - номер подфункции* ecx = дескриптор фьютекса* edx = контрольное значение* ecx = указатель на дескриптор фьютексаPlease roll back. See message above
@@ -5041,3 +5100,3 @@* eax = 77 - номер функции* ebx = 3 - номер подфункции* ecx = дескриптор фьютекса* ecx = указатель на дескриптор фьютексаPlease roll back. See message above
@@ -5053,0 +5112,4 @@* Подфункции 4-7 зарезервированы и сейчас возвращают -1.* Подфункции 8, 9 и 12 не реализованы и возвращают -EBADF (-9).============================================================================= Функция 77, подфункция 10, Прочитать из файла. =======Seems missing
====@@ -5071,3 +5139,2 @@* ebx = 11 - номер подфункции* ecx = дескриптор файла* edx = указатель на буфер, откуда брать данные для записи* ecx = указатель на файловый дескрипторThere is no mistake here. Reverse this change
@@ -5197,11 +5281,12 @@ Remarks:Parameters:* eax = 77 - function number* ebx = 1 - subfunction number* ecx = futex handleThere is no mistake here. Reverse this change
@@ -5181,3 +5269,3 @@* eax = 77 - function number* ebx = 0 - subfunction number* ecx = pointer to futex dword* ecx = pointer to futex control valueCorrect: Pointer to futex dword control value.
@@ -5187,3 +5273,1 @@* Use subfunction 1 to destroy the futex.The kernel destroys the futexes automatically when the processterminates.* eax = pointer to futex handle, 0 on errorThere is no mistake here. Reverse this change
@@ -5215,3 +5300,1 @@* ecx = futex handle* edx = control value* esi = timeout in system ticks or 0 for infinity* ecx = pointer to futex handleThere is no mistake here. Reverse this change
@@ -5216,2 +5300,2 @@* edx = control value* esi = timeout in system ticks or 0 for infinity* ecx = pointer to futex handle* edx = pointer to futex control valueThere is no mistake here. Reverse this change
Control value. NOT a pointer. Please note:
@@ -5235,3 +5315,3 @@* eax = 77 - function number* ebx = 3 - subfunction number* ecx = futex handle* ecx = pointer to futex handleThere is no mistake here. Reverse this change
WIP: system/docs: align docs with actual kernel, add missing SF constantsto system/docs: update docs and SF constants to match actual kernelNew commits pushed, approval review dismissed automatically according to repository settings
@dunkaist @Doczom @Sweetbread Please review this again if possible...