mirror of
https://github.com/RGBCube/serenity
synced 2025-10-17 04:12:08 +00:00

This makes it clear in the code that these drivers are specific for the Raspberry Pi devices.
26 lines
464 B
C++
26 lines
464 B
C++
/*
|
|
* Copyright (c) 2021, Nico Weber <thakis@chromium.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#include <Kernel/Arch/aarch64/MainIdRegister.h>
|
|
#include <Kernel/Arch/aarch64/RPi/MMIO.h>
|
|
|
|
namespace Kernel::RPi {
|
|
|
|
MMIO::MMIO()
|
|
: m_base_address(0xFE00'0000)
|
|
{
|
|
MainIdRegister id;
|
|
if (id.part_num() <= MainIdRegister::RaspberryPi3)
|
|
m_base_address = 0x3F00'0000;
|
|
}
|
|
|
|
MMIO& MMIO::the()
|
|
{
|
|
static MMIO instance;
|
|
return instance;
|
|
}
|
|
|
|
}
|