Device.py (13892:0182a0601f66) Device.py (13930:c5e728ccd2e2)
1# Copyright (c) 2012-2016 ARM Limited
2# All rights reserved.
3#
4# The license below extends only to copyright in the software and shall
5# not be construed as granting a license to any other intellectual
6# property including but not limited to intellectual property relating
7# to a hardware implementation of the functionality of the software
8# licensed hereunder. You may use the software subject to the license

--- 70 unchanged lines hidden (view full) ---

79 pio_latency = Param.Latency('100ns', "Programmed IO latency")
80
81class DmaDevice(PioDevice):
82 type = 'DmaDevice'
83 cxx_header = "dev/dma_device.hh"
84 abstract = True
85 dma = MasterPort("DMA port")
86
1# Copyright (c) 2012-2016 ARM Limited
2# All rights reserved.
3#
4# The license below extends only to copyright in the software and shall
5# not be construed as granting a license to any other intellectual
6# property including but not limited to intellectual property relating
7# to a hardware implementation of the functionality of the software
8# licensed hereunder. You may use the software subject to the license

--- 70 unchanged lines hidden (view full) ---

79 pio_latency = Param.Latency('100ns', "Programmed IO latency")
80
81class DmaDevice(PioDevice):
82 type = 'DmaDevice'
83 cxx_header = "dev/dma_device.hh"
84 abstract = True
85 dma = MasterPort("DMA port")
86
87 sid = Param.Unsigned(0,
88 "Stream identifier used by an IOMMU to distinguish amongst "
89 "several devices attached to it")
90 ssid = Param.Unsigned(0,
91 "Substream identifier used by an IOMMU to distinguish amongst "
92 "several devices attached to it")
87
93
94
88class IsaFake(BasicPioDevice):
89 type = 'IsaFake'
90 cxx_header = "dev/isa_fake.hh"
91 pio_size = Param.Addr(0x8, "Size of address range")
92 ret_data8 = Param.UInt8(0xFF, "Default data to return")
93 ret_data16 = Param.UInt16(0xFFFF, "Default data to return")
94 ret_data32 = Param.UInt32(0xFFFFFFFF, "Default data to return")
95 ret_data64 = Param.UInt64(0xFFFFFFFFFFFFFFFF, "Default data to return")
96 ret_bad_addr = Param.Bool(False, "Return pkt status bad address on access")
97 update_data = Param.Bool(False, "Update the data that is returned on writes")
98 warn_access = Param.String("", "String to print when device is accessed")
99 fake_mem = Param.Bool(False,
100 "Is this device acting like a memory and thus may get a cache line sized req")
101
102class BadAddr(IsaFake):
103 pio_addr = 0
104 ret_bad_addr = Param.Bool(True, "Return pkt status bad address on access")
105
106
95class IsaFake(BasicPioDevice):
96 type = 'IsaFake'
97 cxx_header = "dev/isa_fake.hh"
98 pio_size = Param.Addr(0x8, "Size of address range")
99 ret_data8 = Param.UInt8(0xFF, "Default data to return")
100 ret_data16 = Param.UInt16(0xFFFF, "Default data to return")
101 ret_data32 = Param.UInt32(0xFFFFFFFF, "Default data to return")
102 ret_data64 = Param.UInt64(0xFFFFFFFFFFFFFFFF, "Default data to return")
103 ret_bad_addr = Param.Bool(False, "Return pkt status bad address on access")
104 update_data = Param.Bool(False, "Update the data that is returned on writes")
105 warn_access = Param.String("", "String to print when device is accessed")
106 fake_mem = Param.Bool(False,
107 "Is this device acting like a memory and thus may get a cache line sized req")
108
109class BadAddr(IsaFake):
110 pio_addr = 0
111 ret_bad_addr = Param.Bool(True, "Return pkt status bad address on access")
112
113