29.11.2014 Views

Fast Models Reference Manual - ARM Information Center

Fast Models Reference Manual - ARM Information Center

Fast Models Reference Manual - ARM Information Center

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Peripheral and Interface Components<br />

Memory is stored in blocks of at least 4KB, so the returned pointer can access all<br />

memory within a block. If a limit pointer is provided, it is used to return the<br />

device address corresponding to the limit of the current block.<br />

The pointer value returned is not guaranteed to remain valid indefinitely. Bus<br />

activities, or other calls to the control port, might invalidate the pointer.<br />

provideReadStorage(pv::bus_addr_t base, pv::bus_addr_t limit, const uint8_t * storage),<br />

provideReadWriteStorage(pv::bus_addr_t base,pv::bus_addr_t limit, uint8_t * storage)<br />

These methods enables you to allocate blocks of memory that the PVBusSlave<br />

can use to manage regions of RAM/ROM. Only use these methods when you<br />

require a high degree of control over memory, such as when you need a device to<br />

map specific regions of host memory into the simulation.<br />

You must align base (inclusive) and limit (exclusive) values to 4KB page<br />

addresses within device address space. The memory region pointed to by storage<br />

must be large enough to contain (limit - base) bytes.<br />

After these calls, PVBusSlave controls access to the underlying memory. The<br />

owner must call getWriteStorage() before modifying the memory contents and<br />

getReadStorage() before reading the memory contents.<br />

pv::accessMode values<br />

The values assigned to pv::accessMode control what happens when an address is accessed. Legal<br />

values for the enumeration are:<br />

pv::ACCESSMODE_MEMORY<br />

Act as memory. The PVBusSlave manages the underlying storage to provide 4KB<br />

of memory, which can be ROM or RAM, depending on how you configure it to<br />

handle bus write transactions.<br />

pv::ACCESSMODE_DEVICE<br />

Act as a device. Requests to the select pages are routed to the PVBusSlave device<br />

port, where the necessary behavior can be implemented by the component.<br />

pv::ACCESSMODE_ABORT<br />

Generate bus abort signals for any accesses to this page.<br />

pv::ACCESSMODE_IGNORE<br />

Ignore accesses to this page. Bus read requests return 0.<br />

Parameters<br />

Table 5-6 provides a description of the configuration parameters for the PVBusSlave<br />

component.<br />

Table 5-6 PVBusSlave configuration parameters<br />

Parameter<br />

name<br />

Description<br />

Type<br />

Allowed<br />

value<br />

Default<br />

value<br />

size<br />

Addressable size of<br />

the device in bytes.<br />

Must be a multiple<br />

of 0x1000 (4KB).<br />

uint64_t 4KB to 4GB 0x10000000<br />

(256MB)<br />

<strong>ARM</strong> DUI 0423J Copyright © 2008-2011 <strong>ARM</strong>. All rights reserved. 5-11<br />

ID051811<br />

Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!