arch/arm/mach-omap2/pdata-quirks.c
Source file repositories/reference/linux-study-clean/arch/arm/mach-omap2/pdata-quirks.c
File Facts
- System
- Linux kernel
- Corpus path
arch/arm/mach-omap2/pdata-quirks.c- Extension
.c- Size
- 16030 bytes
- Lines
- 577
- Domain
- Architecture Layer
- Bucket
- arch/arm
- Inferred role
- Architecture Layer: implementation source
- Status
- source implementation candidate
Why This File Exists
CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- CPU and platform-specific kernel glue: boot entry, traps, syscall entry, interrupts, page tables, context switch, and low-level barriers.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/clk.hlinux/davinci_emac.hlinux/gpio/machine.hlinux/gpio/consumer.hlinux/init.hlinux/kernel.hlinux/of_platform.hlinux/mmc/card.hlinux/mmc/host.hlinux/power/smartreflex.hlinux/regulator/machine.hlinux/regulator/fixed.hlinux/platform_data/pinctrl-single.hlinux/platform_data/hsmmc-omap.hlinux/platform_data/iommu-omap.hlinux/platform_data/ti-sysc.hlinux/platform_data/wkup_m3.hlinux/platform_data/asoc-ti-mcbsp.hlinux/platform_data/ti-prm.hclockdomain.hcommon.hcommon-board-devices.hcontrol.homap_device.homap-secure.hsoc.h
Detected Declarations
struct pdata_initfunction omap2420_n8x0_legacy_initfunction omap3_gpio126_127_129function hsmmc2_internal_input_clkfunction omap3_sbc_t3x_usb_hub_initfunction omap3_sbc_t3730_legacy_initfunction omap3_sbc_t3530_legacy_initfunction omap3_evm_legacy_initfunction am35xx_enable_emac_intfunction am35xx_disable_emac_intfunction am35xx_emac_resetfunction omap3_sbc_t3517_wifi_initfunction omap3_sbc_t3517_legacy_initfunction am3517_evm_legacy_initfunction nokia_n900_legacy_initfunction omap3_tao3530_legacy_initfunction omap3_logicpd_torpedo_initfunction omap3_pandora_legacy_initfunction clkdm_deny_idlefunction ti_sysc_clkdm_deny_idlefunction ti_sysc_clkdm_allow_idlefunction ti_sysc_enable_modulefunction ti_sysc_idle_modulefunction ti_sysc_shutdown_modulefunction ti_sysc_soc_type_gpfunction omap_pcs_legacy_initfunction omap3_mcbsp_initfunction omap3_mcbsp_initfunction pdata_quirks_checkfunction pdata_quirks_init_clocksfunction pdata_quirks_init
Annotated Snippet
struct pdata_init {
const char *compatible;
void (*fn)(void);
};
static struct of_dev_auxdata omap_auxdata_lookup[];
#ifdef CONFIG_MACH_NOKIA_N8X0
static void __init omap2420_n8x0_legacy_init(void)
{
omap_auxdata_lookup[0].platform_data = n8x0_legacy_init();
}
#else
#define omap2420_n8x0_legacy_init NULL
#endif
#ifdef CONFIG_ARCH_OMAP3
/*
* Configures GPIOs 126, 127 and 129 to 1.8V mode instead of 3.0V
* mode for MMC1 in case bootloader did not configure things.
* Note that if the pins are used for MMC1, pbias-regulator
* manages the IO voltage.
*/
static void __init omap3_gpio126_127_129(void)
{
u32 reg;
reg = omap_ctrl_readl(OMAP343X_CONTROL_PBIAS_LITE);
reg &= ~OMAP343X_PBIASLITEVMODE1;
reg |= OMAP343X_PBIASLITEPWRDNZ1;
omap_ctrl_writel(reg, OMAP343X_CONTROL_PBIAS_LITE);
if (cpu_is_omap3630()) {
reg = omap_ctrl_readl(OMAP34XX_CONTROL_WKUP_CTRL);
reg |= OMAP36XX_GPIO_IO_PWRDNZ;
omap_ctrl_writel(reg, OMAP34XX_CONTROL_WKUP_CTRL);
}
}
static void __init hsmmc2_internal_input_clk(void)
{
u32 reg;
reg = omap_ctrl_readl(OMAP343X_CONTROL_DEVCONF1);
reg |= OMAP2_MMCSDIO2ADPCLKISEL;
omap_ctrl_writel(reg, OMAP343X_CONTROL_DEVCONF1);
}
#ifdef CONFIG_OMAP_HWMOD
static struct iommu_platform_data omap3_iommu_pdata = {
.reset_name = "mmu",
.assert_reset = omap_device_assert_hardreset,
.deassert_reset = omap_device_deassert_hardreset,
.device_enable = omap_device_enable,
.device_idle = omap_device_idle,
};
static struct iommu_platform_data omap3_iommu_isp_pdata = {
.device_enable = omap_device_enable,
.device_idle = omap_device_idle,
};
#endif
static void __init omap3_sbc_t3x_usb_hub_init(char *hub_name, int idx)
{
struct gpio_desc *d;
/* This asserts the RESET line (reverse polarity) */
d = gpiod_get_index(NULL, "reset", idx, GPIOD_OUT_HIGH);
if (IS_ERR(d)) {
pr_err("Unable to get T3x USB reset GPIO descriptor\n");
return;
}
gpiod_set_consumer_name(d, hub_name);
gpiod_export(d, 0);
udelay(10);
/* De-assert RESET */
gpiod_set_value(d, 0);
msleep(1);
}
static struct gpiod_lookup_table omap3_sbc_t3x_usb_gpio_table = {
.dev_id = NULL,
.table = {
GPIO_LOOKUP_IDX("gpio-160-175", 7, "reset", 0,
GPIO_ACTIVE_LOW),
{ }
},
};
static void __init omap3_sbc_t3730_legacy_init(void)
Annotation
- Immediate include surface: `linux/clk.h`, `linux/davinci_emac.h`, `linux/gpio/machine.h`, `linux/gpio/consumer.h`, `linux/init.h`, `linux/kernel.h`, `linux/of_platform.h`, `linux/mmc/card.h`.
- Detected declarations: `struct pdata_init`, `function omap2420_n8x0_legacy_init`, `function omap3_gpio126_127_129`, `function hsmmc2_internal_input_clk`, `function omap3_sbc_t3x_usb_hub_init`, `function omap3_sbc_t3730_legacy_init`, `function omap3_sbc_t3530_legacy_init`, `function omap3_evm_legacy_init`, `function am35xx_enable_emac_int`, `function am35xx_disable_emac_int`.
- Atlas domain: Architecture Layer / arch/arm.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.