genode/repos/base-hw/src/core/spec/x86_64/platform_support.cc
Reto Buerki 2a0b6fb541 hw_x86_64: Factor out _core_only_mmio_regions function
Move the _core_only_mmio_regions function to the
x86_64/platform_support.cc file. This is required to make it overridable
for other platforms deriving from x86.
2015-08-21 11:00:59 +02:00

29 lines
678 B
C++

/*
* \brief Platform implementations specific for x86_64
* \author Reto Buerki
* \date 2015-05-04
*/
/*
* Copyright (C) 2015 Genode Labs GmbH
*
* This file is part of the Genode OS framework, which is distributed
* under the terms of the GNU General Public License version 2.
*/
/* core includes */
#include <platform.h>
#include <board.h>
using namespace Genode;
Native_region * Platform::_core_only_mmio_regions(unsigned const i)
{
static Native_region _regions[] =
{
{ Board::MMIO_LAPIC_BASE, Board::MMIO_LAPIC_SIZE },
{ Board::MMIO_IOAPIC_BASE, Board::MMIO_IOAPIC_SIZE },
};
return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0;
}