omap sram, omap4 control module and es2.0 support
cover omap sram, omap4 control module and es2.0 support
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
The series contains
- SRAM mapping fixes to avoid speculative aborts
- omap4 control module support
- Fixes for omap4 HS/GP detection
- omap4 es2.0 fixes. MMC and ethernet fixes are queued in respective trees
Boot tested with omap3_defconfig on
- OMAP4430 SPP
- OMAP4 Panda
- OMAP4 Blaze
- OMAP3430 SDP
The following changes since commit 03a7ab083e4d619136d6f07ce70fa9de0bc436fc:
Linus Torvalds (1):
Merge git://git.kernel.org/.../sfrench/cifs-2.6
are available in the git repository at:
git://dev.omapzoom.org/pub/scm/santosh/kernel-omap4-base.git omap_for_2.6.37
David Anders (1):
omap4: Panda: Add DEBUG_LL support
Santosh Shilimkar (11):
ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
omap: Map only available sram memory
davinci: map sram using MT_MEMORY_NONCACHED instead of MT_DEVICE
omap4: control: Add ctrl_pad_base to omap_globals
omap4: control: Add accessor api's for pad control module
omap4: control: Add the register definition headers
omap4: control: Fix the control module register accesses
omap4: Update id.c and cpu.h for es2.0
omap4: Fix silicon version detection for early samples
omap4: l2x0: Fix init parameter for es2.0
omap4: Fix bootup crash observed with higher CPU clocks
Vikram Pandita (2):
omap: sram: fix is_sram_locked check
omap4: sram: Fix start address
arch/arm/mach-davinci/dm355.c | 3 +- arch/arm/mach-davinci/dm365.c | 3 +- arch/arm/mach-davinci/dm644x.c | 3 +- arch/arm/mach-davinci/dm646x.c | 3 +- arch/arm/mach-omap2/control.c | 25 + arch/arm/mach-omap2/hsmmc.c | 67 +- arch/arm/mach-omap2/id.c | 40 +- .../include/mach/ctrl_module_core_44xx.h | 391 ++++++ .../include/mach/ctrl_module_pad_core_44xx.h | 1409 ++++++++++++++++++++ .../include/mach/ctrl_module_pad_wkup_44xx.h | 236 ++++ .../include/mach/ctrl_module_wkup_44xx.h | 92 ++ arch/arm/mach-omap2/omap4-common.c | 10 +- arch/arm/mm/mmu.c | 17 +- arch/arm/plat-omap/common.c | 3 +- arch/arm/plat-omap/dmtimer.c | 2 +- arch/arm/plat-omap/include/plat/common.h | 1 + arch/arm/plat-omap/include/plat/control.h | 31 +- arch/arm/plat-omap/include/plat/cpu.h | 5 +- arch/arm/plat-omap/include/plat/uncompress.h | 1 + arch/arm/plat-omap/sram.c | 38 +- 20 files changed, 2271 insertions(+), 109 deletions(-) create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_core_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_pad_core_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_pad_wkup_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_wkup_44xx.h
PATCH 1/14 ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
This patch populates the L1 entries for MT_MEMORY and MT_MEMORY_NONCACHED types so that at boot-up, we can map memories outside system memory at page level granularity
Previously the mapping was limiting to section level, which creates unnecessary addiotional mapping for which physical memory may not present. On the newer ARM with speculation, this is dangerous and can result in untraceable aborts.
--- arch/arm/mm/mmu.c | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-)
arch/arm/mm/mmu.c +15 -2
@@ -246,6 +246,9 @@ static struct mem_type mem_types[] = { .domain = DOMAIN_USER, }, [MT_MEMORY] = { + .prot_pte =L_PTE_PRESENT |L_PTE_YOUNG |L_PTE_DIRTY | + L_PTE_USER | L_PTE_EXEC, + .prot_l1 = PMD_TYPE_TABLE, .prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE, .domain = DOMAIN_KERNEL, },
@@ -254,6 +257,9 @@ static struct mem_type mem_types[] = { .domain = DOMAIN_KERNEL, }, [MT_MEMORY_NONCACHED] = { + .prot_pte =L_PTE_PRESENT |L_PTE_YOUNG |L_PTE_DIRTY | + L_PTE_USER | L_PTE_EXEC | L_PTE_MT_BUFFERABLE, + .prot_l1 = PMD_TYPE_TABLE, .prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE, .domain = DOMAIN_KERNEL, },
@@ -411,9 +417,12 @@ static void __init build_mem_type_table(void)* Enable CPU-specific coherency if supported. * (Only available on XSC3 at the moment.) */ -if (arch_is_coherent () &&cpu_is_xsc3 ()) +if (arch_is_coherent () &&cpu_is_xsc3 ()) { mem_types[MT_MEMORY ].prot_sect |=PMD_SECT_S ; - + mem_types[MT_MEMORY ].prot_pte |=L_PTE_SHARED ; + mem_types[MT_MEMORY_NONCACHED ].prot_sect |=PMD_SECT_S ; + mem_types[MT_MEMORY_NONCACHED ].prot_pte |=L_PTE_SHARED ; + }/* * ARMv6 and above have extended page tables. */
@@ -438,7 +447,9 @@ static void __init build_mem_type_table(void) mem_types[MT_DEVICE_CACHED ].prot_sect |=PMD_SECT_S ; mem_types[MT_DEVICE_CACHED ].prot_pte |=L_PTE_SHARED ; mem_types[MT_MEMORY ].prot_sect |=PMD_SECT_S ; + mem_types[MT_MEMORY ].prot_pte |=L_PTE_SHARED ; mem_types[MT_MEMORY_NONCACHED ].prot_sect |=PMD_SECT_S ; + mem_types[MT_MEMORY_NONCACHED ].prot_pte |=L_PTE_SHARED ;#endif }
@@ -475,6 +486,8 @@ static void __init build_mem_type_table(void) mem_types[MT_LOW_VECTORS ].prot_l1 |= ecc_mask; mem_types[MT_HIGH_VECTORS ].prot_l1 |= ecc_mask; mem_types[MT_MEMORY ].prot_sect |= ecc_mask | cp->pmd; + mem_types[MT_MEMORY ].prot_pte |= kern_pgprot; + mem_types[MT_MEMORY_NONCACHED ].prot_sect |= ecc_mask; mem_types[MT_ROM ].prot_sect |= cp->pmd;switch (cp->pmd) {
Signature · 1 line
1.6.0.4
PATCH 2/14 omap: Map only available sram memory
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order of KBs. This patch maps only available sram and removes some non necessary cpu_is_xxx checks.
On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
--- arch/arm/plat-omap/sram.c | 25 +++++-------------------- 1 files changed, 5 insertions(+), 20 deletions(-)
arch/arm/plat-omap/sram.c +5 -20
@@ -220,20 +220,7 @@ void __init omap_map_sram(void)if (omap_sram_size ==0 )return ; -if (cpu_is_omap24xx ()) { - omap_sram_io_desc[0 ].virtual =OMAP2_SRAM_VA ; - - base =OMAP2_SRAM_PA ; - base =ROUND_DOWN (base,PAGE_SIZE ); - omap_sram_io_desc[0 ].pfn =__phys_to_pfn (base); - } -if (cpu_is_omap34xx ()) { - omap_sram_io_desc[0 ].virtual =OMAP3_SRAM_VA ; - base =OMAP3_SRAM_PA ; - base =ROUND_DOWN (base,PAGE_SIZE ); - omap_sram_io_desc[0 ].pfn =__phys_to_pfn (base); -/* * SRAM must be marked as non-cached on OMAP3 since the * CORE DPLL M2 divider change code (in SRAM) runs with the
@@ -244,13 +231,11 @@ void __init omap_map_sram(void) omap_sram_io_desc[0 ].type =MT_MEMORY_NONCACHED ; } -if (cpu_is_omap44xx ()) { - omap_sram_io_desc[0 ].virtual =OMAP4_SRAM_VA ; - base =OMAP4_SRAM_PA ; - base =ROUND_DOWN (base,PAGE_SIZE ); - omap_sram_io_desc[0 ].pfn =__phys_to_pfn (base); - } - omap_sram_io_desc[0 ].length =1024 *1024 ;/* Use section desc */ + omap_sram_io_desc[0 ].virtual = omap_sram_base; + base = omap_sram_start; + base =ROUND_DOWN (base,PAGE_SIZE ); + omap_sram_io_desc[0 ].pfn =__phys_to_pfn (base); + omap_sram_io_desc[0 ].length =ROUND_DOWN (omap_sram_size,PAGE_SIZE );iotable_init (omap_sram_io_desc,ARRAY_SIZE (omap_sram_io_desc)); printk(KERN_INFO "SRAM: Mapped pa 0x%08lx to va 0x%08lx size: 0x%lx\n",
Signature · 1 line
1.6.0.4
PATCH 3/14 davinci: map sram using MT_MEMORY_NONCACHED instead of MT_DEVICE
On Davinci SRAM is mapped as MT_DEVICE becasue of the section mapping pre-requisite instead of intended MT_MEMORY_NONCACHED
Since the section mapping limitation gets fixed with first patch in this series, the MT_MEMORY_NONCACHED can be used now.
Have not tested this, so somebody with Davinci hardware can try this out
--- arch/arm/mach-davinci/dm355.c | 3 +-- arch/arm/mach-davinci/dm365.c | 3 +-- arch/arm/mach-davinci/dm644x.c | 3 +-- arch/arm/mach-davinci/dm646x.c | 3 +-- 4 files changed, 4 insertions(+), 8 deletions(-)
arch/arm/mach-davinci/dm355.c +1 -2
@@ -769,8 +769,7 @@ static struct map_desc dm355_io_desc[] = { .virtual = SRAM_VIRT, .pfn = __phys_to_pfn(0x00010000), .length = SZ_32K, - /* MT_MEMORY_NONCACHED requires supersection alignment */ - .type = MT_DEVICE, + .type = MT_MEMORY_NONCACHED, }, };
arch/arm/mach-davinci/dm365.c +1 -2
@@ -969,8 +969,7 @@ static struct map_desc dm365_io_desc[] = { .virtual = SRAM_VIRT, .pfn = __phys_to_pfn(0x00010000), .length = SZ_32K, - /* MT_MEMORY_NONCACHED requires supersection alignment */ - .type = MT_DEVICE, + .type = MT_MEMORY_NONCACHED, }, };
arch/arm/mach-davinci/dm644x.c +1 -2
@@ -653,8 +653,7 @@ static struct map_desc dm644x_io_desc[] = { .virtual = SRAM_VIRT, .pfn = __phys_to_pfn(0x00008000), .length = SZ_16K, - /* MT_MEMORY_NONCACHED requires supersection alignment */ - .type = MT_DEVICE, + .type = MT_MEMORY_NONCACHED, }, };
arch/arm/mach-davinci/dm646x.c +1 -2
@@ -737,8 +737,7 @@ static struct map_desc dm646x_io_desc[] = { .virtual = SRAM_VIRT, .pfn = __phys_to_pfn(0x00010000), .length = SZ_32K, - /* MT_MEMORY_NONCACHED requires supersection alignment */ - .type = MT_DEVICE, + .type = MT_MEMORY_NONCACHED, }, };
Signature · 1 line
1.6.0.4
PATCH 4/14 omap4: control: Add ctrl_pad_base to omap_globals
On omap4 control module is divided in four IP blocks.
- CTRL_MODULE_CORE 0x4a002000
- CTRL_MODULE_PAD_CORE 0x4a100000
- CTRL_MODULE_WKUP 0x4a30c000
- CTRL_MODULE_PAD_WKUP 0x4a31e000
Addressing all the modules with single base address is not possible considering 16 bit offsets. The mux code manages the pad core and pad wakeup related base address inside the mux framework. For other usage only control core and control pad bases are necessary. So this patch maps only needed pad control base address which is used by device drivers and infrastructure code
The main control core base is still kept same in this patch to keep git-bisect working. This will be fixed in the relevant patch in this series.
--- arch/arm/mach-omap2/control.c | 7 +++++++ arch/arm/plat-omap/common.c | 3 ++- arch/arm/plat-omap/include/plat/common.h | 1 + 3 files changed, 10 insertions(+), 1 deletions(-)
arch/arm/mach-omap2/control.c +7 -0
@@ -25,6 +25,7 @@#include "sdrc.h" static void __iomem *omap2_ctrl_base; +static void __iomem *omap4_ctrl_pad_base;#if defined(CONFIG_ARCH_OMAP3 ) && defined(CONFIG_PM ) struct omap3_scratchpad {
@@ -145,6 +146,12 @@ void __init omap2_set_globals_control(struct omap_globals *omap2_globals) omap2_ctrl_base =ioremap (omap2_globals->ctrl,SZ_4K );WARN_ON (!omap2_ctrl_base); } + +/* Static mapping, never released */ +if (omap2_globals->ctrl_pad) { + omap4_ctrl_pad_base =ioremap (omap2_globals->ctrl_pad,SZ_4K ); +WARN_ON (!omap4_ctrl_pad_base); + } }void __iomem *omap_ctrl_base_get (void )
arch/arm/plat-omap/common.c +2 -1
@@ -336,7 +336,8 @@ void __init omap3_map_io(void)static struct omap_globals omap4_globals = { .class =OMAP443X_CLASS , .tap =OMAP2_L4_IO_ADDRESS (OMAP443X_SCM_BASE ), - .ctrl =OMAP443X_CTRL_BASE , + .ctrl =OMAP443X_CTRL_BASE ,/* FIXME: Move this to control core */ + .ctrl_pad =OMAP443X_CTRL_BASE , .prm =OMAP4430_PRM_BASE , .cm =OMAP4430_CM_BASE , .cm2 =OMAP4430_CM2_BASE ,
arch/arm/plat-omap/include/plat/common.h +1 -0
@@ -47,6 +47,7 @@ struct omap_globals {unsigned long sdrc;/* SDRAM Controller */ unsigned long sms;/* SDRAM Memory Scheduler */ unsigned long ctrl;/* System Control Module */ +unsigned long ctrl_pad;/* PAD Control Module */ unsigned long prm;/* Power and Reset Management */ unsigned long cm;/* Clock Management */ unsigned long cm2;
Signature · 1 line
1.6.0.4
PATCH 5/14 omap4: control: Add accessor api's for pad control module
On OMAP4 control pad are not addressable from control core base. So the common omap_ctrl_read/write APIs breaks Hence export separate APIs to manage the omap4 pad control registers.
This APIs will work only for OMAP4
--- arch/arm/mach-omap2/control.c | 18 ++++++++++++++++++ arch/arm/plat-omap/include/plat/control.h | 4 ++++ 2 files changed, 22 insertions(+), 0 deletions(-)
arch/arm/mach-omap2/control.c +18 -0
@@ -138,6 +138,7 @@ static struct omap3_control_regs control_context;#endif /* CONFIG_ARCH_OMAP3 && CONFIG_PM */ #define OMAP_CTRL_REGADDR (reg) (omap2_ctrl_base + (reg)) +#define OMAP_CTRL_PAD_REGADDR (reg) (omap4_ctrl_pad_base + (reg))void __init omap2_set_globals_control (struct omap_globals *omap2_globals) {
@@ -189,6 +190,23 @@ void omap_ctrl_writel(u32 val, u16 offset)__raw_writel (val,OMAP_CTRL_REGADDR (offset)); } +/* +* On OMAP4 control pad are not addressable from control +* core base. So the common omap_ctrl_read/write APIs breaks +* Hence export separate APIs to manage the omap4 pad control +* registers. This APIs will work only for OMAP4 +*/ + +u32 omap4_ctrl_pad_readl (u16 offset) +{ +return __raw_readl (OMAP_CTRL_PAD_REGADDR (offset)); +} + +void omap4_ctrl_pad_writel (u32 val,u16 offset) +{ +__raw_writel (val,OMAP_CTRL_PAD_REGADDR (offset)); +} +#if defined(CONFIG_ARCH_OMAP3 ) && defined(CONFIG_PM )/* * Clears the scratchpad contents in case of cold boot-
arch/arm/plat-omap/include/plat/control.h +4 -0
@@ -354,9 +354,11 @@ extern void __iomem *omap_ctrl_base_get(void);extern u8 omap_ctrl_readb (u16 offset);extern u16 omap_ctrl_readw (u16 offset);extern u32 omap_ctrl_readl (u16 offset); +extern u32 omap4_ctrl_pad_readl (u16 offset);extern void omap_ctrl_writeb (u8 val,u16 offset);extern void omap_ctrl_writew (u16 val,u16 offset);extern void omap_ctrl_writel (u32 val,u16 offset); +extern void omap4_ctrl_pad_writel (u32 val,u16 offset);extern void omap3_save_scratchpad_contents (void );extern void omap3_clear_scratchpad_contents (void );
@@ -371,9 +373,11 @@ extern void omap3_control_restore_context(void);#define omap_ctrl_readb (x) 0#define omap_ctrl_readw (x) 0#define omap_ctrl_readl (x) 0 +#define omap4_ctrl_pad_readl (x) 0#define omap_ctrl_writeb (x, y) WARN_ON(1)#define omap_ctrl_writew (x, y) WARN_ON(1)#define omap_ctrl_writel (x, y) WARN_ON(1) +#define omap4_ctrl_pad_writel (x, y) WARN_ON(1)#endif #endif /* __ASSEMBLY__ */
Signature · 1 line
1.6.0.4
PATCH 6/14 omap4: control: Add the register definition headers
On OMAP4, control module is divided into 4 separate IPs
- OMAP44XX_CTRL_MODULE_CORE
- OMAP44XX_CTRL_MODULE_PAD_CORE
- OMAP44XX_CTRL_MODULE_WKUP
- OMAP44XX_CTRL_MODULE_PAD_WKUP
This patch adds all the omap4 control module register data and includes them in the common control.h
The register data is autogenerated from the codebase thanks to Benoit Cousson efforts
--- .../include/mach/ctrl_module_core_44xx.h | 391 ++++++ .../include/mach/ctrl_module_pad_core_44xx.h | 1409 ++++++++++++++++++++ .../include/mach/ctrl_module_pad_wkup_44xx.h | 236 ++++ .../include/mach/ctrl_module_wkup_44xx.h | 92 ++ arch/arm/plat-omap/include/plat/control.h | 4 + 5 files changed, 2132 insertions(+), 0 deletions(-) create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_core_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_pad_core_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_pad_wkup_44xx.h create mode 100644 arch/arm/mach-omap2/include/mach/ctrl_module_wkup_44xx.h
arch/arm/mach-omap2/include/mach/ctrl_module_core_44xx.h new file +391 -0
@@ -0,0 +1,391 @@ +/* +* OMAP44xx CTRL_MODULE_CORE registers and bitfields +* +* Copyright (C) 2009-2010 Texas Instruments, Inc. +* +* Benoit Cousson (b-cousson at ti.com) +* Santosh Shilimkar (santosh.shilimkar at ti.com) +* +* This file is automatically generated from the OMAP hardware databases. +* We respectfully ask that any modifications to this file be coordinated +* with the public linux-omap at vger.kernel.org mailing list and the +* authors above to ensure that the autogeneration scripts are kept +* up-to-date with the file contents. +* +* This program is free software; you can redistribute it and/or modify +* it under the terms of the GNU General Public License version 2 as +* published by the Free Software Foundation. +*/ + +#ifndef __ARCH_ARM_MACH_OMAP2_CTRL_MODULE_CORE_44XX_H +#define __ARCH_ARM_MACH_OMAP2_CTRL_MODULE_CORE_44XX_H + + +/* Base address */ +#define OMAP4_CTRL_MODULE_CORE 0x4a002000 + +/* Registers offset */ +#define OMAP4_CTRL_MODULE_CORE_IP_REVISION 0x0000 +#define OMAP4_CTRL_MODULE_CORE_IP_HWINFO 0x0004 +#define OMAP4_CTRL_MODULE_CORE_IP_SYSCONFIG 0x0010 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_DIE_ID_0 0x0200 +#define OMAP4_CTRL_MODULE_CORE_ID_CODE 0x0204 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_DIE_ID_1 0x0208 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_DIE_ID_2 0x020c +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_DIE_ID_3 0x0210 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_PROD_ID_0 0x0214 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_PROD_ID_1 0x0218 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_USB_CONF 0x021c +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_OPP_VDD_WKUP 0x0228 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_OPP_BGAP 0x0260 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_OPP_DPLL_0 0x0264 +#define OMAP4_CTRL_MODULE_CORE_STD_FUSE_OPP_DPLL_1 0x0268 +#define OMAP4_CTRL_MODULE_CORE_STATUS 0x02c4 +#define OMAP4_CTRL_MODULE_CORE_DEV_CONF 0x0300 +#define OMAP4_CTRL_MODULE_CORE_LDOVBB_IVA_VOLTAGE_CTRL 0x0314 +#define OMAP4_CTRL_MODULE_CORE_LDOVBB_MPU_VOLTAGE_CTRL 0x0318 +#define OMAP4_CTRL_MODULE_CORE_LDOSRAM_IVA_VOLTAGE_CTRL 0x0320 +#define OMAP4_CTRL_MODULE_CORE_LDOSRAM_MPU_VOLTAGE_CTRL 0x0324 +#define OMAP4_CTRL_MODULE_CORE_LDOSRAM_CORE_VOLTAGE_CTRL 0x0328 +#define OMAP4_CTRL_MODULE_CORE_TEMP_SENSOR 0x032c +#define OMAP4_CTRL_MODULE_CORE_DPLL_NWELL_TRIM_0 0x0330 +#define OMAP4_CTRL_MODULE_CORE_DPLL_NWELL_TRIM_1 0x0334 +#define OMAP4_CTRL_MODULE_CORE_USBOTGHS_CONTROL 0x033c +#define OMAP4_CTRL_MODULE_CORE_DSS_CONTROL 0x0340 +#define OMAP4_CTRL_MODULE_CORE_HWOBS_CONTROL 0x0350 +#define OMAP4_CTRL_MODULE_CORE_DEBOBS_FINAL_MUX_SEL 0x0400 +#define OMAP4_CTRL_MODULE_CORE_DEBOBS_MMR_MPU 0x0408 +#define OMAP4_CTRL_MODULE_CORE_CONF_SDMA_REQ_SEL0 0x042c +#define OMAP4_CTRL_MODULE_CORE_CONF_SDMA_REQ_SEL1 0x0430 +#define OMAP4_CTRL_MODULE_CORE_CONF_SDMA_REQ_SEL2 0x0434 +#define OMAP4_CTRL_MODULE_CORE_CONF_SDMA_REQ_SEL3 0x0438 +#define OMAP4_CTRL_MODULE_CORE_CONF_CLK_SEL0 0x0440 +#define OMAP4_CTRL_MODULE_CORE_CONF_CLK_SEL1 0x0444 +#define OMAP4_CTRL_MODULE_CORE_CONF_CLK_SEL2 0x0448 +#define OMAP4_CTRL_MODULE_CORE_CONF_DPLL_FREQLOCK_SEL 0x044c +#define OMAP4_CTRL_MODULE_CORE_CONF_DPLL_TINITZ_SEL 0x0450 +#define OMAP4_CTRL_MODULE_CORE_CONF_DPLL_PHASELOCK_SEL 0x0454 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_0 0x0480 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_1 0x0484 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_2 0x0488 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_3 0x048c +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_4 0x0490 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_5 0x0494 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_6 0x0498 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_7 0x049c +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_8 0x04a0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_9 0x04a4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_10 0x04a8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_11 0x04ac +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_12 0x04b0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_13 0x04b4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_14 0x04b8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_15 0x04bc +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_16 0x04c0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_17 0x04c4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_18 0x04c8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_19 0x04cc +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_20 0x04d0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_21 0x04d4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_22 0x04d8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_23 0x04dc +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_24 0x04e0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_25 0x04e4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_26 0x04e8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_27 0x04ec +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_28 0x04f0 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_29 0x04f4 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_30 0x04f8 +#define OMAP4_CTRL_MODULE_CORE_CONF_DEBUG_SEL_TST_31 0x04fc + +/* Registers shifts and masks */ + +/* IP_REVISION */ +#define OMAP4_IP_REV_SCHEME_SHIFT 30 +#define OMAP4_IP_REV_SCHEME_MASK (0x3 << 30) +#define OMAP4_IP_REV_FUNC_SHIFT 16 +#define OMAP4_IP_REV_FUNC_MASK (0xfff << 16) +#define OMAP4_IP_REV_RTL_SHIFT 11 +#define OMAP4_IP_REV_RTL_MASK (0x1f << 11) +#define OMAP4_IP_REV_MAJOR_SHIFT 8 +#define OMAP4_IP_REV_MAJOR_MASK (0x7 << 8) +#define OMAP4_IP_REV_CUSTOM_SHIFT 6 +#define OMAP4_IP_REV_CUSTOM_MASK (0x3 << 6) +#define OMAP4_IP_REV_MINOR_SHIFT 0 +#define OMAP4_IP_REV_MINOR_MASK (0x3f << 0) + +/* IP_HWINFO */ +#define OMAP4_IP_HWINFO_SHIFT 0 +#define OMAP4_IP_HWINFO_MASK (0xffffffff << 0) + +/* IP_SYSCONFIG */ +#define OMAP4_IP_SYSCONFIG_IDLEMODE_SHIFT 2 +#define OMAP4_IP_SYSCONFIG_IDLEMODE_MASK (0x3 << 2) + +/* STD_FUSE_DIE_ID_0 */ +#define OMAP4_STD_FUSE_DIE_ID_0_SHIFT 0 +#define OMAP4_STD_FUSE_DIE_ID_0_MASK (0xffffffff << 0) + +/* ID_CODE */ +#define OMAP4_STD_FUSE_IDCODE_SHIFT 0 +#define OMAP4_STD_FUSE_IDCODE_MASK (0xffffffff << 0) + +/* STD_FUSE_DIE_ID_1 */ +#define OMAP4_STD_FUSE_DIE_ID_1_SHIFT 0 +#define OMAP4_STD_FUSE_DIE_ID_1_MASK (0xffffffff << 0) + +/* STD_FUSE_DIE_ID_2 */ +#define OMAP4_STD_FUSE_DIE_ID_2_SHIFT 0 +#define OMAP4_STD_FUSE_DIE_ID_2_MASK (0xffffffff << 0) + +/* STD_FUSE_DIE_ID_3 */ +#define OMAP4_STD_FUSE_DIE_ID_3_SHIFT 0 +#define OMAP4_STD_FUSE_DIE_ID_3_MASK (0xffffffff << 0) + +/* STD_FUSE_PROD_ID_0 */ +#define OMAP4_STD_FUSE_PROD_ID_0_SHIFT 0 +#define OMAP4_STD_FUSE_PROD_ID_0_MASK (0xffffffff << 0) + +/* STD_FUSE_PROD_ID_1 */ +#define OMAP4_STD_FUSE_PROD_ID_1_SHIFT 0 +#define OMAP4_STD_FUSE_PROD_ID_1_MASK (0xffffffff << 0) + +/* STD_FUSE_USB_CONF */ +#define OMAP4_USB_PROD_ID_SHIFT 16 +#define OMAP4_USB_PROD_ID_MASK (0xffff << 16) +#define OMAP4_USB_VENDOR_ID_SHIFT 0 +#define OMAP4_USB_VENDOR_ID_MASK (0xffff << 0) + +/* STD_FUSE_OPP_VDD_WKUP */ +#define OMAP4_STD_FUSE_OPP_VDD_WKUP_SHIFT 0 +#define OMAP4_STD_FUSE_OPP_VDD_WKUP_MASK (0xffffffff << 0) + +/* STD_FUSE_OPP_BGAP */ +#define OMAP4_STD_FUSE_OPP_BGAP_SHIFT 0 +#define OMAP4_STD_FUSE_OPP_BGAP_MASK (0xffffffff << 0) + +/* STD_FUSE_OPP_DPLL_0 */ +#define OMAP4_STD_FUSE_OPP_DPLL_0_SHIFT 0 +#define OMAP4_STD_FUSE_OPP_DPLL_0_MASK (0xffffffff << 0) + +/* STD_FUSE_OPP_DPLL_1 */ +#define OMAP4_STD_FUSE_OPP_DPLL_1_SHIFT 0 +#define OMAP4_STD_FUSE_OPP_DPLL_1_MASK (0xffffffff << 0) + +/* STATUS */ +#define OMAP4_ATTILA_CONF_SHIFT 11 +#define OMAP4_ATTILA_CONF_MASK (0x3 << 11) +#define OMAP4_DEVICE_TYPE_SHIFT 8 +#define OMAP4_DEVICE_TYPE_MASK (0x7 << 8) +#define OMAP4_SYS_BOOT_SHIFT 0 +#define OMAP4_SYS_BOOT_MASK (0xff << 0) + +/* DEV_CONF */ +#define OMAP4_DEV_CONF_SHIFT 1 +#define OMAP4_DEV_CONF_MASK (0x7fffffff << 1) +#define OMAP4_USBPHY_PD_SHIFT 0 +#define OMAP4_USBPHY_PD_MASK (1 << 0) + +/* LDOVBB_IVA_VOLTAGE_CTRL */ +#define OMAP4_LDOVBBIVA_RBB_MUX_CTRL_SHIFT 26 +#define OMAP4_LDOVBBIVA_RBB_MUX_CTRL_MASK (1 << 26) +#define OMAP4_LDOVBBIVA_RBB_VSET_IN_SHIFT 21 +#define OMAP4_LDOVBBIVA_RBB_VSET_IN_MASK (0x1f << 21) +#define OMAP4_LDOVBBIVA_RBB_VSET_OUT_SHIFT 16 +#define OMAP4_LDOVBBIVA_RBB_VSET_OUT_MASK (0x1f << 16) +#define OMAP4_LDOVBBIVA_FBB_MUX_CTRL_SHIFT 10 +#define OMAP4_LDOVBBIVA_FBB_MUX_CTRL_MASK (1 << 10) +#define OMAP4_LDOVBBIVA_FBB_VSET_IN_SHIFT 5 +#define OMAP4_LDOVBBIVA_FBB_VSET_IN_MASK (0x1f << 5) +#define OMAP4_LDOVBBIVA_FBB_VSET_OUT_SHIFT 0 +#define OMAP4_LDOVBBIVA_FBB_VSET_OUT_MASK (0x1f << 0) + +/* LDOVBB_MPU_VOLTAGE_CTRL */ +#define OMAP4_LDOVBBMPU_RBB_MUX_CTRL_SHIFT 26 +#define OMAP4_LDOVBBMPU_RBB_MUX_CTRL_MASK (1 << 26) +#define OMAP4_LDOVBBMPU_RBB_VSET_IN_SHIFT 21 +#define OMAP4_LDOVBBMPU_RBB_VSET_IN_MASK (0x1f << 21) +#define OMAP4_LDOVBBMPU_RBB_VSET_OUT_SHIFT 16 +#define OMAP4_LDOVBBMPU_RBB_VSET_OUT_MASK (0x1f << 16) +#define OMAP4_LDOVBBMPU_FBB_MUX_CTRL_SHIFT 10 +#define OMAP4_LDOVBBMPU_FBB_MUX_CTRL_MASK (1 << 10) +#define OMAP4_LDOVBBMPU_FBB_VSET_IN_SHIFT 5 +#define OMAP4_LDOVBBMPU_FBB_VSET_IN_MASK (0x1f << 5) +#define OMAP4_LDOVBBMPU_FBB_VSET_OUT_SHIFT 0 +#define OMAP4_LDOVBBMPU_FBB_VSET_OUT_MASK (0x1f << 0) + +/* LDOSRAM_IVA_VOLTAGE_CTRL */ +#define OMAP4_LDOSRAMIVA_RETMODE_MUX_CTRL_SHIFT 26 +#define OMAP4_LDOSRAMIVA_RETMODE_MUX_CTRL_MASK (1 << 26) +#define OMAP4_LDOSRAMIVA_RETMODE_VSET_IN_SHIFT 21 +#define OMAP4_LDOSRAMIVA_RETMODE_VSET_IN_MASK (0x1f << 21) +#define OMAP4_LDOSRAMIVA_RETMODE_VSET_OUT_SHIFT 16 +#define OMAP4_LDOSRAMIVA_RETMODE_VSET_OUT_MASK (0x1f << 16) +#define OMAP4_LDOSRAMIVA_ACTMODE_MUX_CTRL_SHIFT 10 +#define OMAP4_LDOSRAMIVA_ACTMODE_MUX_CTRL_MASK (1 << 10) +#define OMAP4_LDOSRAMIVA_ACTMODE_VSET_IN_SHIFT 5 +#define OMAP4_LDOSRAMIVA_ACTMODE_VSET_IN_MASK (0x1f << 5) +#define OMAP4_LDOSRAMIVA_ACTMODE_VSET_OUT_SHIFT 0 +#define OMAP4_LDOSRAMIVA_ACTMODE_VSET_OUT_MASK (0x1f << 0) + +/* LDOSRAM_MPU_VOLTAGE_CTRL */ +#define OMAP4_LDOSRAMMPU_RETMODE_MUX_CTRL_SHIFT 26 +#define OMAP4_LDOSRAMMPU_RETMODE_MUX_CTRL_MASK (1 << 26) +#define OMAP4_LDOSRAMMPU_RETMODE_VSET_IN_SHIFT 21 +#define OMAP4_LDOSRAMMPU_RETMODE_VSET_IN_MASK (0x1f << 21) +#define OMAP4_LDOSRAMMPU_RETMODE_VSET_OUT_SHIFT 16 +#define OMAP4_LDOSRAMMPU_RETMODE_VSET_OUT_MASK (0x1f << 16) +#define OMAP4_LDOSRAMMPU_ACTMODE_MUX_CTRL_SHIFT 10 +#define OMAP4_LDOSRAMMPU_ACTMODE_MUX_CTRL_MASK (1 << 10) +#define OMAP4_LDOSRAMMPU_ACTMODE_VSET_IN_SHIFT 5 +#define OMAP4_LDOSRAMMPU_ACTMODE_VSET_IN_MASK (0x1f << 5) +#define OMAP4_LDOSRAMMPU_ACTMODE_VSET_OUT_SHIFT 0 +#define OMAP4_LDOSRAMMPU_ACTMODE_VSET_OUT_MASK (0x1f << 0) + +/* LDOSRAM_CORE_VOLTAGE_CTRL */ +#define OMAP4_LDOSRAMCORE_RETMODE_MUX_CTRL_SHIFT 26 +#define OMAP4_LDOSRAMCORE_RETMODE_MUX_CTRL_MASK (1 << 26) +#define OMAP4_LDOSRAMCORE_RETMODE_VSET_IN_SHIFT 21 +#define OMAP4_LDOSRAMCORE_RETMODE_VSET_IN_MASK (0x1f << 21) +#define OMAP4_LDOSRAMCORE_RETMODE_VSET_OUT_SHIFT 16 +#define OMAP4_LDOSRAMCORE_RETMODE_VSET_OUT_MASK (0x1f << 16) +#define OMAP4_LDOSRAMCORE_ACTMODE_MUX_CTRL_SHIFT 10 +#define OMAP4_LDOSRAMCORE_ACTMODE_MUX_CTRL_MASK (1 << 10) +#define OMAP4_LDOSRAMCORE_ACTMODE_VSET_IN_SHIFT 5 +#define OMAP4_LDOSRAMCORE_ACTMODE_VSET_IN_MASK (0x1f << 5) +#define OMAP4_LDOSRAMCORE_ACTMODE_VSET_OUT_SHIFT 0 +#define OMAP4_LDOSRAMCORE_ACTMODE_VSET_OUT_MASK (0x1f << 0) + +/* TEMP_SENSOR */ +#define OMAP4_BGAP_TEMPSOFF_SHIFT 12 +#define OMAP4_BGAP_TEMPSOFF_MASK (1 << 12) +#define OMAP4_BGAP_TSHUT_SHIFT 11 +#define OMAP4_BGAP_TSHUT_MASK (1 << 11) +#define OMAP4_BGAP_TEMP_SENSOR_CONTCONV_SHIFT 10 +#define OMAP4_BGAP_TEMP_SENSOR_CONTCONV_MASK (1 << 10) +#define OMAP4_BGAP_TEMP_SENSOR_SOC_SHIFT 9 +#define OMAP4_BGAP_TEMP_SENSOR_SOC_MASK (1 << 9) +#define OMAP4_BGAP_TEMP_SENSOR_EOCZ_SHIFT 8 +#define OMAP4_BGAP_TEMP_SENSOR_EOCZ_MASK (1 << 8) +#define OMAP4_BGAP_TEMP_SENSOR_DTEMP_SHIFT 0 +#define OMAP4_BGAP_TEMP_SENSOR_DTEMP_MASK (0xff << 0) + +/* DPLL_NWELL_TRIM_0 */ +#define OMAP4_DPLL_ABE_NWELL_TRIM_MUX_CTRL_SHIFT 29 +#define OMAP4_DPLL_ABE_NWELL_TRIM_MUX_CTRL_MASK (1 << 29) +#define OMAP4_DPLL_ABE_NWELL_TRIM_SHIFT 24 +#define OMAP4_DPLL_ABE_NWELL_TRIM_MASK (0x1f << 24) +#define OMAP4_DPLL_PER_NWELL_TRIM_MUX_CTRL_SHIFT 23 +#define OMAP4_DPLL_PER_NWELL_TRIM_MUX_CTRL_MASK (1 << 23) +#define OMAP4_DPLL_PER_NWELL_TRIM_SHIFT 18 +#define OMAP4_DPLL_PER_NWELL_TRIM_MASK (0x1f << 18) +#define OMAP4_DPLL_CORE_NWELL_TRIM_MUX_CTRL_SHIFT 17 +#define OMAP4_DPLL_CORE_NWELL_TRIM_MUX_CTRL_MASK (1 << 17) +#define OMAP4_DPLL_CORE_NWELL_TRIM_SHIFT 12 +#define OMAP4_DPLL_CORE_NWELL_TRIM_MASK (0x1f << 12) +#define OMAP4_DPLL_IVA_NWELL_TRIM_MUX_CTRL_SHIFT 11 +#define OMAP4_DPLL_IVA_NWELL_TRIM_MUX_CTRL_MASK (1 << 11) +#define OMAP4_DPLL_IVA_NWELL_TRIM_SHIFT 6 +#define OMAP4_DPLL_IVA_NWELL_TRIM_MASK (0x1f << 6) +#define OMAP4_DPLL_MPU_NWELL_TRIM_MUX_CTRL_SHIFT 5 +#define OMAP4_DPLL_MPU_NWELL_TRIM_MUX_CTRL_MASK (1 << 5) +#define OMAP4_DPLL_MPU_NWELL_TRIM_SHIFT 0 +#define OMAP4_DPLL_MPU_NWELL_TRIM_MASK (0x1f << 0) + +/* DPLL_NWELL_TRIM_1 */ +#define OMAP4_DPLL_UNIPRO_NWELL_TRIM_MUX_CTRL_SHIFT 29 +#define OMAP4_DPLL_UNIPRO_NWELL_TRIM_MUX_CTRL_MASK (1 << 29) +#define OMAP4_DPLL_UNIPRO_NWELL_TRIM_SHIFT 24 +#define OMAP4_DPLL_UNIPRO_NWELL_TRIM_MASK (0x1f << 24) +#define OMAP4_DPLL_USB_NWELL_TRIM_MUX_CTRL_SHIFT 23 +#define OMAP4_DPLL_USB_NWELL_TRIM_MUX_CTRL_MASK (1 << 23) +#define OMAP4_DPLL_USB_NWELL_TRIM_SHIFT 18 +#define OMAP4_DPLL_USB_NWELL_TRIM_MASK (0x1f << 18) +#define OMAP4_DPLL_HDMI_NWELL_TRIM_MUX_CTRL_SHIFT 17 +#define OMAP4_DPLL_HDMI_NWELL_TRIM_MUX_CTRL_MASK (1 << 17) +#define OMAP4_DPLL_HDMI_NWELL_TRIM_SHIFT 12 +#define OMAP4_DPLL_HDMI_NWELL_TRIM_MASK (0x1f << 12) +#define OMAP4_DPLL_DSI2_NWELL_TRIM_MUX_CTRL_SHIFT 11 +#define OMAP4_DPLL_DSI2_NWELL_TRIM_MUX_CTRL_MASK (1 << 11) +#define OMAP4_DPLL_DSI2_NWELL_TRIM_SHIFT 6 +#define OMAP4_DPLL_DSI2_NWELL_TRIM_MASK (0x1f << 6) +#define OMAP4_DPLL_DSI1_NWELL_TRIM_MUX_CTRL_SHIFT 5 +#define OMAP4_DPLL_DSI1_NWELL_TRIM_MUX_CTRL_MASK (1 << 5) +#define OMAP4_DPLL_DSI1_NWELL_TRIM_SHIFT 0 +#define OMAP4_DPLL_DSI1_NWELL_TRIM_MASK (0x1f << 0) + +/* USBOTGHS_CONTROL */ +#define OMAP4_DISCHRGVBUS_SHIFT 8 +#define OMAP4_DISCHRGVBUS_MASK (1 << 8) +#define OMAP4_CHRGVBUS_SHIFT 7 +#define OMAP4_CHRGVBUS_MASK (1 << 7) +#define OMAP4_DRVVBUS_SHIFT 6 +#define OMAP4_DRVVBUS_MASK (1 << 6) +#define OMAP4_IDPULLUP_SHIFT 5 +#define OMAP4_IDPULLUP_MASK (1 << 5) +#define OMAP4_IDDIG_SHIFT 4 +#define OMAP4_IDDIG_MASK (1 << 4) +#define OMAP4_SESSEND_SHIFT 3 +#define OMAP4_SESSEND_MASK (1 << 3) +#define OMAP4_VBUSVALID_SHIFT 2 +#define OMAP4_VBUSVALID_MASK (1 << 2) +#define OMAP4_BVALID_SHIFT 1 +#define OMAP4_BVALID_MASK (1 << 1) +#define OMAP4_AVALID_SHIFT 0 +#define OMAP4_AVALID_MASK (1 << 0) + +/* DSS_CONTROL */ +#define OMAP4_DSS_MUX6_SELECT_SHIFT 0 +#define OMAP4_DSS_MUX6_SELECT_MASK (1 << 0) + +/* HWOBS_CONTROL */ +#define OMAP4_HWOBS_CLKDIV_SEL_SHIFT 3 +#define OMAP4_HWOBS_CLKDIV_SEL_MASK (0x1f << 3) +#define OMAP4_HWOBS_ALL_ZERO_MODE_SHIFT 2 +#define OMAP4_HWOBS_ALL_ZERO_MODE_MASK (1 << 2) +#define OMAP4_HWOBS_ALL_ONE_MODE_SHIFT 1 +#define OMAP4_HWOBS_ALL_ONE_MODE_MASK (1 << 1) +#define OMAP4_HWOBS_MACRO_ENABLE_SHIFT 0 +#define OMAP4_HWOBS_MACRO_ENABLE_MASK (1 << 0) + +/* DEBOBS_FINAL_MUX_SEL */ +#define OMAP4_SELECT_SHIFT 0 +#define OMAP4_SELECT_MASK (0xffffffff << 0) + +/* DEBOBS_MMR_MPU */ +#define OMAP4_SELECT_DEBOBS_MMR_MPU_SHIFT 0 +#define OMAP4_SELECT_DEBOBS_MMR_MPU_MASK (0xf << 0) + +/* CONF_SDMA_REQ_SEL0 */ +#define OMAP4_MULT_SHIFT 0 +#define OMAP4_MULT_MASK (0x7f << 0) + +/* CONF_CLK_SEL0 */ +#define OMAP4_MULT_CONF_CLK_SEL0_SHIFT 0 +#define OMAP4_MULT_CONF_CLK_SEL0_MASK (0x7 << 0) + +/* CONF_CLK_SEL1 */ +#define OMAP4_MULT_CONF_CLK_SEL1_SHIFT 0 +#define OMAP4_MULT_CONF_CLK_SEL1_MASK (0x7 << 0) + +/* CONF_CLK_SEL2 */ +#define OMAP4_MULT_CONF_CLK_SEL2_SHIFT 0 +#define OMAP4_MULT_CONF_CLK_SEL2_MASK (0x7 << 0) + +/* CONF_DPLL_FREQLOCK_SEL */ +#define OMAP4_MULT_CONF_DPLL_FREQLOCK_SEL_SHIFT 0 +#define OMAP4_MULT_CONF_DPLL_FREQLOCK_SEL_MASK (0x7 << 0) + +/* CONF_DPLL_TINITZ_SEL */ +#define OMAP4_MULT_CONF_DPLL_TINITZ_SEL_SHIFT 0 +#define OMAP4_MULT_CONF_DPLL_TINITZ_SEL_MASK (0x7 << 0) + +/* CONF_DPLL_PHASELOCK_SEL */ +#define OMAP4_MULT_CONF_DPLL_PHASELOCK_SEL_SHIFT 0 +#define OMAP4_MULT_CONF_DPLL_PHASELOCK_SEL_MASK (0x7 << 0) + +/* CONF_DEBUG_SEL_TST_0 */ +#define OMAP4_MODE_SHIFT 0 +#define OMAP4_MODE_MASK (0xf << 0) + +#endif
arch/arm/mach-omap2/include/mach/ctrl_module_pad_core_44xx.h new file +1409 -0
1,409 lines not on this page · raw message
arch/arm/mach-omap2/include/mach/ctrl_module_pad_wkup_44xx.h new file +236 -0
236 lines not on this page · raw message
arch/arm/mach-omap2/include/mach/ctrl_module_wkup_44xx.h new file +92 -0
92 lines not on this page · raw message
arch/arm/plat-omap/include/plat/control.h +4 -0
@@ -17,6 +17,10 @@#define __ASM_ARCH_CONTROL_H#include <mach/io.h> +#include <mach/ctrl_module_core_44xx.h> +#include <mach/ctrl_module_wkup_44xx.h> +#include <mach/ctrl_module_pad_core_44xx.h> +#include <mach/ctrl_module_pad_wkup_44xx.h> #ifndef __ASSEMBLY__#define OMAP242X_CTRL_REGADDR (reg) \
Signature · 1 line
1.6.0.4
PATCH 7/14 omap4: control: Fix the control module register accesses
This patch has multiple fixes together. To ensure that git bisect work across commits, all changes are clubbed together
1. Move the common control base address to control core
2. Remove the manually coeded defines and use the ones from headers.
3. Fix the the status register define in id.c for OMAP4
4. Fix all the register define in hsmmc.c
5. Use the control pad accessor API for omap4 hsmmc register accesses
--- arch/arm/mach-omap2/hsmmc.c | 67 +++++++++++++++------------- arch/arm/mach-omap2/id.c | 2 +- arch/arm/plat-omap/common.c | 2 +- arch/arm/plat-omap/include/plat/control.h | 23 ---------- 4 files changed, 38 insertions(+), 56 deletions(-)
arch/arm/mach-omap2/hsmmc.c +36 -31
@@ -135,10 +135,11 @@ static void omap4_hsmmc1_before_set_reg(struct device *dev, int slot,* * FIXME handle VMMC1A as needed ... */ - reg =omap_ctrl_readl (control_pbias_offset); - reg &= ~(OMAP4_MMC1_PBIASLITE_PWRDNZ |OMAP4_MMC1_PWRDNZ | -OMAP4_USBC1_ICUSB_PWRDNZ ); -omap_ctrl_writel (reg, control_pbias_offset); + reg =omap4_ctrl_pad_readl (control_pbias_offset); + reg &= ~(OMAP4_MMC1_PBIASLITE_PWRDNZ_MASK | +OMAP4_MMC1_PWRDNZ_MASK | +OMAP4_USBC1_ICUSB_PWRDNZ_MASK ); +omap4_ctrl_pad_writel (reg, control_pbias_offset); } static void omap4_hsmmc1_after_set_reg(struct device *dev, int slot,
@@ -147,30 +148,33 @@ static void omap4_hsmmc1_after_set_reg(struct device *dev, int slot,u32 reg;if (power_on) { - reg =omap_ctrl_readl (control_pbias_offset); - reg |=OMAP4_MMC1_PBIASLITE_PWRDNZ ; + reg =omap4_ctrl_pad_readl (control_pbias_offset); + reg |=OMAP4_MMC1_PBIASLITE_PWRDNZ_MASK ;if ((1 << vdd) <=MMC_VDD_165_195 ) - reg &= ~OMAP4_MMC1_PBIASLITE_VMODE ; + reg &= ~OMAP4_MMC1_PBIASLITE_VMODE_MASK ;else - reg |=OMAP4_MMC1_PBIASLITE_VMODE ; - reg |= (OMAP4_MMC1_PBIASLITE_PWRDNZ |OMAP4_MMC1_PWRDNZ | -OMAP4_USBC1_ICUSB_PWRDNZ ); -omap_ctrl_writel (reg, control_pbias_offset); + reg |=OMAP4_MMC1_PBIASLITE_VMODE_MASK ; + reg |= (OMAP4_MMC1_PBIASLITE_PWRDNZ_MASK | +OMAP4_MMC1_PWRDNZ_MASK | +OMAP4_USBC1_ICUSB_PWRDNZ_MASK ); +omap4_ctrl_pad_writel (reg, control_pbias_offset);/* 4 microsec delay for comparator to generate an error*/ udelay (4 ); - reg =omap_ctrl_readl (control_pbias_offset); -if (reg &OMAP4_MMC1_PBIASLITE_VMODE_ERROR ) { + reg =omap4_ctrl_pad_readl (control_pbias_offset); +if (reg &OMAP4_MMC1_PBIASLITE_VMODE_ERROR_MASK ) {pr_err ("Pbias Voltage is not same as LDO\n" );/* Caution : On VMODE_ERROR Power Down MMC IO */ - reg &= ~(OMAP4_MMC1_PWRDNZ |OMAP4_USBC1_ICUSB_PWRDNZ ); -omap_ctrl_writel (reg, control_pbias_offset); + reg &= ~(OMAP4_MMC1_PWRDNZ_MASK | +OMAP4_USBC1_ICUSB_PWRDNZ_MASK ); +omap4_ctrl_pad_writel (reg, control_pbias_offset); } }else { - reg =omap_ctrl_readl (control_pbias_offset); - reg |= (OMAP4_MMC1_PBIASLITE_PWRDNZ | -OMAP4_MMC1_PBIASLITE_VMODE |OMAP4_MMC1_PWRDNZ | -OMAP4_USBC1_ICUSB_PWRDNZ ); -omap_ctrl_writel (reg, control_pbias_offset); + reg =omap4_ctrl_pad_readl (control_pbias_offset); + reg |= (OMAP4_MMC1_PBIASLITE_PWRDNZ_MASK | +OMAP4_MMC1_PWRDNZ_MASK | +OMAP4_MMC1_PBIASLITE_VMODE_MASK | +OMAP4_USBC1_ICUSB_PWRDNZ_MASK ); +omap4_ctrl_pad_writel (reg, control_pbias_offset); } }
@@ -218,17 +222,18 @@ void __init omap2_hsmmc_init(struct omap2_hsmmc_info *controllers) control_devconf1_offset =OMAP343X_CONTROL_DEVCONF1 ; } }else { - control_pbias_offset =OMAP44XX_CONTROL_PBIAS_LITE ; - control_mmc1 =OMAP44XX_CONTROL_MMC1 ; - reg =omap_ctrl_readl (control_mmc1); - reg |= (OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP0 | -OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP1 ); - reg &= ~(OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP2 | -OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP3 ); - reg |= (OMAP4_CONTROL_SDMMC1_DR0_SPEEDCTRL | -OMAP4_CONTROL_SDMMC1_DR1_SPEEDCTRL | -OMAP4_CONTROL_SDMMC1_DR2_SPEEDCTRL ); -omap_ctrl_writel (reg, control_mmc1); + control_pbias_offset = +OMAP4_CTRL_MODULE_PAD_CORE_CONTROL_PBIASLITE ; + control_mmc1 =OMAP4_CTRL_MODULE_PAD_CORE_CONTROL_MMC1 ; + reg =omap4_ctrl_pad_readl (control_mmc1); + reg |= (OMAP4_SDMMC1_PUSTRENGTH_GRP0_MASK | +OMAP4_SDMMC1_PUSTRENGTH_GRP1_MASK ); + reg &= ~(OMAP4_SDMMC1_PUSTRENGTH_GRP2_MASK | +OMAP4_SDMMC1_PUSTRENGTH_GRP3_MASK ); + reg |= (OMAP4_USBC1_DR0_SPEEDCTRL_MASK | +OMAP4_SDMMC1_DR1_SPEEDCTRL_MASK | +OMAP4_SDMMC1_DR2_SPEEDCTRL_MASK ); +omap4_ctrl_pad_writel (reg, control_mmc1); }for (c = controllers; c->mmc; c++) {
arch/arm/mach-omap2/id.c +1 -1
@@ -60,7 +60,7 @@ int omap_type(void) }else if (cpu_is_omap34xx ()) { val =omap_ctrl_readl (OMAP343X_CONTROL_STATUS ); }else if (cpu_is_omap44xx ()) { - val =omap_ctrl_readl (OMAP44XX_CONTROL_STATUS ); + val =omap_ctrl_readl (OMAP4_CTRL_MODULE_CORE_STATUS ); }else {pr_err ("Cannot detect omap type!\n" ); goto out;
arch/arm/plat-omap/common.c +1 -1
@@ -336,7 +336,7 @@ void __init omap3_map_io(void)static struct omap_globals omap4_globals = { .class =OMAP443X_CLASS , .tap =OMAP2_L4_IO_ADDRESS (OMAP443X_SCM_BASE ), - .ctrl =OMAP443X_CTRL_BASE ,/* FIXME: Move this to control core */ + .ctrl =OMAP443X_SCM_BASE , .ctrl_pad =OMAP443X_CTRL_BASE , .prm =OMAP4430_PRM_BASE , .cm =OMAP4430_CM_BASE ,
arch/arm/plat-omap/include/plat/control.h +0 -23
@@ -208,12 +208,6 @@#define OMAP3_PADCONF_SAD2D_MSTANDBY 0x250#define OMAP3_PADCONF_SAD2D_IDLEACK 0x254 -/* 44xx control status register offset */ -#define OMAP44XX_CONTROL_STATUS 0x2c4 - -/* 44xx-only CONTROL_GENERAL register offsets */ -#define OMAP44XX_CONTROL_MMC1 0x628 -#define OMAP44XX_CONTROL_PBIAS_LITE 0x600/* * REVISIT: This list of registers is not comprehensive - there are more * that should be added.
@@ -259,23 +253,6 @@#define OMAP2_PBIASLITEPWRDNZ0 (1 << 1)#define OMAP2_PBIASLITEVMODE0 (1 << 0) -/* CONTROL_PBIAS_LITE bits for OMAP4 */ -#define OMAP4_MMC1_PWRDNZ (1 << 26) -#define OMAP4_MMC1_PBIASLITE_HIZ_MODE (1 << 25) -#define OMAP4_MMC1_PBIASLITE_SUPPLY_HI_OUT (1 << 24) -#define OMAP4_MMC1_PBIASLITE_VMODE_ERROR (1 << 23) -#define OMAP4_MMC1_PBIASLITE_PWRDNZ (1 << 22) -#define OMAP4_MMC1_PBIASLITE_VMODE (1 << 21) -#define OMAP4_USBC1_ICUSB_PWRDNZ (1 << 20) - -#define OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP0 (1 << 31) -#define OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP1 (1 << 30) -#define OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP2 (1 << 29) -#define OMAP4_CONTROL_SDMMC1_PUSTRENGTHGRP3 (1 << 28) -#define OMAP4_CONTROL_SDMMC1_DR0_SPEEDCTRL (1 << 27) -#define OMAP4_CONTROL_SDMMC1_DR1_SPEEDCTRL (1 << 26) -#define OMAP4_CONTROL_SDMMC1_DR2_SPEEDCTRL (1 << 25) -/* CONTROL_PROG_IO1 bits */ #define OMAP3630_PRG_SDMMC1_SPEEDCTRL (1 << 20)
Signature · 1 line
1.6.0.4
PATCH 8/14 omap: sram: fix is_sram_locked check
From: Vikram Pandita <[email protected]>
For OMAP24xx/34xx/44xx: omap_type() returns the correct type:
OMAP2_DEVICE_TYPE_TEST
OMAP2_DEVICE_TYPE_EMU
OMAP2_DEVICE_TYPE_SEC
OMAP2_DEVICE_TYPE_GP
OMAP2_DEVICE_TYPE_BAD
In current implementation there are two problems:
Problem 1:
For 34xx, the current if check will never return true.
Problem 2:
For 24xx the correct type check should be with omap_type() function Verified by checking the TRM 24xx for CONTROL_STATUS register bits
--- arch/arm/plat-omap/sram.c | 11 +---------- 1 files changed, 1 insertions(+), 10 deletions(-)
arch/arm/plat-omap/sram.c +1 -10
@@ -93,16 +93,7 @@ extern unsigned long omapfb_reserve_sram(unsigned long sram_pstart,*/ static int is_sram_locked (void ) { -int type =0 ; - -if (cpu_is_omap44xx ()) -/* Not yet supported */ -return 0 ; - -if (cpu_is_omap242x ()) - type =omap_rev () &OMAP2_DEVICETYPE_MASK ; - -if (type ==GP_DEVICE ) { +if (OMAP2_DEVICE_TYPE_GP ==omap_type ()) {/* RAMFW: R/W access to all initiators for all qualifier sets */ if (cpu_is_omap242x ()) {__raw_writel (0xFF ,OMAP24XX_VA_REQINFOPERM0 );/* all q-vects */
Signature · 1 line
1.6.0.4
PATCH 9/14 omap4: sram: Fix start address
From: Vikram Pandita <[email protected]>
On OMAP4 there is no need to have SRAM_BOOTLOADER_SZ provision
Hence put this macro under CONFIG_ARCH_OMAP2PLUS check
--- arch/arm/plat-omap/sram.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
arch/arm/plat-omap/sram.c +1 -1
@@ -53,7 +53,7 @@#define OMAP4_SRAM_PUB_PA (OMAP4_SRAM_PA + 0x4000)#define OMAP4_SRAM_PUB_VA (OMAP4_SRAM_VA + 0x4000) -#if defined(CONFIG_ARCH_OMAP2 ) || defined(CONFIG_ARCH_OMAP3 ) +#if defined(CONFIG_ARCH_OMAP2PLUS )#define SRAM_BOOTLOADER_SZ 0x00#else #define SRAM_BOOTLOADER_SZ 0x80
Signature · 1 line
1.6.0.4
PATCH 10/14 omap4: Update id.c and cpu.h for es2.0
This patch updates the id.c and cpu.h files to support omap4 ES2.0 silicon detection.
--- arch/arm/mach-omap2/id.c | 29 ++++++++++++++++++++++------- arch/arm/plat-omap/include/plat/cpu.h | 5 ++++- 2 files changed, 26 insertions(+), 8 deletions(-)
arch/arm/mach-omap2/id.c +22 -7
@@ -298,7 +298,6 @@ static void __init omap4_check_revision(void)u32 idcode;u16 hawkeye;u8 rev; -char *rev_name ="ES1.0" ;/* * The IC rev detection is done with hawkeye and rev.
@@ -309,14 +308,30 @@ static void __init omap4_check_revision(void) hawkeye = (idcode >>12 ) &0xffff ; rev = (idcode >>28 ) &0xff ; -if ((hawkeye ==0xb852 ) && (rev ==0x0 )) { - omap_revision =OMAP4430_REV_ES1_0 ; - omap_chip.oc |=CHIP_IS_OMAP4430ES1 ; -pr_info ("OMAP%04x %s\n" ,omap_rev () >>16 , rev_name); -return ; +switch (hawkeye) { +case 0xb852 : +switch (rev) { +case 0 : + omap_revision =OMAP4430_REV_ES1_0 ; + omap_chip.oc |=CHIP_IS_OMAP4430ES1 ; +break ; +case 1 : + omap_revision =OMAP4430_REV_ES2_0 ; + omap_chip.oc |=CHIP_IS_OMAP4430ES2 ; +break ; +default : + omap_revision =OMAP4430_REV_ES2_0 ; + omap_chip.oc |=CHIP_IS_OMAP4430ES2 ; + } +break ; +default : +/* Unknown default to latest silicon rev as default*/ + omap_revision =OMAP4430_REV_ES2_0 ; + omap_chip.oc |=CHIP_IS_OMAP4430ES2 ; } -pr_err ("Unknown OMAP4 CPU id\n" ); +pr_info ("OMAP%04x ES%d.0\n" , +omap_rev () >>16 , ((omap_rev () >>12 ) &0xf ) +1 ); }#define OMAP3_SHOW_FEATURE (feat) \
arch/arm/plat-omap/include/plat/cpu.h +4 -1
@@ -391,6 +391,7 @@ IS_OMAP_TYPE(3517, 0x3517)#define OMAP443X_CLASS 0x44300044#define OMAP4430_REV_ES1_0 0x44300044 +#define OMAP4430_REV_ES2_0 0x44301044/* * omap_chip bits
@@ -417,10 +418,12 @@ IS_OMAP_TYPE(3517, 0x3517)#define CHIP_IS_OMAP4430ES1 (1 << 8)#define CHIP_IS_OMAP3630ES1_1 (1 << 9)#define CHIP_IS_OMAP3630ES1_2 (1 << 10) +#define CHIP_IS_OMAP4430ES2 (1 << 11)#define CHIP_IS_OMAP24XX (CHIP_IS_OMAP2420 | CHIP_IS_OMAP2430) -#define CHIP_IS_OMAP4430 (CHIP_IS_OMAP4430ES1) +#define CHIP_IS_OMAP4430 (CHIP_IS_OMAP4430ES1 | \ + CHIP_IS_OMAP4430ES2)/* * "GE" here represents "greater than or equal to" in terms of ES
Signature · 1 line
1.6.0.4
PATCH 11/14 omap4: Fix silicon version detection for early samples
Few initial omap4 es2 samples IDCODE is same as es1. This patch uses ARM cpuid register to detect the ES version for such samples
--- arch/arm/mach-omap2/id.c | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-)
arch/arm/mach-omap2/id.c +9 -0
@@ -308,6 +308,15 @@ static void __init omap4_check_revision(void) hawkeye = (idcode >>12 ) &0xffff ; rev = (idcode >>28 ) &0xff ; +/* +* Few initial ES2.0 samples IDCODE is same as ES1.0 +* Use ARM register to detect the correct ES version +*/ +if (!rev) { + idcode =read_cpuid (CPUID_ID ); + rev = (idcode &0xf ) -1 ; + } +switch (hawkeye) {case 0xb852 :switch (rev) {
Signature · 1 line
1.6.0.4
PATCH 12/14 omap4: l2x0: Fix init parameter for es2.0
On ES2.0 the L2 cache init parameter ineeds to be changed to take care of cache size. The cache size is 1MB on ES2.0 vs 512KB on ES1.0
This patch fixes the init parameter to update the same using dynamic cpu version check
--- arch/arm/mach-omap2/omap4-common.c | 10 +++++++--- 1 files changed, 7 insertions(+), 3 deletions(-)
arch/arm/mach-omap2/omap4-common.c +7 -3
@@ -61,10 +61,14 @@ static int __init omap_l2_cache_init(void)omap_smc1 (0x102 ,0x1 );/* -* 32KB way size, 16-way associativity, -* parity disabled +* 16-way associativity, parity disabled +* Way size - 32KB (es1.0) +* Way size - 64KB (es2.0 +) */ -l2x0_init (l2cache_base,0x0e050000 ,0xc0000fff ); +if (omap_rev () ==OMAP4430_REV_ES1_0 ) +l2x0_init (l2cache_base,0x0e050000 ,0xc0000fff ); +else +l2x0_init (l2cache_base,0x0e070000 ,0xc0000fff );return 0 ; }
Signature · 1 line
1.6.0.4
PATCH 13/14 omap4: Panda: Add DEBUG_LL support
From: David Anders <[email protected]>
Add support for use of DEBUG_LL for use with PandaBoard.
--- arch/arm/plat-omap/include/plat/uncompress.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/plat-omap/include/plat/uncompress.h +1 -0
@@ -153,6 +153,7 @@ static inline void __arch_decomp_setup(unsigned long arch_id)/* omap4 based boards using UART3 */ DEBUG_LL_OMAP4 (3 , omap_4430sdp); +DEBUG_LL_OMAP4 (3 , omap4_panda);/* zoom2/3 external uart */ DEBUG_LL_ZOOM (omap_zoom2);
Signature · 1 line
1.6.0.4
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
This patch is temporary fix to below crash. This is observed when CPU is clocked more than 600 MHz.
Unhandled fault: imprecise external abort (0x1406) at 0xbf9ef65c
Internal error: : 1406 [#1] PREEMPT SMP last sysfs file: Modules linked in: CPU: 0 Not tainted (2.6.36-rc3+ #18) PC is at kernel_thread_helper+0x0/0x14 LR is at kernel_thread_helper+0x0/0x14 pc : [<c003ce14>] lr : [<c003ce14>] psr: 00000093
sp : dc83bff8 ip : 00000000 fp : 00000000
r10: 00000000 r9 : 00000000 r8 : 00000000
r7 : 00000013 r6 : c003ce28 r5 : c008935c r4 : 00000000 r3 : 00000000 r2 : 00000000 r1 : 00000000 r0 : 00000000
Flags: nzcv IRQs off FIQs on Mode SVC_32 ISA ARM Segment kernel
Control: 10c53c7f Table: 8000404a DAC: 00000017
Process swapper (pid: 2, stack limit = 0xdc83a2f0)
Stack: (0xdc83bff8 to 0xdc83c000) bfe0: 00000000 ffffffff [<c003ce14>] (kernel_thread_helper+0x0/0x14) from [<fffffffe>] (0xfffffffe) Code: c03a0ba3 c03a5fcb c045c880 c0394035 (eb017701) ---[ end trace 1b75b31a2719ed1c ]---
The timer hwmod adaptation will eventually fix it in a proper way.
--- arch/arm/plat-omap/dmtimer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
arch/arm/plat-omap/dmtimer.c +1 -1
@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer *timer, int source)* When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );return ret; }
Signature · 1 line
1.6.0.4
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 48 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM
To: linux-omap at vger.kernel.org
Cc: linux-arm-kernel at lists.infradead.org; Shilimkar, Santosh; Nayak, Rajendra
Subject: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clocksThis patch is temporary fix to below crash. This is observed when CPU is clocked more than 600 MHz.
Unhandled fault: imprecise external abort (
0x1406) at0xbf9ef65cInternal error: : 1406 [#1] PREEMPT SMP last sysfs file: Modules linked in: CPU: 0 Not tainted (2.6.36-rc3+ #18) PC is at kernel_thread_helper+0x0/0x14 LR is at kernel_thread_helper+0x0/0x14 pc : [<c003ce14>] lr : [<c003ce14>] psr: 00000093sp :
dc83bff8ip : 00000000 fp : 00000000
r10: 00000000 r9 : 00000000 r8 : 00000000
r7 : 00000013 r6 :c003ce28r5 :c008935cr4 : 00000000 r3 : 00000000 r2 : 00000000 r1 : 00000000 r0 : 00000000
Flags: nzcv IRQs off FIQs on ModeSVC_32ISA ARM Segment kernel
Control:10c53c7fTable:8000404aDAC: 00000017
Process swapper (pid: 2, stack limit =0xdc83a2f0)Stack: (0xdc83bff8 to 0xdc83c000) bfe0: 00000000 ffffffff [<c003ce14>] (kernel_thread_helper+0x0/0x14) from [<fffffffe>] (0xfffffffe) Code: c03a0ba3 c03a5fcb c045c880 c0394035 (eb017701) ---[ end trace 1b75b31a2719ed1c ]---The timer hwmod adaptation will eventually fix it in a proper way.
Signed-off-by Rajendra Nayak <[email protected]>Signed-off-by Santosh Shilimkar <[email protected]>--- arch/arm/plat-omap/dmtimer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)arch/arm/plat-omap/dmtimer.c +0
-0
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct omap_dm_timer · line 585
Quoted 6 lines
arch/arm/plat-omap/dmtimer.c +1
-1@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer*timer, int source) * When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );
What is the rationale for this increase? Lets say we have a CPU bumped up to 1GHz or something will we have weird numbers again?
Regards,
Nishanth Menon
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 51 lines
-----Original Message-----
From: Menon, Nishanth
Sent: Friday, September 17, 2010 3:45 PM
To: Shilimkar, Santosh; linux-omap at vger.kernel.org
Cc: linux-arm-kernel at lists.infradead.org; Nayak, Rajendra
Subject: RE: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clocksQuoted 43 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM
To: linux-omap at vger.kernel.org
Cc: linux-arm-kernel at lists.infradead.org; Shilimkar, Santosh; Nayak, Rajendra
Subject: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clocksThis patch is temporary fix to below crash. This is observed when CPU is clocked more than 600 MHz.
Unhandled fault: imprecise external abort (
0x1406) at0xbf9ef65cInternal error: : 1406 [#1] PREEMPT SMP last sysfs file: Modules linked in: CPU: 0 Not tainted (2.6.36-rc3+ #18) PC is at kernel_thread_helper+0x0/0x14 LR is at kernel_thread_helper+0x0/0x14 pc : [<c003ce14>] lr : [<c003ce14>] psr: 00000093sp :
dc83bff8ip : 00000000 fp : 00000000
r10: 00000000 r9 : 00000000 r8 : 00000000
r7 : 00000013 r6 :c003ce28r5 :c008935cr4 : 00000000 r3 : 00000000 r2 : 00000000 r1 : 00000000 r0 : 00000000
Flags: nzcv IRQs off FIQs on ModeSVC_32ISA ARM Segment kernel
Control:10c53c7fTable:8000404aDAC: 00000017
Process swapper (pid: 2, stack limit =0xdc83a2f0)Stack: (0xdc83bff8 to 0xdc83c000) bfe0: 00000000 ffffffff [<c003ce14>] (kernel_thread_helper+0x0/0x14) from [<fffffffe>] (0xfffffffe) Code: c03a0ba3 c03a5fcb c045c880 c0394035 (eb017701) ---[ end trace 1b75b31a2719ed1c ]---The timer hwmod adaptation will eventually fix it in a proper way.
Signed-off-by Rajendra Nayak <[email protected]>Signed-off-by Santosh Shilimkar <[email protected]>--- arch/arm/plat-omap/dmtimer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
Quoted 14 lines
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct omap_dm_timer · line 585
Quoted 11 lines
arch/arm/plat-omap/dmtimer.c +1
-1@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer*timer, int source) * When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );What is the rationale for this increase? Lets say we have a CPU bumped up to 1GHz or something will we have weird numbers again?
This is the max what we need at any clock speed. As mentioned in commit "The timer hwmod adaptation will eventually fix it in a proper way"
Regards,
Santosh
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 3 lines
-----Original Message-----
From: Shilimkar, Santosh
Sent: Friday, September 17, 2010 5:17 AM
[..]
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM
[...]
Quoted 17 lines
Quoted 5 lines
arch/arm/plat-
Quoted 5 lines
--- arch/arm/plat-omap/dmtimer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)arch/arm/plat- renamed from arch/arm/plat-omap/dmtimer.c +0
-0
omap/dmtimer.cQuoted 11 lines
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct omap_dm_timer · line 585
Quoted 10 lines
index 44bafda..1d706cf 100644
arch/arm/plat-omap/dmtimer.c +1
-1@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer*timer, int source) * When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );What is the rationale for this increase? Lets say we have a CPU bumped
Quoted 5 lines
up
Quoted 2 lines
to 1GHz or something will we have weird numbers again?
This is the max what we need at any clock speed. As mentioned in commit "The timer hwmod adaptation will eventually fix it in a proper way"
Okay.. taking your word for it ;)
PS: hard coded numbers + delays makes the red blue and white lights in my head to go off..(it even makes the siren sound too) ;)
Regards,
Nishanth Menon
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 36 lines
-----Original Message-----
From: Menon, Nishanth
Sent: Friday, September 17, 2010 3:57 PM
To: Shilimkar, Santosh; linux-omap at vger.kernel.org
Cc: linux-arm-kernel at lists.infradead.org; Nayak, Rajendra
Subject: RE: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clocksQuoted 3 lines
-----Original Message-----
From: Shilimkar, Santosh
Sent: Friday, September 17, 2010 5:17 AM[..]
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM[...]
Quoted 10 lines
Quoted 5 lines
arch/arm/plat-
Quoted 5 lines
--- arch/arm/plat-omap/dmtimer.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)arch/arm/plat- renamed from arch/arm/plat-omap/dmtimer.c +0
-0
omap/dmtimer.cQuoted 4 lines
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct
Quoted 4 lines
index 44bafda..1d706cf 100644
arch/arm/plat-omap/dmtimer.c +0
-0@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct
omap_dm_timerQuoted 7 lines
Quoted 7 lines
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct omap_dm_timer *timer, int source) · line 584
Quoted 6 lines
arch/arm/plat-omap/dmtimer.c +1
-1*timer, int source) * When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );What is the rationale for this increase? Lets say we have a CPU bumped
Quoted 8 lines
Quoted 5 lines
up
Quoted 2 lines
to 1GHz or something will we have weird numbers again?
This is the max what we need at any clock speed. As mentioned in commit "The timer hwmod adaptation will eventually fix it in a proper way"
Okay.. taking your word for it ;)
This one I will ensure.
Quoted 3 lines
PS: hard coded numbers + delays makes the red blue and white lights in my head to go off..(it even makes the siren sound too) ;)
Second your thought. Infact I wasn't ok to push this patch to start with but it's needed till the timer hwmod gets merged
Regards,
Santosh
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
hi,
Quoted 2 lines · Santosh
Second your thought. Infact I wasn't ok to push this patch to start with but it's needed till the timer hwmod gets merged
to me, it just looks like "omap_test_timeout()" is timing out and that function is omap_dm_timer_set_source() is returning with a still-disabled clock.
could you check if you get "cm: Module associated with clock gpt<blablabla> didn't enabled in 100000 tries" message on your dmesg ??
Signature · 1 line
balbi
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 15 lines
-----Original Message-----
From: Balbi, Felipe
Sent: Friday, September 17, 2010 4:12 PM
To: Shilimkar, Santosh
Cc: Menon, Nishanth; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Nayak, Rajendra
Subject: Re: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clockshi,
Quoted 2 lines · Santosh
Second your thought. Infact I wasn't ok to push this patch to start with but it's needed till the timer hwmod gets merged
Quoted 7 lines
to me, it just looks like "
omap_test_timeout()" is timing out and that function isomap_dm_timer_set_source()is returning with a still-disabled clock.could you check if you get "cm: Module associated with clock gpt<blablabla> didn't enabled in 100000 tries" message on your dmesg ??
On OMAP4 specifically, the wait IDLEST support isn't there in the clock framework. This is taken care now in hwmod framework. With that we see that we don't need this delay anymore.
The delay change is there for some time. May be there were issue with wait IDLEST.
Regards,
Santosh
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Hi,
Quoted 6 lines · Santosh
On OMAP4 specifically, the wait IDLEST support isn't there in the clock framework. This is taken care now in hwmod framework. With that we see that we don't need this delay anymore.
The delay change is there for some time. May be there were issue with wait IDLEST.
ok, I see.
Kevin, any plans to remove this hack ?
Signature · 1 line
balbi
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
Quoted 16 lines
-----Original Message-----
From: Balbi, Felipe
Sent: Friday, September 17, 2010 4:49 PM
To: Shilimkar, Santosh
Cc: Balbi, Felipe; Menon, Nishanth; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Nayak, Rajendra; Kevin Hilman
Subject: Re: [PATCH 14/14] omap4: Fix bootup crash observed with higher CPU clocksHi,
Quoted 4 lines · Santosh
On OMAP4 specifically, the wait IDLEST support isn't there in the clock framework. This is taken care now in hwmod framework. With that we see that we don't need this delay anymore.
Quoted 7 lines
Quoted 2 lines
The delay change is there for some time. May be there were issue with wait IDLEST.
ok, I see.
Kevin, any plans to remove this hack ?
It's removed already in the timer hwmod series which is getting developed in parallel.
Regards,
PATCH 14/14 omap4: Fix bootup crash observed with higher CPU clocks
In reply to Menon, NishanthHi,
Quoted 9 lines · Nishanth
arch/arm/plat-omap/dmtimer.c int omap_dm_timer_set_source(struct omap_dm_timer · line 585
Quoted 7 lines
arch/arm/plat-omap/dmtimer.c +1
-1@@ -581,7 +581,7 @@ int omap_dm_timer_set_source(struct omap_dm_timer*timer, int source) * When the functional clock disappears, too quick writes seem * to cause an abort. XXX Is this still necessary? */ -__delay (150000 ); +__delay (300000 );What is the rationale for this increase? Lets say we have a CPU bumped up to 1GHz or something will we have weird numbers again?
yeah, I thought the _omap2_module_wait_ready() should handle that ??
Signature · 1 line
balbi
PATCH 11/14 omap4: Fix silicon version detection for early samples
In reply to Santosh ShilimkarQuoted 4 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM
[..]
Quoted 7 lines
arch/arm/mach-omap2/id.c +0
-0@@ -308,6 +308,15 @@ static void __init omap4_check_revision(void) hawkeye = (idcode >>12 ) &0xffff ; rev = (idcode >>28 ) &0xff ;
arch/arm/mach-omap2/id.c static void __init omap4_check_revision(void) · line 319
Quoted 10 lines
arch/arm/mach-omap2/id.c +9
-0+/* +* Few initial ES2.0 samples IDCODE is same as ES1.0 +* Use ARM register to detect the correct ES version +*/ +if (!rev) { + idcode =read_cpuid (CPUID_ID ); + rev = (idcode &0xf ) -1 ; + } +
Squash this to patch 10?
Regards,
Nishanth Menon
PATCH 11/14 omap4: Fix silicon version detection for early samples
Quoted 23 lines
-----Original Message-----
From: Menon, Nishanth
Sent: Friday, September 17, 2010 3:48 PM
To: Shilimkar, Santosh; linux-omap at vger.kernel.org
Cc: linux-arm-kernel at lists.infradead.org
Subject: RE: [PATCH 11/14] omap4: Fix silicon version detection for early samplesQuoted 4 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Friday, September 17, 2010 4:48 AM[..]
Quoted 8 lines
arch/arm/mach-omap2/id.c +0
-0@@ -308,6 +308,15 @@ static void __init omap4_check_revision(void) hawkeye = (idcode >>12 ) &0xffff ; rev = (idcode >>28 ) &0xff ;
Quoted 12 lines
arch/arm/mach-omap2/id.c static void __init omap4_check_revision(void) · line 319
Quoted 9 lines
arch/arm/mach-omap2/id.c +9
-0+/* +* Few initial ES2.0 samples IDCODE is same as ES1.0 +* Use ARM register to detect the correct ES version +*/ +if (!rev) { + idcode =read_cpuid (CPUID_ID ); + rev = (idcode &0xf ) -1 ; + } +Squash this to patch 10?
Actually this was kind of temporary patch and was suppose to be reverted later and hence I kept it separate.
Felipe, benoit suggested to have this change anyways considering it's just one check.
http://www.mail-archive.com/linux-omap at vger.kernel.org/msg34521.html
But now I think we can fold this into id patch itself. Will fold it into patch 10.
Regards,
Santosh
PATCH 5/14 omap4: control: Add accessor api's for pad control module
In reply to Santosh ShilimkarQuoted 11 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Santosh Shilimkar
Sent: Friday, September 17, 2010 4:48 AMOn OMAP4 control pad are not addressable from control core base. So the common omap_ctrl_read/write APIs breaks Hence export separate APIs to manage the omap4 pad control registers.
This APIs will work only for OMAP4
Cosmetic comment below:
Quoted 12 lines
Signed-off-by Santosh Shilimkar <[email protected]>--- arch/arm/mach-omap2/control.c | 18 ++++++++++++++++++ arch/arm/plat-omap/include/plat/control.h | 4 ++++ 2 files changed, 22 insertions(+), 0 deletions(-)arch/arm/mach-omap2/control.c +0
-0
arch/arm/mach-omap2/control.c static struct omap3_control_regs control_context; · line 141
Quoted 4 lines
arch/arm/mach-omap2/control.c +1
-0@@ -138,6 +138,7 @@ static struct omap3_control_regs control_context;#endif /* CONFIG_ARCH_OMAP3 && CONFIG_PM */ #define OMAP_CTRL_REGADDR (reg) (omap2_ctrl_base + (reg)) +#define OMAP_CTRL_PAD_REGADDR (reg) (omap4_ctrl_pad_base + (reg))
s/ OMAP_CTRL_PAD_REGADDR/OMAP4_CTRL_PAD_REGADDR ?
[...]
Regards,
Nishanth Menon
PATCH 3/14 davinci: map sram using MT_MEMORY_NONCACHED instead of MT_DEVICE
In reply to Santosh ShilimkarQuoted 8 lines · Santosh Shilimkar
On Davinci SRAM is mapped as
MT_DEVICEbecasue of the section mapping pre-requisite instead of intendedMT_MEMORY_NONCACHEDSince the section mapping limitation gets fixed with first patch in this series, the
MT_MEMORY_NONCACHEDcan be used now.Have not tested this, so somebody with Davinci hardware can try this out
Is this still true?
PATCH 3/14 davinci: map sram using MT_MEMORY_NONCACHED instead of MT_DEVICE
Quoted 14 lines
-----Original Message-----
From: Russell King - ARM Linux [mailto:linux at arm.linux.org.uk]
Sent: Friday, September 17, 2010 3:46 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 03/14] davinci: map sram usingMT_MEMORY_NONCACHEDinstead ofMT_DEVICEQuoted 3 lines · Santosh Shilimkar
On Davinci SRAM is mapped as
MT_DEVICEbecasue of the section mapping pre-requisite instead of intendedMT_MEMORY_NONCACHED
Quoted 7 lines
Quoted 5 lines
Since the section mapping limitation gets fixed with first patch in this series, the
MT_MEMORY_NONCACHEDcan be used now.Have not tested this, so somebody with Davinci hardware can try this out
Is this still true?
No it's not anymore..
It's already tested on Davinci by Kevin. I missed to remove that
PATCH 2/14 omap: Map only available sram memory
In reply to Santosh ShilimkarQuoted 2 lines · Santosh Shilimkar
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order
physical
Quoted 5 lines
of KBs. This patch maps only available sram and removes some non necessary
cpu_is_xxxchecks.On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
"this" should be expanded (otherwise it is unclear whether it refers to the original code or the new code.)
PATCH 2/14 omap: Map only available sram memory
Quoted 13 lines
-----Original Message-----
From: Russell King - ARM Linux [mailto:linux at arm.linux.org.uk]
Sent: Friday, September 17, 2010 3:46 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 02/14] omap: Map only available sram memoryQuoted 2 lines · Santosh Shilimkar
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order
physical
Quoted 8 lines
Quoted 5 lines
of KBs. This patch maps only available sram and removes some non necessary
cpu_is_xxxchecks.On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
"this" should be expanded (otherwise it is unclear whether it refers to the original code or the new code.)
Will fix the change log as below.
omap: Map only available sram memory
Currently we map 1 MB section while setting up SRAM on OMAPs Regardless of the actual memory. The physical OCM RAM available on OMAP SOCs is in order of KBs. This patch maps only available sram and cleans up some un-necessary cpu_is_xxx checks.
Mapping un-available or non-accessible(secure) memory on the newer ARM processor is dangerous. Because ARM CPUs can now speculatively prefetch, we should avoid mapping any no-existing or secure memory.
PATCH 2/14 omap: Map only available sram memory
In reply to Santosh ShilimkarQuoted 9 lines · Santosh Shilimkar
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order of KBs. This patch maps only available sram and removes some non necessary
cpu_is_xxxchecks.On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
Signed-off-by Santosh Shilimkar <[email protected]>
This hangs OMAP3 pandora:
[ 0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-20 [ 0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7), cr=10c53c7f [ 0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache [ 0.000000] Machine: Pandora Handheld Console [ 0.000000] Ignoring unrecognised tag 0x54410008 [ 0.000000] bootconsole [earlycon0] enabled [ 0.000000] Reserving 6422528 bytes SDRAM for VRAM [ 0.000000] Memory policy: ECC disabled, Data cache writeback [ 0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ 0.000000] SRAM: Mapped pa 0x40200000 to va 0xfe400000 size: 0x10000
(stuck here)
reverting this fixes the problem.
Quoted 56 lines
---
?arch/arm/plat-omap/sram.c | ? 25 +++++-------------------- ?1 files changed, 5 insertions(+), 20 deletions(-)arch/arm/plat-omap/sram.c +0
-13@@ -220,20 +220,7 @@ void __init omap_map_sram(void) ? ? ? ?if (omap_sram_size == 0) ? ? ? ? ? ? ? ?return; - ? ? ? if (cpu_is_omap24xx()) { - ? ? ? ? ? ? ? omap_sram_io_desc[0].virtual = OMAP2_SRAM_VA; - - ? ? ? ? ? ? ? base = OMAP2_SRAM_PA; - ? ? ? ? ? ? ? base = ROUND_DOWN(base, PAGE_SIZE); - ? ? ? ? ? ? ? omap_sram_io_desc[0].pfn = __phys_to_pfn(base); - ? ? ? } - ? ? ? ?if (cpu_is_omap34xx()) { - ? ? ? ? ? ? ? omap_sram_io_desc[0].virtual = OMAP3_SRAM_VA; - ? ? ? ? ? ? ? base = OMAP3_SRAM_PA; - ? ? ? ? ? ? ? base = ROUND_DOWN(base, PAGE_SIZE); - ? ? ? ? ? ? ? omap_sram_io_desc[0].pfn = __phys_to_pfn(base); -? ? ? ? ? ? ? ?/*
? ? ? ? ? ? ? ? * SRAM must be marked as non-cached on OMAP3 since the ? ? ? ? ? ? ? ? * CORE DPLL M2 divider change code (in SRAM) runs with thearch/arm/plat-omap/sram.c +5
-8@@ -244,13 +231,11 @@ void __init omap_map_sram(void) ? ? ? ? ? ? ? ?omap_sram_io_desc[0].type = MT_MEMORY_NONCACHED; ? ? ? ?} - ? ? ? if (cpu_is_omap44xx()) { - ? ? ? ? ? ? ? omap_sram_io_desc[0].virtual = OMAP4_SRAM_VA; - ? ? ? ? ? ? ? base = OMAP4_SRAM_PA; - ? ? ? ? ? ? ? base = ROUND_DOWN(base, PAGE_SIZE); - ? ? ? ? ? ? ? omap_sram_io_desc[0].pfn = __phys_to_pfn(base); - ? ? ? } - ? ? ? omap_sram_io_desc[0].length = 1024 * 1024; ? ? ?/* Use section desc */ + ? ? ? omap_sram_io_desc[0].virtual = omap_sram_base; + ? ? ? base = omap_sram_start; + ? ? ? base = ROUND_DOWN(base, PAGE_SIZE); + ? ? ? omap_sram_io_desc[0].pfn = __phys_to_pfn(base); + ? ? ? omap_sram_io_desc[0].length = ROUND_DOWN(omap_sram_size, PAGE_SIZE); ? ? ? ?iotable_init(omap_sram_io_desc, ARRAY_SIZE(omap_sram_io_desc)); ? ? ? ?printk(KERN_INFO "SRAM: Mapped pa 0x%08lx to va 0x%08lx size: 0x%lx\n", --1.6.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo at vger.kernel.org
More majordomo info at ?http://vger.kernel.org/majordomo-info.html
Tony Lindgren
maintainerPATCH 2/14 omap: Map only available sram memory
Quoted 27 lines · Grazvydas Ignotas
Quoted 9 lines · Santosh Shilimkar
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order of KBs. This patch maps only available sram and removes some non necessary
cpu_is_xxxchecks.On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
Signed-off-by Santosh Shilimkar <[email protected]>This hangs OMAP3 pandora:
[ 0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-20 [ 0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7), cr=10c53c7f [ 0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache [ 0.000000] Machine: Pandora Handheld Console [ 0.000000] Ignoring unrecognised tag 0x54410008 [ 0.000000] bootconsole [earlycon0] enabled [ 0.000000] Reserving 6422528 bytes SDRAM for VRAM [ 0.000000] Memory policy: ECC disabled, Data cache writeback [ 0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ 0.000000] SRAM: Mapped pa 0x40200000 to va 0xfe400000 size: 0x10000
Quoted 3 lines
(stuck here)
reverting this fixes the problem.
Hmm, boots fine here with overo. Any idea what in this patch breaks pandora?
Tony
PATCH 2/14 omap: Map only available sram memory
Quoted 39 lines
-----Original Message-----
From: Tony Lindgren [mailto:tony at atomide.com]
Sent: Saturday, October 02, 2010 4:23 AM
To: Grazvydas Ignotas
Cc: Shilimkar, Santosh; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Russell King - ARM Linux
Subject: Re: [PATCH 02/14] omap: Map only available sram memoryQuoted 10 lines · Grazvydas Ignotas
Quoted 8 lines · Santosh Shilimkar
Currently we map 1 MB section while setting up SRAM on OMAPs. The actual physcal OCM RAM available on OMAP SOCs is in order of KBs. This patch maps only available sram and removes some non necessary
cpu_is_xxxchecks.On the newer ARMs with speculation, this is dangerous and can result in untraceable aborts.
Quoted 8 lines
Quoted 1 line
Signed-off-by Santosh Shilimkar <[email protected]>This hangs OMAP3 pandora:
[ 0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-20 [ 0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7),cr=10c53c7f
Quoted 11 lines
[ 0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache [ 0.000000] Machine: Pandora Handheld Console [ 0.000000] Ignoring unrecognised tag 0x54410008 [ 0.000000] bootconsole [earlycon0] enabled [ 0.000000] Reserving 6422528 bytes SDRAM for VRAM [ 0.000000] Memory policy: ECC disabled, Data cache writeback [ 0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ 0.000000] SRAM: Mapped pa 0x40200000 to va 0xfe400000 size: 0x10000(stuck here)
Quoted 5 lines
Quoted 1 line
reverting this fixes the problem.
Hmm, boots fine here with overo. Any idea what in this patch breaks pandora?
The change in this patch is not board dependent really. Have tested this on 3430SDP. Pandora is OMAP3 based, right ?
Regards,
Santosh
PATCH 2/14 omap: Map only available sram memory
Quoted 19 lines
Quoted 19 lines
Quoted 7 lines
This hangs OMAP3 pandora:
[ ? ?0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-20
[ ? ?0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7),cr=10c53c7f
Quoted 11 lines
[ ? ?0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
[ ? ?0.000000] Machine: Pandora Handheld Console
[ ? ?0.000000] Ignoring unrecognised tag0x54410008
[ ? ?0.000000] bootconsole [earlycon0] enabled
[ ? ?0.000000] Reserving 6422528 bytes SDRAM for VRAM
[ ? ?0.000000] Memory policy: ECC disabled, Data cache writeback [ ? ?0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ ? ?0.000000] SRAM: Mapped pa0x40200000to va0xfe400000size:0x10000(stuck here)
Quoted 7 lines
Quoted 5 lines
Quoted 1 line
reverting this fixes the problem.
Hmm, boots fine here with overo. Any idea what in this patch breaks pandora?
The change in this patch is not board dependent really. Have tested this on 3430SDP. Pandora is OMAP3 based, right ?
OMAP3530 ES2.1, also tried on friend's beagleboard b5 (also ES2.1) and it has the same problem. Maybe it's because of older Cortex A8 used there, or I'm missing some errata workaround in defconfig.
BTW, hacking the size to 1M on top of your patch fixes the problem too:
base = omap_sram_start;
base = ROUND_DOWN(base, PAGE_SIZE);
omap_sram_io_desc[0].pfn = __phys_to_pfn(base);
- omap_sram_io_desc[0].length = ROUND_DOWN(omap_sram_size, PAGE_SIZE);
+ omap_sram_io_desc[0].length = 0x100000;
iotable_init(omap_sram_io_desc, ARRAY_SIZE(omap_sram_io_desc));PATCH 2/14 omap: Map only available sram memory
Quoted 40 lines
-----Original Message-----
From: Grazvydas Ignotas [mailto:notasas at gmail.com]
Sent: Monday, October 04, 2010 2:34 PM
To: Shilimkar, Santosh
Cc: Tony Lindgren; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Russell King - ARM Linux
Subject: Re: [PATCH 02/14] omap: Map only available sram memoryQuoted 8 lines
Quoted 8 lines
Quoted 7 lines
This hangs OMAP3 pandora:
[ ? ?0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-20
[ ? ?0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7),cr=10c53c7f
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
[ ? ?0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
[ ? ?0.000000] Machine: Pandora Handheld Console
[ ? ?0.000000] Ignoring unrecognised tag0x54410008
[ ? ?0.000000] bootconsole [earlycon0] enabled
[ ? ?0.000000] Reserving 6422528 bytes SDRAM for VRAM
[ ? ?0.000000] Memory policy: ECC disabled, Data cache writeback [ ? ?0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ ? ?0.000000] SRAM: Mapped pa0x40200000to va0xfe400000size:
0x10000Quoted 9 lines
Quoted 7 lines
Quoted 3 lines
(stuck here)
reverting this fixes the problem.
Hmm, boots fine here with overo. Any idea what in this patch breaks pandora?
The change in this patch is not board dependent really. Have tested this on 3430SDP. Pandora is OMAP3 based, right ?
OMAP3530 ES2.1, also tried on friend's beagleboard b5 (also ES2.1) and it has the same problem. Maybe it's because of older Cortex A8 used there, or I'm missing some errata workaround in defconfig.
Quoted 8 lines
BTW, hacking the size to 1M on top of your patch fixes the problem too:
base = omap_sram_start; base = ROUND_DOWN(base, PAGE_SIZE); omap_sram_io_desc[0].pfn = __phys_to_pfn(base);- omap_sram_io_desc[0].length = ROUND_DOWN(omap_sram_size,
PAGE_SIZE);
+ omap_sram_io_desc[0].length =0x100000;
This is the exact reason this patch is created :) So that you map only available memory instead of 1 MB
Quoted 1 line
iotable_init(omap_sram_io_desc, ARRAY_SIZE(omap_sram_io_desc));
PATCH 2/14 omap: Map only available sram memory
Quoted 55 lines
-----Original Message-----
From: linux-omap-owner at vger.kernel.org [mailto:linux-omap- owner at vger.kernel.org] On Behalf Of Shilimkar, Santosh
Sent: Monday, October 04, 2010 3:08 PM
To: Grazvydas Ignotas
Cc: Tony Lindgren; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Russell King - ARM Linux
Subject: RE: [PATCH 02/14] omap: Map only available sram memoryQuoted 13 lines
-----Original Message-----
From: Grazvydas Ignotas [mailto:notasas at gmail.com]
Sent: Monday, October 04, 2010 2:34 PM
To: Shilimkar, Santosh
Cc: Tony Lindgren; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Russell King - ARM Linux
Subject: Re: [PATCH 02/14] omap: Map only available sram memoryQuoted 5 lines
Quoted 5 lines
Quoted 5 lines
This hangs OMAP3 pandora:
[ ? ?0.000000] Linux version 2.6.36-rc6-next-20101001-00002-ge76bb53-dirty (notaz at pixelinis)
(gcc
Quoted 12 lines
Quoted 12 lines
Quoted 12 lines
Quoted 2 lines
version 4.3.3 (Sourcery G++ Lite 2009q1-20
[ ? ?0.000000] CPU: ARMv7 Processor [411fc082] revision 2 (ARMv7),cr=10c53c7f
Quoted 9 lines
[ ? ?0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
[ ? ?0.000000] Machine: Pandora Handheld Console
[ ? ?0.000000] Ignoring unrecognised tag0x54410008
[ ? ?0.000000] bootconsole [earlycon0] enabled
[ ? ?0.000000] Reserving 6422528 bytes SDRAM for VRAM
[ ? ?0.000000] Memory policy: ECC disabled, Data cache writeback [ ? ?0.000000] OMAP3430/3530 ES2.1 (l2cache iva sgx neon isp ) [ ? ?0.000000] SRAM: Mapped pa0x40200000to va0xfe400000size:Quoted 9 lines
0x10000Quoted 8 lines
Quoted 7 lines
Quoted 3 lines
(stuck here)
reverting this fixes the problem.
Hmm, boots fine here with overo. Any idea what in this patch breaks pandora?
The change in this patch is not board dependent really. Have tested
this
Quoted 8 lines
Quoted 1 line
on 3430SDP. Pandora is OMAP3 based, right ?
OMAP3530 ES2.1, also tried on friend's beagleboard b5 (also ES2.1) and it has the same problem. Maybe it's because of older Cortex A8 used there, or I'm missing some errata workaround in defconfig.
BTW, hacking the size to 1M on top of your patch fixes the problem too:
Quoted 9 lines
Quoted 6 lines
base = omap_sram_start; base = ROUND_DOWN(base, PAGE_SIZE); omap_sram_io_desc[0].pfn = __phys_to_pfn(base);- omap_sram_io_desc[0].length = ROUND_DOWN(omap_sram_size,
PAGE_SIZE);
+ omap_sram_io_desc[0].length =0x100000;This is the exact reason this patch is created :) So that you map only available memory instead of 1 MB
Quoted 1 line
iotable_init(omap_sram_io_desc, ARRAY_SIZE(omap_sram_io_desc));
Just booted latest mainline where this patch is already merged and my OMAP3630 boots fine
## Booting image at 80300000 ...
Image Name: Linux-2.6.36-rc6-00086-gd4e8aa3 Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 3242124 Bytes = 3.1 MB
Load Address: 80008000
Entry Point: 80008000
Verifying Checksum ... OK
OK
Starting kernel ...
Uncompressing Linux... done, booting the kernel.
[ 0.000000] Linux version 2.6.36-rc6-00086-gd4e8aa3 (a0393909 at a0393909-desktop) (gcc version 4.4.1 (Sourcery G++ Lite 2010q1-202) ) #1 Mon Oct 4 18:27:30 IST 2010 [ 0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c53c7f [ 0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache [ 0.000000] Machine: OMAP Zoom3 board [ 0.000000] Memory policy: ECC disabled, Data cache writeback [ 0.000000] OMAP3630 ES1.0 (l2cache iva sgx neon isp 192mhz_clk ) [ 0.000000] SRAM: Mapped pa 0x40208000 to va 0xfe408000 size: 0x8000 [ 0.000000] Built 1 zonelists in Zone order, mobility grouping on. Total pages: 32512 [ 0.000000] Kernel command line: root=/dev/ram0 rw mem=128M console=ttyS0,115200n8 noinitrd root=/dev/nfs rw nfsroot=172.24.190.46:/ubuntu/nfs-share/omap3_next/,nolock,tcp,rsize=4096,wsize=4096 ip=dhcp earlyprintk [ 0.000000] PID hash table entries: 512 (order: -1, 2048 bytes) [ 0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes) [ 0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes) [ 0.000000] Memory: 128MB = 128MB total [ 0.000000] Memory: 116148k/116148k available, 14924k reserved, 0K highmem [ 0.000000] Virtual kernel memory layout: [ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB) [ 0.000000] fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB) [ 0.000000] DMA : 0xffc00000 - 0xffe00000 ( 2 MB) [ 0.000000] vmalloc : 0xc8800000 - 0xf8000000 ( 760 MB) [ 0.000000] lowmem : 0xc0000000 - 0xc8000000 ( 128 MB) [ 0.000000] modules : 0xbf000000 - 0xc0000000 ( 16 MB) [ 0.000000] .init : 0xc0008000 - 0xc0047000 ( 252 kB) [ 0.000000] .text : 0xc0047000 - 0xc05e9000 (5768 kB) [ 0.000000] .data : 0xc0612000 - 0xc07e2900 (1859 kB) [ 0.000000] Hierarchical RCU implementation. [ 0.000000] RCU-based detection of stalled CPUs is disabled. [ 0.000000] Verbose stalled-CPUs detection is disabled. [ 0.000000] NR_IRQS:402 [ 0.000000] Clocking rate (Crystal/Core/MPU): 26.0/400/600 MHz [ 0.000000] (null): Could not get uart4_ick [ 0.000000] (null): Could not get uart4_fck [ 0.000000] Reprogramming SDRC clock to 400000000 Hz [ 0.000000] GPMC revision 5.0 [ 0.000000] IRQ: Found an INTC at 0xfa200000 (revision 4.0) with 96 interrupts [ 0.000000] Total of 96 interrupts on 1 active controller [ 0.000000] Could not get gpios_ick [ 0.000000] Could not get gpios_fck
----
Looks like for you " is_sram_locked" function is failing. There was a patch in my series from Vikram which was fixing this API.
Do you have this patch applied when you are trying this out ?
http://www.spinics.net/linux/lists/arm-kernel/msg98697.html
Regards,
Santosh
PATCH 2/14 omap: Map only available sram memory
Quoted 5 lines
Looks like for you "
is_sram_locked" function is failing. There was a patch in my series from Vikram which was fixing this API.Do you have this patch applied when you are trying this out ?
http://www.spinics.net/linux/lists/arm-kernel/msg98697.html
Well it looks like this only happens on linux-next (was using next-20101001 version) with this defconfig:
http://notaz.gp2x.de/misc/pnd/config_next_101001_2
this has yours and Vikram's patch you mentioned in. Using omap2plus_defconfig on linux-next or this "bad" defconfig on linux-omap boots fine, strange.
Tony Lindgren
maintainerPATCH 2/14 omap: Map only available sram memory
Quoted 6 lines · Grazvydas Ignotas
Quoted 5 lines
Looks like for you "
is_sram_locked" function is failing. There was a patch in my series from Vikram which was fixing this API.Do you have this patch applied when you are trying this out ?
http://www.spinics.net/linux/lists/arm-kernel/msg98697.html
Quoted 7 lines
Well it looks like this only happens on linux-next (was using next-20101001 version) with this defconfig:
http://notaz.gp2x.de/misc/pnd/config_next_101001_2this has yours and Vikram's patch you mentioned in. Using
omap2plus_defconfigon linux-next or this "bad" defconfig on linux-omap boots fine, strange.
Maybe you need to disable CONFIG_SMP still in for-next?
At least one patch is still missing there, that's the TLB broadcast patch we have in omap-testing and sitting in Russell's patch system.
Regards,
Tony
Tony Lindgren
maintainerPATCH 2/14 omap: Map only available sram memory
Quoted 15 lines · Tony Lindgren
Quoted 6 lines · Grazvydas Ignotas
Quoted 5 lines
Looks like for you "
is_sram_locked" function is failing. There was a patch in my series from Vikram which was fixing this API.Do you have this patch applied when you are trying this out ?
http://www.spinics.net/linux/lists/arm-kernel/msg98697.htmlQuoted 7 lines
Well it looks like this only happens on linux-next (was using next-20101001 version) with this defconfig:
http://notaz.gp2x.de/misc/pnd/config_next_101001_2this has yours and Vikram's patch you mentioned in. Using
omap2plus_defconfigon linux-next or this "bad" defconfig on linux-omap boots fine, strange.
Quoted 5 lines
Maybe you need to disable
CONFIG_SMPstill in for-next?At least one patch is still missing there, that's the TLB broadcast patch we have in omap-testing and sitting in Russell's patch system.
Hmm, no CONFIG_SMP at least in the config above.. Must be something else then.
Tony
PATCH 2/14 omap: Map only available sram memory
In reply to Grazvydas IgnotasQuoted 15 lines
-----Original Message-----
From: Grazvydas Ignotas [mailto:notasas at gmail.com]
Sent: Tuesday, October 05, 2010 5:14 AM
To: Shilimkar, Santosh
Cc: Tony Lindgren; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org; Russell King - ARM Linux
Subject: Re: [PATCH 02/14] omap: Map only available sram memoryQuoted 1 line
Looks like for you "
is_sram_locked" function is failing. There was apatch
Quoted 4 lines
in my series from Vikram which was fixing this API.
Do you have this patch applied when you are trying this out ?
http://www.spinics.net/linux/lists/arm-kernel/msg98697.html
Quoted 7 lines
Well it looks like this only happens on linux-next (was using next-20101001 version) with this defconfig:
http://notaz.gp2x.de/misc/pnd/config_next_101001_2this has yours and Vikram's patch you mentioned in. Using
omap2plus_defconfigon linux-next or this "bad" defconfig on linux-omap boots fine, strange.
Indeed strange. At least good to know that omap2plus_defconfig on linux-next is booting fine.
Tony Lindgren
maintainerPATCH 1/14 ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
In reply to Santosh ShilimkarQuoted 6 lines · Santosh Shilimkar
This patch populates the L1 entries for
MT_MEMORYandMT_MEMORY_NONCACHEDtypes so that at boot-up, we can map memories outside system memory at page level granularityPreviously the mapping was limiting to section level, which creates unnecessary addiotional mapping for which physical memory may not
Minor typo here, it should be "additional".
Tony
PATCH 1/14 ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
In reply to Santosh ShilimkarHi Santosh,
Quoted 20 lines · Santosh Shilimkar
This patch populates the L1 entries for
MT_MEMORYandMT_MEMORY_NONCACHEDtypes so that at boot-up, we can map memories outside system memory at page level granularityPreviously the mapping was limiting to section level, which creates unnecessary addiotional mapping for which physical memory may not present. On the newer ARM with speculation, this is dangerous and can result in untraceable aborts.
Signed-off-by Santosh Shilimkar <[email protected]>Reviewed-by Russell King <[email protected]>--- arch/arm/mm/mmu.c | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-)arch/arm/mm/mmu.c +0
-0
arch/arm/mm/mmu.c static struct mem_type mem_types[] = { · line 251
Quoted 6 lines
arch/arm/mm/mmu.c +3
-0@@ -246,6 +246,9 @@ static struct mem_type mem_types[] = { .domain = DOMAIN_USER, }, [MT_MEMORY] = { + .prot_pte =L_PTE_PRESENT |L_PTE_YOUNG |L_PTE_DIRTY | + L_PTE_USER | L_PTE_EXEC, + .prot_l1 = PMD_TYPE_TABLE,
Just a quick question - does this need to have L_PTE_USER? Is it read-only or it needs L_PTE_WRITE as well?
Thanks.
Signature · 1 line
Catalin
PATCH 1/14 ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
Quoted 27 lines
-----Original Message-----
From: Catalin Marinas [mailto:catalin.marinas at arm.com]
Sent: Wednesday, September 29, 2010 8:21 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 01/14] ARM: mmu: SetupMT_MEMORYandMT_MEMORY_NONCACHEDL1 entriesHi Santosh,
Quoted 1 line · Santosh Shilimkar
This patch populates the L1 entries for
MT_MEMORYand
MT_MEMORY_NONCACHEDQuoted 14 lines
types so that at boot-up, we can map memories outside system memory at page level granularity
Previously the mapping was limiting to section level, which creates unnecessary addiotional mapping for which physical memory may not present. On the newer ARM with speculation, this is dangerous and can result in untraceable aborts.
Signed-off-by Santosh Shilimkar <[email protected]>Reviewed-by Russell King <[email protected]>--- arch/arm/mm/mmu.c | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-)
Quoted 15 lines
arch/arm/mm/mmu.c static struct mem_type mem_types[] = { · line 251
Quoted 11 lines
arch/arm/mm/mmu.c +3
-0@@ -246,6 +246,9 @@ static struct mem_type mem_types[] = { .domain = DOMAIN_USER, }, [MT_MEMORY] = { + .prot_pte =L_PTE_PRESENT |L_PTE_YOUNG |L_PTE_DIRTY | + L_PTE_USER | L_PTE_EXEC, + .prot_l1 = PMD_TYPE_TABLE,Just a quick question - does this need to have
L_PTE_USER? Is it read-only or it needsL_PTE_WRITEas well?
I think you are right. It should have "L_PTE_WRITE" as well.
Regards,
Santosh
PATCH 1/14 ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
In reply to Catalin MarinasQuoted 18 lines · Catalin Marinas
Hi Santosh,
Quoted 15 lines · Santosh Shilimkar
This patch populates the L1 entries for
MT_MEMORYandMT_MEMORY_NONCACHEDtypes so that at boot-up, we can map memories outside system memory at page level granularityPreviously the mapping was limiting to section level, which creates unnecessary addiotional mapping for which physical memory may not present. On the newer ARM with speculation, this is dangerous and can result in untraceable aborts.
Signed-off-by Santosh Shilimkar <[email protected]>Reviewed-by Russell King <[email protected]>--- arch/arm/mm/mmu.c | 17 +++++++++++++++-- 1 files changed, 15 insertions(+), 2 deletions(-)
Quoted 14 lines
arch/arm/mm/mmu.c static struct mem_type mem_types[] = { · line 251
Quoted 11 lines
arch/arm/mm/mmu.c +3
-0@@ -246,6 +246,9 @@ static struct mem_type mem_types[] = { .domain = DOMAIN_USER, }, [MT_MEMORY] = { + .prot_pte =L_PTE_PRESENT |L_PTE_YOUNG |L_PTE_DIRTY | + L_PTE_USER | L_PTE_EXEC, + .prot_l1 = PMD_TYPE_TABLE,Just a quick question - does this need to have
L_PTE_USER? Is it read-only or it needsL_PTE_WRITEas well?
Eek. It should not have L_PTE_USER or else it will be accessible to userspace.
cover omap sram, omap4 control module and es2.0 support
In reply to Santosh ShilimkarSantosh,
Unfortunately, the kernel still cannot find MMC device and mount the root file system on my Panda ES2.0 8 layers board.
Did we miss some patches? The Ubuntu 2.6.35 kernel boots fine.
-Bryan
Quoted 74 lines · Santosh Shilimkar
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
The series contains
? ? ? ?- SRAM mapping fixes to avoid speculative aborts
? ? ? ?- omap4 control module support
? ? ? ?- Fixes for omap4 HS/GP detection
? ? ? ?- omap4 es2.0 fixes. MMC and ethernet fixes are queued in respective ? ? ? ? ?treesBoot tested with
omap3_defconfigon
? ? ? ? ? ? ? ? ? ? ? ?- OMAP4430 SPP
? ? ? ? ? ? ? ? ? ? ? ?- OMAP4 Panda
? ? ? ? ? ? ? ? ? ? ? ?- OMAP4 Blaze
? ? ? ? ? ? ? ? ? ? ? ?- OMAP3430 SDPThe following changes since commit
03a7ab083e4d619136d6f07ce70fa9de0bc436fc:
?Linus Torvalds (1):
? ? ? ?Mergegit://git.kernel.org/.../sfrench/cifs-2.6are available in the git repository at:
?git://dev.omapzoom.org/pub/scm/santosh/kernel-omap4-base.git omap_for_2.6.37
David Anders (1):
? ? ?omap4: Panda: AddDEBUG_LLsupportSantosh Shilimkar (11):
? ? ?ARM: mmu: SetupMT_MEMORYandMT_MEMORY_NONCACHEDL1 entries ? ? ?omap: Map only available sram memory
? ? ?davinci: map sram usingMT_MEMORY_NONCACHEDinstead ofMT_DEVICE? ? ?omap4: control: Addctrl_pad_basetoomap_globals
? ? ?omap4: control: Add accessor api's for pad control module ? ? ?omap4: control: Add the register definition headers
? ? ?omap4: control: Fix the control module register accesses ? ? ?omap4: Updateid.candcpu.hfor es2.0
? ? ?omap4: Fix silicon version detection for early samples ? ? ?omap4: l2x0: Fix init parameter for es2.0
? ? ?omap4: Fix bootup crash observed with higher CPU clocksVikram Pandita (2):
? ? ?omap: sram: fixis_sram_lockedcheck
? ? ?omap4: sram: Fix start address?arch/arm/mach-davinci/dm355.c ? ? ? ? ? ? ? ? ? ? ?| ? ?3 +- ?arch/arm/mach-davinci/dm365.c ? ? ? ? ? ? ? ? ? ? ?| ? ?3 +- ?arch/arm/mach-davinci/dm644x.c ? ? ? ? ? ? ? ? ? ? | ? ?3 +- ?arch/arm/mach-davinci/dm646x.c ? ? ? ? ? ? ? ? ? ? | ? ?3 +- ?arch/arm/mach-omap2/control.c ? ? ? ? ? ? ? ? ? ? ?| ? 25 + ?arch/arm/mach-omap2/hsmmc.c ? ? ? ? ? ? ? ? ? ? ? ?| ? 67 +- ?arch/arm/mach-omap2/id.c ? ? ? ? ? ? ? ? ? ? ? ? ? | ? 40 +- ?.../include/mach/ctrl_module_core_44xx.h ? ? ? ? ? | ?391 ++++++ ?.../include/mach/ctrl_module_pad_core_44xx.h ? ? ? | 1409 ++++++++++++++++++++ ?.../include/mach/ctrl_module_pad_wkup_44xx.h ? ? ? | ?236 ++++ ?.../include/mach/ctrl_module_wkup_44xx.h ? ? ? ? ? | ? 92 ++ ?arch/arm/mach-omap2/omap4-common.c ? ? ? ? ? ? ? ? | ? 10 +- ?arch/arm/mm/mmu.c ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? 17 +- ?arch/arm/plat-omap/common.c ? ? ? ? ? ? ? ? ? ? ? ?| ? ?3 +- ?arch/arm/plat-omap/dmtimer.c ? ? ? ? ? ? ? ? ? ? ? | ? ?2 +- ?arch/arm/plat-omap/include/plat/common.h ? ? ? ? ? | ? ?1 + ?arch/arm/plat-omap/include/plat/control.h ? ? ? ? ?| ? 31 +- ?arch/arm/plat-omap/include/plat/cpu.h ? ? ? ? ? ? ?| ? ?5 +- ?arch/arm/plat-omap/include/plat/uncompress.h ? ? ? | ? ?1 + ?arch/arm/plat-omap/sram.c ? ? ? ? ? ? ? ? ? ? ? ? ?| ? 38 +-?20 files changed, 2271 insertions(+), 109 deletions(-)
?create mode 100644arch/arm/mach-omap2/include/mach/ctrl_module_core_44xx.h?create mode 100644arch/arm/mach-omap2/include/mach/ctrl_module_pad_core_44xx.h?create mode 100644arch/arm/mach-omap2/include/mach/ctrl_module_pad_wkup_44xx.h?create mode 100644arch/arm/mach-omap2/include/mach/ctrl_module_wkup_44xx.h--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo at vger.kernel.org
More majordomo info at ?http://vger.kernel.org/majordomo-info.html
cover omap sram, omap4 control module and es2.0 support
Quoted 8 lines
-----Original Message-----
From: cooloney at gmail.com [mailto:cooloney at gmail.com] On Behalf Of Bryan Wu
Sent: Friday, September 17, 2010 8:36 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 support
Quoted 6 lines
Santosh,
Unfortunately, the kernel still cannot find MMC device and mount the root file system on my Panda ES2.0 8 layers board.
Did we miss some patches? The Ubuntu 2.6.35 kernel boots fine.
Use the patch posted by Madhu for MMC apart from this series
http://www.mail-archive.com/linux-omap at vger.kernel.org/msg34855.html
I didn't find any issues with my es2.0 Panda board. Kevin also tested his Panda where MMC worked well.
Not sure what is the problem with your board,
Regards,
Santosh
cover omap sram, omap4 control module and es2.0 support
In reply to Santosh ShilimkarHello Santosh
Quoted 2 lines · Santosh Shilimkar
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
Patch 6 is missing, could you please look into why?
Also, please split all of the SCM changes out into a separate series/branch since they will be going in through my tree. Am reviewing those now.
- Paul
cover omap sram, omap4 control module and es2.0 support
-----Original Message-----
Quoted 7 lines
From: Paul Walmsley [mailto:paul at pwsan.com]
Sent: Friday, September 17, 2010 11:21 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 support
Quoted 9 lines
Hello Santosh
Quoted 2 lines · Santosh Shilimkar
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
Patch 6 is missing, could you please look into why?
Mostly because of size of the patch, You can pick this from the below git link
Quoted 4 lines
Also, please split all of the SCM changes out into a separate series/branch since they will be going in through my tree. Am reviewing those now.
Ok done. I have split the series and kept scm changes on 'omap4_scm_2.6.37' head and rest on 'omap_for_2.6.37'
Regards,
Santosh
---
The following changes since commit 03a7ab083e4d619136d6f07ce70fa9de0bc436fc:
Linus Torvalds (1):
Merge git://git.kernel.org/.../sfrench/cifs-2.6
are available in the git repository at:
git://dev.omapzoom.org/pub/scm/santosh/kernel-omap4-base.git omap4_scm_2.6.37
Santosh Shilimkar (4):
omap4: control: Add ctrl_pad_base to omap_globals
omap4: control: Add accessor api's for pad control module
omap4: control: Add the register definition headers
omap4: control: Fix the control module register accesses
Tony Lindgren
maintainercover omap sram, omap4 control module and es2.0 support
Quoted 20 lines · Shilimkar, Santosh
-----Original Message-----
Quoted 7 lines
From: Paul Walmsley [mailto:paul at pwsan.com]
Sent: Friday, September 17, 2010 11:21 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 supportQuoted 9 lines
Hello Santosh
Quoted 2 lines · Santosh Shilimkar
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
Patch 6 is missing, could you please look into why?
Mostly because of size of the patch, You can pick this from the below git link
Quoted 6 lines
Quoted 4 lines
Also, please split all of the SCM changes out into a separate series/branch since they will be going in through my tree. Am reviewing those now.
Ok done. I have split the series and kept scm changes on 'omap4_scm_2.6.37' head and rest on 'omap_for_2.6.37'
Santosh, the "Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries" should get tested in the arm tree to avoid nasty surprises. Please do the following split:
1. A series for Russell to pull
ARM: mmu: Setup MT_MEMORY and MT_MEMORY_NONCACHED L1 entries
omap: Map only available sram memory
davinci: map sram using MT_MEMORY_NONCACHED instead of MT_DEVICE
You can add my Acked-by: Tony Lindgren <[email protected]> to the "Map only available sram memory" patch.
2. A series for me to pull
omap4: sram: Fix start address
omap4: Update id.c and cpu.h for es2.0
omap4: l2x0: Fix init parameter for es2.0
omap4: Panda: Add DEBUG_LL support
omap4: Fix bootup crash observed with higher CPU clocks
3. A series for Paul to pull (already in omap4_scm_2.6.37)
omap4: control: Add ctrl_pad_base to omap_globals
omap4: control: Add accessor api's for pad control module
omap4: control: Add the register definition headers
omap4: control: Fix the control module register accesses
Please base them either on v2.6.35 or v2.6.36-rc5.
Regards,
Tony
cover omap sram, omap4 control module and es2.0 support
Quoted 59 lines
-----Original Message-----
From: Tony Lindgren [mailto:tony at atomide.com]
Sent: Friday, September 24, 2010 6:43 AM
To: Shilimkar, Santosh
Cc: Paul Walmsley; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 supportQuoted 12 lines · Shilimkar, Santosh
-----Original Message-----
Quoted 11 lines
From: Paul Walmsley [mailto:paul at pwsan.com]
Sent: Friday, September 17, 2010 11:21 PM
To: Shilimkar, Santosh
Cc: linux-omap at vger.kernel.org; linux-arm-kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 supportHello Santosh
On Fri, 17 Sep 2010, Santosh Shilimkar wrote:
Quoted 10 lines
Quoted 5 lines
Quoted 2 lines
This is consolidated patch series targetted for 2.6.37 merge window. All of these patches have been already posted/reviewed on the list.
Patch 6 is missing, could you please look into why?
Mostly because of size of the patch, You can pick this from the below git link
Quoted 2 lines
Also, please split all of the SCM changes out into a separate series/branch since they will be going in through my tree. Am
reviewing
Quoted 3 lines
Quoted 2 lines
those now.
Ok done. I have split the series and kept scm changes on
'omap4_scm_2.6.37'
Quoted 1 line
head and rest on 'omap_for_2.6.37'
Santosh, the "Setup
MT_MEMORYandMT_MEMORY_NONCACHEDL1 entries" should get tested in the arm tree to avoid nasty surprises. Please do the following
split:1. A series for Russell to pull
ARM: mmu: SetupMT_MEMORYandMT_MEMORY_NONCACHEDL1 entries
omap: Map only available sram memory
davinci: map sram usingMT_MEMORY_NONCACHEDinstead ofMT_DEVICEYou can add my Acked-by: Tony Lindgren <[email protected]> to the "Map only available sram memory" patch.
2. A series for me to pull
omap4: sram: Fix start address
omap4: Updateid.candcpu.hfor es2.0
omap4: l2x0: Fix init parameter for es2.0
omap4: Panda: AddDEBUG_LLsupport
omap4: Fix bootup crash observed with higher CPU clocks
Quoted 8 lines
3. A series for Paul to pull (already in omap4_scm_2.6.37)
omap4: control: Addctrl_pad_basetoomap_globals
omap4: control: Add accessor api's for pad control module
omap4: control: Add the register definition headers
omap4: control: Fix the control module register accessesPlease base them either on v2.6.35 or v2.6.36-rc5.
Will do arrange patches as you suggested.
Regards,
Santosh
cover omap sram, omap4 control module and es2.0 support
In reply to Tony LindgrenTony,
Quoted 9 lines
-----Original Message-----
From: Tony Lindgren [mailto:tony at atomide.com]
Sent: Friday, September 24, 2010 6:43 AM
To: Shilimkar, Santosh
Cc: Paul Walmsley; linux-omap at vger.kernel.org; linux-arm- kernel at lists.infradead.org
Subject: Re: [PATCH 00/14] omap sram, omap4 control module and es2.0 support
<snip..>
Quoted 5 lines
Santosh, the "Setup
MT_MEMORYandMT_MEMORY_NONCACHEDL1 entries" should get tested in the arm tree to avoid nasty surprises. Please do the following
split:
Quoted 7 lines
1. A series for Russell to pull
ARM: mmu: SetupMT_MEMORYandMT_MEMORY_NONCACHEDL1 entries
omap: Map only available sram memory
davinci: map sram usingMT_MEMORY_NONCACHEDinstead ofMT_DEVICEYou can add my Acked-by: Tony Lindgren <[email protected]> to the "Map only available sram memory" patch.
Have submitted above three patches to RMK's patch system with your ack on the mentioned patch
- patch 6407/1 - patch 6408/1 - patch 6409/1
They are also available at:git://dev.omapzoom.org/pub/scm/santosh/kernel-omap4-base.git
omap_for_2.6.37-rmk
Quoted 8 lines
2. A series for me to pull
omap4: sram: Fix start address
omap4: Updateid.candcpu.hfor es2.0
omap4: l2x0: Fix init parameter for es2.0
omap4: Panda: AddDEBUG_LLsupport
omap4: Fix bootup crash observed with higher CPU clocks
The pull request is sent to you with patches rebased on v2.6.36-rc5
Quoted 6 lines
3. A series for Paul to pull (already in omap4_scm_2.6.37)
omap4: control: Addctrl_pad_basetoomap_globals
omap4: control: Add accessor api's for pad control module
omap4: control: Add the register definition headers
omap4: control: Fix the control module register accesses
This series is already available. I just rebased on v2.6.36-rc5 as you suggested.
Regards,
Santosh