E820.py revision 7087
16928SBrad.Beckmann@amd.com# Copyright (c) 2008 The Hewlett-Packard Development Company
26928SBrad.Beckmann@amd.com# All rights reserved.
36928SBrad.Beckmann@amd.com#
46928SBrad.Beckmann@amd.com# The license below extends only to copyright in the software and shall
56928SBrad.Beckmann@amd.com# not be construed as granting a license to any other intellectual
66928SBrad.Beckmann@amd.com# property including but not limited to intellectual property relating
76928SBrad.Beckmann@amd.com# to a hardware implementation of the functionality of the software
86928SBrad.Beckmann@amd.com# licensed hereunder.  You may use the software subject to the license
96928SBrad.Beckmann@amd.com# terms below provided that you ensure that this notice is replicated
106928SBrad.Beckmann@amd.com# unmodified and in its entirety in all distributions of the software,
116928SBrad.Beckmann@amd.com# modified or unmodified, in source code or in binary form.
126928SBrad.Beckmann@amd.com#
136928SBrad.Beckmann@amd.com# Redistribution and use in source and binary forms, with or without
146928SBrad.Beckmann@amd.com# modification, are permitted provided that the following conditions are
156928SBrad.Beckmann@amd.com# met: redistributions of source code must retain the above copyright
166928SBrad.Beckmann@amd.com# notice, this list of conditions and the following disclaimer;
176928SBrad.Beckmann@amd.com# redistributions in binary form must reproduce the above copyright
186928SBrad.Beckmann@amd.com# notice, this list of conditions and the following disclaimer in the
196928SBrad.Beckmann@amd.com# documentation and/or other materials provided with the distribution;
206928SBrad.Beckmann@amd.com# neither the name of the copyright holders nor the names of its
216928SBrad.Beckmann@amd.com# contributors may be used to endorse or promote products derived from
226928SBrad.Beckmann@amd.com# this software without specific prior written permission.
236928SBrad.Beckmann@amd.com#
246928SBrad.Beckmann@amd.com# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
256928SBrad.Beckmann@amd.com# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
266928SBrad.Beckmann@amd.com# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
276928SBrad.Beckmann@amd.com# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
286928SBrad.Beckmann@amd.com# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
296928SBrad.Beckmann@amd.com# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
306928SBrad.Beckmann@amd.com# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
316928SBrad.Beckmann@amd.com# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
326928SBrad.Beckmann@amd.com# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
336928SBrad.Beckmann@amd.com# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
346928SBrad.Beckmann@amd.com# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
356928SBrad.Beckmann@amd.com#
366928SBrad.Beckmann@amd.com# Authors: Gabe Black
376928SBrad.Beckmann@amd.com
386928SBrad.Beckmann@amd.comfrom m5.params import *
396928SBrad.Beckmann@amd.comfrom m5.SimObject import SimObject
406928SBrad.Beckmann@amd.com
416928SBrad.Beckmann@amd.comclass X86E820Entry(SimObject):
426928SBrad.Beckmann@amd.com    type = 'X86E820Entry'
436928SBrad.Beckmann@amd.com    cxx_class = 'X86ISA::E820Entry'
446928SBrad.Beckmann@amd.com
456928SBrad.Beckmann@amd.com    addr = Param.Addr(0, 'address of the beginning of the region')
467034SBrad.Beckmann@amd.com    size = Param.MemorySize('0B', 'size of the region')
477034SBrad.Beckmann@amd.com    range_type = Param.UInt64('type of the region')
486928SBrad.Beckmann@amd.com
496928SBrad.Beckmann@amd.comclass X86E820Table(SimObject):
506928SBrad.Beckmann@amd.com    type = 'X86E820Table'
516928SBrad.Beckmann@amd.com    cxx_class = 'X86ISA::E820Table'
526928SBrad.Beckmann@amd.com
536928SBrad.Beckmann@amd.com    entries = VectorParam.X86E820Entry([], 'entries for the e820 table')
546928SBrad.Beckmann@amd.com