Age | Commit message (Collapse) | Author |
|
On certain embedded controllers (ECs) like the EC present on the
Thinkpad T420s, writes to the i8042 controller configuration byte
are not very liked by the EC internal logic and thus result in them
asserting an NMI as a certain host bus error. To workaround this, Hyra
falls back to polling on these specific devices. Previously, Hyra did not
have DMI/SMBIOS capabilities and therefore had to rely on assuming *all*
Lenovo devices were "hostile". As of now since we are capable grabbing
the product version from DMI, we can target specific devices like the
T420s and this commit provides that logic.
This commit additionally implements logic to enable interrupts on PS/2
port 0 (aka the keyboard).
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Before the Hyra kernel starts up, the Limine bootloader creates a
mapping of the first 4 GiB of memory (identity mapped for base revisions
of zero and mapped to the HDDM on higher base revisions). However, it
usually will create a huge mapping over this which would be problematic
during remaps of device MMIO base addresses as they typically reside at
the 4 GiB region of RAM and as of this commit, huge pages are not a
supported feature of the Hyra AMD64 pmap layer.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
The function md_td_kick() is only used for user threads and there is no
need reference any kernel segments. Furthermore, the previous code would
introduce a bug where rpl would always be 0.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
During an exit(), the parent needs to kill all of the child processes
that depend on it. However, there might be an occurrence where one or
more is already exiting and trying to kill such processes would be
problematic and may result in issues like double frees. This commit
ensures that the exiting parent only kills child processes that aren't
already exiting themselves.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
MAP_ANON does not need to be treated as any specific flag bits as it
isn't even checked with mmap()
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
This commit implements EEPROM reading logic as well as some code to read
the ethernet address into a `netif' structure.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
The E1000 may add padding in-between registers and for the sake of
simplicity, we will deal with raw offsets instead of a silly structure.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
There will likely be multiple times the reference count of a ctlfs entry
will hit zero. Several programs may open and close a ctlfs node more
than once and as these are hardwired kernel objects, they must always
stay present. At the most we may set the vp->data field to NULL,
indicating that it is currently unused.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Allow the intr_hand structure to carry driver specific and interrupt
related data so that it can be passed to an interrupt handler when it
is invoked.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
- Implement pmap_map()
- Implement pmap_unmap()
- Implement pmap_read_vas()
- Implement pmap_switch_vas()
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
- Add handle_exception() as higher level logic to handle the exceptions
- Simplify frame.h
- Call C handler in vector.S
- Clean up stack after creating frame
- Add register dump on exception
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
- md_halt() -> md_hlt()
- Pass dummy operand
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Add SYS_sleep to put a thread to sleep for some time through a timespec
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
- Introduce timespec structure for nanosecond/second precision
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Introduce IEEE 802.3 related headers such as ones containing the
structure of an ethernet frame as well as its types. This commit
additionally introduces ARP request logic.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
This is no longer needed as the Hyra PMM now does this automatically by
default.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
To prevent a situation where there is a data race between one thread
freeing physical memory and one allocating physical memory. Do not
immediately reuse freed physical memory. Instead, keep allocating
upwards and once there is no more room, wrap the last_idx back to the
bitmap free index. We now also zero allocated physical memory for
security reasons.
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
Signed-off-by: Ian Moffett <ian@osmora.org>
|
|
- Flush the entire output buffer
- Wipe the whole screen with "bg"
- The entire console will now be cleared when a "\033[H" sequence is
encountered
Signed-off-by: Ian Moffett <ian@osmora.org>
|