summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
26 hoursusr: sysctl: Add parsing for 'hw.machine'mainexptIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
26 hourskernel: sysctl: Add 'hw.machine' variableIan Moffett
Introduce the 'hw.machine' sysctl variable to represent the current machine architecture. Signed-off-by: Ian Moffett <ian@osmora.org>
26 hoursusr.sbin: init: Refactor init_hostname()Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
26 hoursusr.bin: sysctl: Remove extra newlineIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
26 hourskernel: descrip: Fix byte count on read()Ian Moffett
Byte count returned must be the number of bytes read() which may be less than the number of bytes actually requested. Signed-off-by: Ian Moffett <ian@osmora.org>
27 hoursusr.bin: sysctl: Support non 'kern.*' variablesIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
27 hoursusr.bin: fetch: Remove unused globalIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
27 hourskernel: sysctl: Report 'hw.*' variablesIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
30 hoursusr.sbin: init: Add basic loggingIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
30 hoursusr.bin: osh: Add true hostname to promptIan Moffett
This commit puts the true hostname of the machine in the OSH prompt using gethostname() Signed-off-by: Ian Moffett <ian@osmora.org>
30 hoursusr.sbin: init: Set hostname to /etc/hostnameIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
30 hourskernel: sysctl: Set 'oldlenp' to NULL if neededIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourslib: libc: Implement gethostname() + sethostname()Ian Moffett
This commit adds the POSIX gethostname() and sethostname() functions to the Hyra C library. Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourskernel: sysctl: Add 'kern.hostname' varIan Moffett
This commit introduces the 'kern.hostname' sysctl variable to store the machines hostname. Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourskernel: Do not blacklist AHCIIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourskernel: sysctl: Allow 'old*' fields to be NULLIan Moffett
When setting sysctl variables from userspace, the 'old' fields will unused and thus typically be set to NULL. This commit modifies the behaviour of do_sysctl() to enable this. Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourskernel: sysctl: Be sure to set 'newlen' in argsIan Moffett
Since we are approaching the point to where we'll need to set sysctl variables from userspace. It would be a wise idea to actually set the length of the new data. Signed-off-by: Ian Moffett <ian@osmora.org>
31 hourskernel: sysctl: Add sysctl_clearstr()Ian Moffett
Introduce the sysctl_clearstr() function to clear string variables that aren't readonly to a known state. Signed-off-by: Ian Moffett <ian@osmora.org>
32 hourslib: libc: Fix syntax issue in ctype.hIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
32 hoursproject: Bump version to 2.6Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
37 hoursusr: fetch: Add CPU brand informationIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
39 hoursusr.bin: Add 'sysctl' programIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
39 hourslib: libc: Add sysctl()Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
40 hourskernel: vcache: Include '\0' in sysctl stringIan Moffett
The strlen() function does not count the null terminator when measuring the length of the string and therefore a value of 1 must be added to do so. Signed-off-by: Ian Moffett <ian@osmora.org>
2 daysman: cat(1): Add description of flagsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2 daysusr.bin: cat: Add the '-n' and '-b' flagsIan Moffett
Introduce two new flags for cat(1) '-n': number all lines '-b': number only non-blank lines Signed-off-by: Ian Moffett <ian@osmora.org>
2 dayslib: libc: Set 'optind' to initial value of 1Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2 dayslib: libc: Add initial POSIX getopt() implIan Moffett
This commit introduces an initial implementation of the POSIX getopt() argument parser. Signed-off-by: Ian Moffett <ian@osmora.org>
2 dayskernel: sysctl: Use user headers ifndef _KERNELIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2 daysMerge branch 'expt' of github.com:sigsegv7/Hyra into exptIan Moffett
2 dayskernel/amd64: Limit frame depth in backtraceIan Moffett
A backtrace usually occurs during critcal system events like panics. When the system in a error state, we cannot trust the correctness of the stack. This commit aims to improve checks done in a731d4e by adding a max frame depth that limits how many frames can be walked. Signed-off-by: Ian Moffett <ian@osmora.org>
2 dayskernel/amd64: Add better checks on 'rbp' and 'rip'Ian Moffett
Improve handling within the stacktrace logic used during system panics and critical events. - Perform checks on 'rbp' *before* logging - Ensure RBP is 8-byte aligned Signed-off-by: Ian Moffett <ian@osmora.org>
2 dayskernel/amd64: Add better checks on 'rbp' and 'rip'Ian Moffett
Improve handling within the stacktrace logic used during system panics and critical events. Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayslib: libgfx: Add SHAPE_SQUARE_BORDERIan Moffett
Introduce new SHAPE_SQUARE_BORDER shape type to draw unfilled (bordered) squares. Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayslib: libgfx: Simplify gfx_draw_square()Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayslib: libgfx: Fix one line bugsIan Moffett
- Add missing return statement - Fix x/y mismatch Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Fake success on missing optIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Fix typo in commentIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel & libc: Add POSIX setsockopt syscallIan Moffett
This commit implements the POSIX setsockopt syscall so that user programs may be able to configure sockets they have created. Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Implement recv() timeoutIan Moffett
This commit implements proper timeout handling for recv(). Previously, the recv() syscall would yield the current process forver until data is available to be read. Obviously, that is not the most ideal as it is not uncommon for programs to try seeing if any data exists on the socket before deferring to perform some other task until data arrives. The basics of how this work is that we try reading data off of some specified socket. However, if no data is present, we must wait for the given timeout value before attempting to read again. While this is pretty effective and works perfectly fine as of now, it might be worth optimizing this later to allow that timeout period to be somehow "interrupted" by data arriving at a socket so that the program does not have to defer execution for the full wait-period. Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Add POSIX setsockopt()Ian Moffett
This commit introduces the kernel-side implementation of setsockopt() for setting options on a socket file descriptor. See POSIX setsockopt() for more information. https://pubs.opengroup.org/onlinepubs/9690949499/functions/setsockopt.html Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Fix typo in code commentIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: sched: Add sched_suspend()Ian Moffett
Introduce a new sched_suspend() function that allows the caller to suspend themselves (equivalent to a yield) for a specified amount of time described by a 'timeval'. Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Refactor recv() implIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
3 dayskernel: socket: Zero newly allocated 'ksock'Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
4 daysliboda: Add oda_movewin()Ian Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
4 dayslibgfx: draw: Add gfx_copy_region()Ian Moffett
This commit introduces a new gfx_copy_region() function that allows a rectangular region of the screen to be defined and its contents copied to a different part of the screen. Signed-off-by: Ian Moffett <ian@osmora.org>
4 dayslibgfx: draw: Add gfx_get_pix() functionIan Moffett
Introduce gfx routine to grab the RGB value of a specific pixel at a specific location on the screen. Signed-off-by: Ian Moffett <ian@osmora.org>
4 daysliboda: Add window cacheIan Moffett
Implement a window cache to avoid the overhead of back-to-back calls for malloc() and free. This commit additionally introduces a new oda_shutdown() function for cleaning up the library. Signed-off-by: Ian Moffett <ian@osmora.org>
5 daysdocs: liboda: Add input management sectionIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>