Share via


BSP and SOC Directory Layout (Windows Embedded CE 6.0)

1/5/2010

The board support package (BSP) and the system-on-chip (SOC) directory structures for the production-quality OAL parallel the Windows Embedded CE hardware library structure.

This parallel structure makes it is easier to browse and understand what hardware platforms are supported and allows you to quickly locate code that implements a particular hardware platform.

Note

The SOC directory is new for Windows Embedded CE 6.0. The contents of the Windows CE 5.0 CSP directory has been restructured and migrated to the SOC directory.

The following directories have been revised for the production-quality OAL model:

  • %_WINCEROOT%\Platform\<Hardware Platform Name>
    In the production-quality OAL model, the %_WINCEROOT%\Platform\<Hardware Platform Name> BSP directory contains only the following files and code:

    • Memory-mapped configuration files
    • Some include files that define the memory layout for the hardware platform that matches Config.bib
    • Some glue logic, which is board-level customization code that unites everything in the %_WINCEROOT%\Platform\Common directory
      The BSP directory layout is consistent for most BSPs.
  • %_WINCEROOT%\Platform\Common
    The code in the %_WINCEROOT%\Platform\Common directory contains the CPU-specific OAL routines.

    Note

    Any code that must include board descriptions or the way the board itself is laid out — such as interrupts, routing to traces, or the way the board makes use of the CPU — must be in the BSP directory, not in the %_WINCEROOT%\Platform\Common directory.

  • %_WINCEROOT%\Platform\Common\Src\SOC
    The system-on-a-chip (SOC) directory, %_WINCEROOT%\Public\Common\Src\SOC, contains a collection of system-on-a-chip (SOC), and CPU or chipset-level peripheral drivers. You can port the chipset driver for a core peripheral to any new hardware platform environment that makes use of the SOC or chipset without modification.

\Platform\&lt;Hardware Platform Name&gt;

For the production-quality OAL, each hardware platform directory contains the code you need to build the boot loader and the kernel image.

The following table shows the subdirectories under the %_WINCEROOT%\Platform\<Hardware Platform Name> directory.

\Platform\<Hardware Platform Name> subdirectory Description

Catalog

Contains the Platform Builder catalog pbcxml file.

Cesysgen

Contains a makefile for filtering any of the configuration files in the Files directory.

Files

Contains project-specific files for building the run-time image, initial directory structure, initialized databases, and initialized registry.

Src

Contains the boot loader, OAL, and include files for the hardware platform.

Src\Bootloader

Contains all the boot loader specific code.

Src\Bootloader\Eboot

Contains the boot loader source files.

Src\Common

Contains all the code common to the boot loader and OAL.

Src\Drivers

Contains the local BSP drivers.

Src\Inc

Contains hardware platform-specific include files.

Src\KITL

Contains build files, and possibly stub functions, for building a kernel with Kernel Independent Transport Layer (KITL) support.

Src\OAL

Contains the hardware platform-specific OAL code.

\Platform\Common

For the production-quality OAL, this directory contains entries for each processor family, the common OAL code, and the include files for the OAL components. The processor families are ARM, MIPS, and x86.

The %_WINCEROOT%\Platform\Common directory is divided by CPU architecture. Each CPU architecture directory is further divided into more specific architecture information, such as the CPU family or the CPU manufacturer. As you navigate down the directory tree, the directories become more CPU architecture-specific. For example, the ARM\ARM920T tree contains cache and data abort routines for the ARM920T CPU, and the ARM\ARM926 tree contains the cache routines for the ARM926 CPU. Code can also be inherited from the directories that are further up in the tree.

Although you might want to override some of the code in the %_WINCEROOT%\Platform\Common directory for performance reasons, overall, the code should work without modification. You do not have to copy any of the code in this directory unless necessary. Typically, you should include the library from the particular location in the %_WINCEROOT%\Platform\Common directory in your %_WINCEROOT%\Platform\<Hardware Platform Name> sources file.

The following table shows the subdirectories under the %_WINCEROOT%\Platform\Common directory.

\Platform\Common subdirectory Description

Lib

Contains libraries required to build your project.

The libraries are in directories with the following formats:

  • CPU\Debug
  • CPU\Retail

An example is: ARMV4I\Retail.

Ee479427.note(en-US,WinEmbedded.60).gifNote:
Do not include your custom libraries in this directory.

Src

Contains header files, common OAL code, and processor specific OAL code.

Src\ARM

Contains the ARM processor-specific OAL code.

Src\ARM\ARM920T

Contains all the CPU OAL code required for the ARM920T processor.

Src\ARM\ARM920T\Abort

Contains the abort routines specific to the ARM920T CPU.

Src\ARM\ARM920T\Cache

Contains the cache routines specific to the ARM920T CPU.

Src\ARM\ARM926

Contains the CPU OAL code required for the ARM926 processor.

Src\ARM\ARM926\Cache

Contains the cache routines specific to the ARM926 CPU.

Src\ARM\Common

Contains routines that are generic to ARM-based hardware platforms.

Src\ARM\Common\Boot

Contains boot routines that are common for all ARM CPUs.

Src\ARM\Common\Cache

Contains the cache routines that are common for all ARM CPUs.

Src\ARM\Common\Memory

Contains the memory translation routines that are common for all ARM CPUs.

The memory routines are used for translating physical addresses to physical addresses, and vice versa.

Src\ARM\Common\Misc

Contains miscellaneous routines that are common for all ARM CPUs.

Src\Common

Contains OAL code that is generic across all CPU architectures.

For more information about each of these components, see Production-Quality OAL Components.

Src\Common\Boot

Contains generic boot arguments.

Src\Common\Cache

Contains code for generic cache routines.

Src\Common\CEDDK

Contains code used for the Ceddk.dll library.

Src\Common\EthDrv

Contains code for the generic Ethernet drivers, which is used for debugging.

Src\Common\Flash

Contains generic flash memory code.

Src\Common\Ilt

Contains generic ILTiming code.

Src\Common\Intr

Contains interrupt code that is generic for all CPUs.

This contains code that performs translations between SYSINTRs and IRQs.

Src\Common\IO

Contains generic I/O routines for all CPUs.

Src\Common\IOCTL

Contains generic IOCTLs for all CPUs.

Src\Common\KITL

Contains code for generic KITL routines.

Src\Common\Log

Contains code used for logging.

Src\Common\Other

Contains miscellaneous generic routines.

Src\Common\PCI

Contains generic PCI routines.

Src\Common\PerReg

Contains generic performance register code.

Src\Common\Power

Contains generic power management code.

Src\Common\RTC

Contains generic RTC code.

Src\Common\Timer

Contains generic timer or system tick code.

Src\Common\Watson

Contains generic Windows Embedded CE Error Reporting code.

Src\Inc

Contains all the header files that export OAL components.

Ee479427.note(en-US,WinEmbedded.60).gifNote:
There is a single include file called Oal.h that includes all the other include files.

Src\MIPS

Contains the MIPS processor-specific OAL code.

Src\MIPS\Common

Contains routines that are generic to MIPS-based hardware platforms.

Src\MIPS\Inc

Contains include files that are generic to all MIPS CPUs.

Src\MIPS\MIPS32

Contains all the CPU OAL code required for the MIPS32 processor.

Src\SOC

Contains a collection of system-on-chip (SOC), and CPU or chipset-level peripheral drivers

Src\x86

Contains the x86 processor specific OAL code.

Src\x86\Common

Contains routines that are generic to x86-based hardware platforms.

Src\x86\Inc

Contains include files that are generic to all x86 CPUs.

\Platform\Common\Src\SOC

For the production-quality OAL, the SOC or chipset drivers are in a common directory along with an organized array of include files that describe the register layouts and common hardware definitions. SOC drivers and BSP code share the same include files, which are under the SOC or chipset model's Inc subdirectory.

The SOC directory structure, under the %_WINCEROOT%\Platform\Common\Src directory, has the format SOC\<SOC or Chipset Model>_<vendor name>_<version>\<Driver Function>.

For more information, see SOC Drivers.

OEMs can ship code in the \Platform\Common\Src\SOC directory structure, in addition to the \Platform\<Hardware Platform Name> directory. The SOC directory structure should be used for chipset-specific code which is fit for re-use. For best practices, see BSP Directory Rearchitecture Porting and Best Practices.

See Also

Concepts

Production-Quality OAL
Device Driver Libraries