RISC OS Open
A fast and easily customised operating system for ARM devices
ROOL
Home | News | Software | Bugs | Bounties | Forum | Documents | Photos | Contact us
Account

PCI_RAMAlloc

Programmer's Reference Manuals
» Part 15 – SWI Calls
» PCI
» PCI_RAMAlloc

PCI_RAMAlloc

(SWI &50390)
Entry
R0 Size required
R1 Alignment required (e.g. &1000 it must be 4K aligned – 0 if none)
R2 Boundary limitation (e.g. &10000 it mustn’t cross 64K boundary – 0 if none)
Exit
R0 Logical address
R1 PCI address
R2 Preserved ?

Use

The purpose of this call is to allocate memory from a fixed, contiguous memory pool, suitable for access by other bus masters.

Notes

This is provided for the convenience of drivers that only need a few simple data structures for communication with their PCI device, and don’t want the complexity of dealing with cache coherency, memory fragmentation and physical page moving (Service_PagesUnsafe et al).

Memory will be uncachable but bufferable – you must ensure that any writes you perform have taken place before another bus master reads the memory, by calling OS_MMUControl 1 with bit 29 of R0 set. The memory is not accessible from user mode.

See also

  • OS_MMUControl 1
  • PCI
  • Service_PagesUnsafe
Created on December 11, 2009 19:30:09 by Alan Robertson (52)? (127.0.0.1)
Edit | Views: Print | Source | Linked from: PCI SWI Calls, PCI_RAMFree

Search the Wiki

Commercial use

For commercial enquiries, please contact the owners of RISC OS, Castle Technology Ltd.

ROOL Store

The official C/C++ Development kit and more here.

Donate! Why?

Help ROOL make things happen – please consider donating!

Navigation

  • Home Page
  • All Pages
  • Recently Revised
  • Authors
  • Feeds
Site design © RISC OS Open Limited 2011 except where indicated
The RISC OS Open Instiki theme is based on Insitki's default layout

Valid XHTML 1.0  |  Valid CSS

Instiki 0.19.1(MML+)
This site runs on Rails

Hosted by Arachsys