RISC OS Open
Safeguarding the past, present and future of RISC OS for everyone
ROOL
Home | News | Downloads | Bugs | Bounties | Forum | Documents | Photos | Contact us
Account

Memory Page Access Flags (changes)

Showing changes from revision #7 to #8: Added | Removed | Changed

OS SWI Calls
» OS_ReadMemMapEntries
» Memory Map Request Block
» Memory Page Access Flags

Memory Page Access Flags

The page access flags used below are used by the OS_DynamicArea, OS_Memory, and the OS_SetMemMapEntries group of SWIs. However, when using calls to modify the access of pages, be aware that not all APIs support all types of flags. Specifying an unsupported flag can lead to malfunction. Also note that this page only lists the flags supported by RISC OS 5 and its predecessors; for information on RISC OS 4 and 6, please see ROL’s documentation.

  • For OS_DynamicArea, see Dynamic Area Flags for the full list of flags that are available for dynamic areas.
  • For the OS_SetMemMapEntries group of SWIs, consult the table below to determine which flags are supported.
  • For OS_Memory, consult the details of the individual reason code to determine which flags are supported.
Bit Meaning OS version Notes
0-3 Access privileges to be given to each page in the area Arthur
4 Set if area is not bufferable by chips 3.50 1
5 Set if area is not cacheable by chips 3.50 1
6 If set, area is doubly mapped (reserved, OS use only), otherwise area is singly mapped 3.50 2
7-11 7 Reserved Page (must has be been zero) reserved5.27 3
8-11 Reserved (must be zero)
12-14 Cache policy 5.00
15-31 Reserved (must be zero)

Notes

Prior to RISC OS 5.00, OS_ReadMemMapEntries and OS_FindMemMapEntries would return all of the flags for a given page, but OS_SetMemMapEntries would only pay attention to the bottom two bits and clear the rest to zero. With RISC OS 5.00 this behaviour was fixed so that the full set of flags are used.

1 Advice on bits 4 & 5

Setting flags such that r4 bit 4 is 1 and bit 5 is 0 (area is cacheable but not bufferable) has different meanings depending on the operating system version. On RISC OS 5 it selects a non-merging write-through or write-back cache policy. On other operating system versions it is unsupported and must not be used.

2 Doubly mapped regions

Using OS_SetMemMapEntries to set a page as doubly mapped is not supported and will result in the page tables being incorrectly modified.

3 Reserved pages

This flag is read-only via OS_SetMemMapEntries. The only API which can modify its state is OS_Memory 23. See the OS_Memory 23 documentation for more details on the behaviour of reserved pages.

See also

  • Dynamic Area Flags
  • Memory Map Request Block
  • Memory Cache Policies
  • OS_FindMemMapEntries
  • OS_ReadMemMapEntries
  • OS_SetMemMapEntries
  • OS_DynamicArea
  • OS_Memory
Revised on November 25, 2019 21:44:33 by Jeffrey Lee (213) (109.152.28.242)
Edit | Back in time (7 revisions) | Hide changes | History | Views: Print | Source | Linked from: Memory Map Request Block, PCI_HardwareAddress Input Flags, Memory Map Page Access, Dynamic Area Flags, Kernel notes, OS_DynamicArea 22, OS_DynamicArea 25, OS_Memory 23

Search the Wiki

Social

Follow us on and

ROOL Store

Buy RISC OS Open merchandise here, including SD cards for Raspberry Pi and more.

Donate! Why?

Help ROOL make things happen – please consider donating!

RISC OS IPR

RISC OS is an Open Source operating system owned by RISC OS Developments Ltd and licensed primarily under the Apache 2.0 license.

Navigation

  • Home Page
  • All Pages
  • Recently Revised
  • Authors
  • Feeds
Site design © RISC OS Open Limited 2018 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