io_device.hh revision 1310
12810SN/A/*
210693SMarco.Balboni@ARM.com * Copyright (c) 2004 The Regents of The University of Michigan
38856Sandreas.hansson@arm.com * All rights reserved.
48856Sandreas.hansson@arm.com *
58856Sandreas.hansson@arm.com * Redistribution and use in source and binary forms, with or without
68856Sandreas.hansson@arm.com * modification, are permitted provided that the following conditions are
78856Sandreas.hansson@arm.com * met: redistributions of source code must retain the above copyright
88856Sandreas.hansson@arm.com * notice, this list of conditions and the following disclaimer;
98856Sandreas.hansson@arm.com * redistributions in binary form must reproduce the above copyright
108856Sandreas.hansson@arm.com * notice, this list of conditions and the following disclaimer in the
118856Sandreas.hansson@arm.com * documentation and/or other materials provided with the distribution;
128856Sandreas.hansson@arm.com * neither the name of the copyright holders nor the names of its
138856Sandreas.hansson@arm.com * contributors may be used to endorse or promote products derived from
142810SN/A * this software without specific prior written permission.
152810SN/A *
162810SN/A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
172810SN/A * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
182810SN/A * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
192810SN/A * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
202810SN/A * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
212810SN/A * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
222810SN/A * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
232810SN/A * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
242810SN/A * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
252810SN/A * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
262810SN/A * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
272810SN/A */
282810SN/A
292810SN/A#ifndef __DEV_IO_DEVICE_HH__
302810SN/A#define __DEV_IO_DEVICE_HH__
312810SN/A
322810SN/A#include "mem/functional_mem/functional_memory.hh"
332810SN/A
342810SN/Aclass BaseInterface;
352810SN/Aclass Bus;
362810SN/Aclass HierParams;
372810SN/Aclass Platform;
382810SN/Atemplate <class BusType> class DMAInterface;
392810SN/A
402810SN/Aclass PioDevice : public FunctionalMemory
414458SN/A{
424458SN/A  protected:
432810SN/A    Platform *platform;
442810SN/A    BaseInterface *pioInterface;
452810SN/A    Tick pioLatency;
462810SN/A
472810SN/A  public:
482810SN/A    PioDevice(const std::string &name, Platform *p);
492810SN/A    virtual ~PioDevice();
5011051Sandreas.hansson@arm.com};
5111051Sandreas.hansson@arm.com
522810SN/Aclass DmaDevice : public PioDevice
537676Snate@binkert.org{
547676Snate@binkert.org  protected:
557676Snate@binkert.org    DMAInterface<Bus> *dmaInterface;
562810SN/A
572810SN/A  public:
582825SN/A    DmaDevice(const std::string &name, Platform *p);
592810SN/A    virtual ~DmaDevice();
602810SN/A};
616215Snate@binkert.org
628232Snate@binkert.org#endif // __DEV_IO_DEVICE_HH__
638232Snate@binkert.org