summaryrefslogtreecommitdiff
path: root/Kernel/Memory/ScopedAddressSpaceSwitcher.h
blob: d5470729314c5537b1c0b8135496a49fe2adb207 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/*
 * Copyright (c) 2020-2021, Andreas Kling <kling@serenityos.org>
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */

#pragma once

#include <AK/Types.h>
#include <Kernel/Forward.h>

namespace Kernel {

class ScopedAddressSpaceSwitcher {
public:
    explicit ScopedAddressSpaceSwitcher(Process&);
    ~ScopedAddressSpaceSwitcher();

private:
    u32 m_previous_cr3 { 0 };
};

}