Searched hist:e24c35737413c8626f9c4e8f47e33926b7ab7f23 (Results 1 – 2 of 2) sorted by relevance
/linux/arch/arm/mach-omap2/ |
H A D | prm.h | diff e24c35737413c8626f9c4e8f47e33926b7ab7f23 Sun Oct 21 09:01:11 CEST 2012 Paul Walmsley <paul@pwsan.com> ARM: OMAP2+: PRM: prepare for use of prm_ll_data function pointers
There are several PRM operations which behave similarly across OMAP2+ SoCs, but which have slight differences in their underlying implementations. For example, to fetch the SoC's last reset sources, different registers are read across OMAP2xxx, 3xxx, and 44xx, and different bits are used on each SoC. But the information returned is so similar that a single, common interface for drivers is useful.
This patch creates the support code for this function pointer registration process. No function pointers are included yet, but a subsequent patch will create one for the reset source API.
To illustrate the end goal with the above reset source example, each per-SoC driver will use its own low-level implementation function -- e.g., prm2xxx.c would contain omap2xxx_prm_read_reset_sources(). This function would read the appropriate register and remap the register bits to a standard set of reset source bits. When the prm2xxx.c driver is loaded, it would register this function with the common PRM driver, prm.c. prm.c would then export a common function, omap_prm_read_reset_sources(). Calling it would call through to the function pointer for the currently-registered SoC PRM driver. This will allow other drivers to use PRM-provided data and operations without needing to know which SoC is currently in use.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
|
H A D | prm_common.c | diff e24c35737413c8626f9c4e8f47e33926b7ab7f23 Sun Oct 21 09:01:11 CEST 2012 Paul Walmsley <paul@pwsan.com> ARM: OMAP2+: PRM: prepare for use of prm_ll_data function pointers
There are several PRM operations which behave similarly across OMAP2+ SoCs, but which have slight differences in their underlying implementations. For example, to fetch the SoC's last reset sources, different registers are read across OMAP2xxx, 3xxx, and 44xx, and different bits are used on each SoC. But the information returned is so similar that a single, common interface for drivers is useful.
This patch creates the support code for this function pointer registration process. No function pointers are included yet, but a subsequent patch will create one for the reset source API.
To illustrate the end goal with the above reset source example, each per-SoC driver will use its own low-level implementation function -- e.g., prm2xxx.c would contain omap2xxx_prm_read_reset_sources(). This function would read the appropriate register and remap the register bits to a standard set of reset source bits. When the prm2xxx.c driver is loaded, it would register this function with the common PRM driver, prm.c. prm.c would then export a common function, omap_prm_read_reset_sources(). Calling it would call through to the function pointer for the currently-registered SoC PRM driver. This will allow other drivers to use PRM-provided data and operations without needing to know which SoC is currently in use.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
|