blob: 7e111a764e632af22f5766312cb4c772088e5d74 [file] [log] [blame]
Nico Huber5e9b1b52016-10-08 22:09:33 +02001--
2-- Copyright (C) 2016 secunet Security Networks AG
3--
4-- This program is free software; you can redistribute it and/or modify
5-- it under the terms of the GNU General Public License as published by
Nico Huberaab715f2016-10-18 00:22:25 +02006-- the Free Software Foundation; either version 2 of the License, or
7-- (at your option) any later version.
Nico Huber5e9b1b52016-10-08 22:09:33 +02008--
9-- This program is distributed in the hope that it will be useful,
10-- but WITHOUT ANY WARRANTY; without even the implied warranty of
11-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12-- GNU General Public License for more details.
13--
14
15package body HW.MMIO_Range
16with
17 Refined_State =>
18 (State => MMIO,
19 Base_Address => null)
20is
21
22 MMIO : Array_T with Volatile, Address => System'To_Address (Base_Addr);
23
24 procedure Read (Value : out Element_T; Index : in Index_T) is
25 begin
26 Value := MMIO (Index);
27 end Read;
28
29 procedure Write (Index : in Index_T; Value : in Element_T) is
30 begin
31 MMIO (Index) := Value;
32 end Write;
33
34 procedure Set_Base_Address (Base : Word64) is null;
35
36end HW.MMIO_Range;