Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

11 Commits

Folders and files

Repository files navigation

kernel-lp64

The kernel side of the Phorepoc 64-bit (LP64) port that both 64-bit architectures share: the changes the 2010 EKA2 kernel needs for 64-bit pointers, the kernel's reader of the 64-bit image format, and the ROM builder the 64-bit bootstraps include.

Nothing here is architecture code. The nanokernel back ends, the MMU code, the bootstraps and the board drivers live in the architecture repositories, which build the kernel with this repository laid over the Symbian source.

Layout

  • os/kernel/eka/ -- whole-file overlays of kernel/eka files of the pinned Symbian kernel source (oss.FCL.sf.os.kernelhwsrv at 0c3208650587ac0230aed8a74e9bddb5288023eb, core sources.lock), same relative paths. A 64-bit kernel build compiles a file from here when it exists, else the upstream file. The 32-bit builds never see this tree. The files are the upstream files with the LP64 changes applied once; each change carries an LP64 comment. They cover:
    • include/kernel, include/nkern, include/nkernsmp, include/memmodel, include/slab.h, include/dispchannel.inl: pointer-sized fields, the 64-bit exec tables, TPhysAddr as 64 bits, the 64-bit trap and message argument slots;
    • kernel/, klib/, nkern/, nkernsmp/: casts and fields that held a pointer in 32 bits;
    • memmodel/epoc/... (the flexible memory model): virtual addresses and page-table indexes in TLinAddr, the address-space allocator's slab masks, the code-segment export directory with 8-byte entries;
    • drivers/ (local media, ECOMM, EDISP, the shared-chunk sound LDD) and ewsrv/: the same kind of casts; drivers/display/display.cpp (the RDisplayChannel LDD): its physical addresses as TPhysAddr, not TUint32. drivers/pipe/dpipe.cpp + include/drivers/dpipe.h (the Open C pipe LDD): the same casts, operator new on TSizeT; drivers/camerasc/cameraldd.cpp: the shared-chunk camera LDD of the 2010 release's BRANCH_RCL_3, which the boards restore (it is not in the pinned kernel source), its int request arguments cast through TLinAddr.
  • os/symbian-2010/ -- whole-file overlays of kernel-side files of other packages, by their path under the symbian-2010 source tree: the Graphics Resource channel (graphicsresourceimplementation/src/sgchannel.cpp: EControlResourceDataAddress writes the 64-bit address to its second argument instead of returning it in the TInt result; core's LP64 copy of sgdevice.inl passes it) and the reference surface manager (surfacemgrcommon/src/extension.cpp, surfacemanagerdriver.cpp: physical addresses as TPhysAddr, page lists and kernel addresses at their LP64 types, int arguments through TLinAddr).
  • os/symbian-rcl3/ -- the same for files of the symbian-rcl3 source tree: the WLAN logical device (oss.FCL.sf.os.wlan: wlan_bearer/wlanldd, the UMAC, OSA and LDD, and the wlan_plat/wlan_hal_api types). TPacketId is pointer-sized (the UMAC passes a pointer as the packet id); the OSA heap's placement new takes size_t, its hardware-chunk id is the chunk's address as a TLinAddr; the frame transfer block's own addresses are TLinAddr (the block is shared kernel/user memory, both sides 64-bit); the Rx buffer lists stay 32-bit offsets from the Rx chunk. The EControlFastAllocTxBuffer fast control returns the Tx meta header's offset from the transfer block in its TInt result (never 0: the block's queues come first) and RPcmNetCardIf::AllocTxBuffer adds the block's user address back.
  • os/kernel/lp64/p64loader.cpp, p64loader.h -- the kernel-side reader of P64Image (the LP64 variant of E32Image that the pdk's tools/emitter/p64image.py writes): header checks, the 64-bit relocations, the 8-byte export directory, import resolution.
  • os/kernel/lp64/p64rom.inc -- the ROM builder: it turns the PORF file list (the pdk's tools/p64rom.py) into the ROM header, the XIP-relocated images and the ROM file system. A bootstrap includes it and provides the ROM area, the console output and Die(); a board with devices linked into the kernel defines Lp64BuiltinDevice().

The user-visible kernel headers (include/e32*.h, u32*.h), common/ and euser/ are not here: they belong to the user-side type model in core (os/toolchain/shims/lp64_eka), and the kernel build takes them from there.

Licence

The overlays are Nokia's files with Phorepoc's changes and keep Nokia's notice; see NOTICE and LICENSES/. Phorepoc's own files are EPL-2.0 OR GPL-2.0-or-later.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages