docs

Navigating around the downstream kernel (BCM21664/BCM23550 Samsung 3.4 release)

This guide applies to the known kernels for the Galaxy Grand Neo, Trend Plus and Core Plus. These are all kernel version 3.4.5.

Board files and device info

Board files for all the devices are located in arch/arm/mach-hawaii (mach-java for BCM23550), and are prefixed with board-ss_. They usually contain plenty of unused peripherals, so always double-check if the peripheral you’re looking at is actually enabled (usually there’s kernel config options you can cross-reference). Some devices are also defined in the devices.c file in the mach-{hawaii/java} directory.

Some structs to look out for:

There are also plenty of addresses for various peripherals stored in arch/arm/mach-{hawaii/java}/include/mach/rdb/brcm_rdb_sysmap.h.

Clocks

Clock data is stored in the clock.c file in the mach directory. Each clock has the following structs:

Some values to look out for:

These values are usually stored in rdb header files; a quick grep -iR in the mach directory should point you towards the right file. A lot of values are stored in arch/arm/mach-{hawaii/java}/include/mach/rdb/brcm_rdb_kps_clk_mgr_reg.h (slave clocks) or brcm_rdb_kpm_clk_mgr_reg.h (master clocks).

Note that downstream uses masks, and mainline uses bits; thankfully, bits are stored alongside masks in the appropriate header files, and masks on mainline are generated by the driver when needed.

plat-kona drivers

The arch/arm/plat-kona directory contains various core platform-related drivers: the SMP driver, clock driver, and some other drivers we don’t yet understand.