Support permanent mapping of IO above 4GB using supersections
Ben Avison authored
This is facilitated by two extended calls. From the HAL:
* RISCOS_MapInIO64 allows the physical address to be specified as 64-bit

From the OS:
* OS_Memory 21 acts like OS_Memory 13, but takes a 64-bit physical address

There is no need to extend RISCOS_LogToPhys, instead we change its return
type to uint64_t. Any existing HALs will only read the a1 register, thereby
narrowing the result to 32 bits, which is fine because all existing HALs
only expected a 32-bit physical address space anyway.

Internally, RISCOS_MapInIO has been rewritten to detect and use supersections
for IO regions that end above 4GB. Areas that straddle the 4GB boundary should
also work, although if you then search for a sub-area that doesn't, it won't
find a match and will instead map it in again using vanilla sections - this is
enough of an edge case that I don't think we need to worry about it too much.

The rewrite also conveniently fixes a bug in the old code: if the area being
mapped in went all the way up to physical address 0xFFFFFFFF (inclusive) then
only the first megabyte of the area was actually mapped in due to a loop
termination issue.

Requires RiscOS/Sources/Programmer/HdrSrc!2
9024d1f6
Name Last commit Last update
..
AMBControl Implement support for cacheable pagetables
PMF Various kernel cleanups
vdu Move former ControlList_Interlaced item into SyncPol flags
ARM600 Implement support for cacheable pagetables
ARMops Fix dodgy ranged ICache cleans when using ARMv7MP ARMops
Arthur2 Fix incorrect OS_SynchroniseCodeAreas call
Arthur3 Attempt to tidy up substitute screen mode selection logic
ArthurSWIs Increase number of vectors supported by the kernel to 96.
CPUFeatures Revise comments - it's multiprocessing extensions, not virtualisation
ChangeDyn Simplify initial AplSpace claim
Convrsions Add UUID output formatter to conversions
Exceptions Implement support for cacheable pagetables
ExtraSWIs Fix global OS_SynchroniseCodeAreas. ARMop tweaks.
GetAll Attempt to tidy up substitute screen mode selection logic
HAL Support permanent mapping of IO above 4GB using supersections
HeapMan Delete lots of old switches
HeapSort Avoid unnecesssary remainder calculations
Kernel Support permanent mapping of IO above 4GB using supersections
LibKern More HAL work. IOMD HAL work in progress. Lots of my own little build scripts. Don't touch this.
MOSDict Import from cleaned 360 CD
MemInfo Support permanent mapping of IO above 4GB using supersections
MemMap2 Attempt to tidy up substitute screen mode selection logic
Middle Make it easier to debug aborts that were triggered by ABT/UND code
ModHand Unplug/RMInsert with podule module fix
MoreComms Resolve 2x header clashes
MoreSWIs
MsgCode
NewIRQs
NewReset
Oscli
SWINaming
Super1
SysComms
TickEvents
UnSqueeze
Utility
VMSAv6