mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 13:47:45 +00:00
Kernel: Enable SMAP protection on IRQ and exception entry
It would be nice to do this in the assembly code, but we have to check if the feature is available before doing a CLAC, so I've put this in the C++ code for now.
This commit is contained in:
parent
fe9680f0a4
commit
372f9e9a11
2 changed files with 6 additions and 0 deletions
|
@ -38,6 +38,7 @@ static u32 s_seconds_since_boot;
|
|||
|
||||
void timer_interrupt_handler(RegisterDump regs)
|
||||
{
|
||||
clac();
|
||||
IRQHandlerScope scope(IRQ_TIMER);
|
||||
if (++s_ticks_this_second >= TICKS_PER_SECOND) {
|
||||
// FIXME: Synchronize with the RTC somehow to prevent drifting apart.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue