diff mbox

[1/2] Macro for getting the BASEADDRESS field in omap's gpmc configuration

Message ID 1312470395-19672-1-git-send-email-david.wagner@free-electrons.com (mailing list archive)
State New, archived
Headers show

Commit Message

david.wagner@free-electrons.com Aug. 4, 2011, 3:06 p.m. UTC
BASEADDRESS is located in the 6 lower bits of the CONFIG7 register.
See OMAP 35x Technical Reference Manual, p. 1169.

Signed-off-by: David Wagner <david.wagner@free-electrons.com>
---
 arch/arm/plat-omap/include/plat/gpmc.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Comments

david.wagner@free-electrons.com Aug. 11, 2011, 3 p.m. UTC | #1
Hi,

On 08/04/2011 05:06 PM, David Wagner wrote:
> BASEADDRESS is located in the 6 lower bits of the CONFIG7 register.
> See OMAP 35x Technical Reference Manual, p. 1169.
> 
> Signed-off-by: David Wagner <david.wagner@free-electrons.com>

I'm not subscribed to the linux-omap mailing list but I saw no answer on
this patch and the next one in the archive.

The second one (replaces bitwise operations in board-igep0020.c with
GPMC macros) partly depends on the first one, but can be split so that
part of it can be standalone. Should I do so and resubmit or is it ok
like this ?

Regards,
David.
diff mbox

Patch

diff --git a/arch/arm/plat-omap/include/plat/gpmc.h b/arch/arm/plat-omap/include/plat/gpmc.h
index 1527929..154456d 100644
--- a/arch/arm/plat-omap/include/plat/gpmc.h
+++ b/arch/arm/plat-omap/include/plat/gpmc.h
@@ -72,6 +72,7 @@ 
 #define GPMC_CONFIG1_FCLK_DIV3          (GPMC_CONFIG1_FCLK_DIV(2))
 #define GPMC_CONFIG1_FCLK_DIV4          (GPMC_CONFIG1_FCLK_DIV(3))
 #define GPMC_CONFIG7_CSVALID		(1 << 6)
+#define GPMC_CONFIG7_BASEADDRESS(val)	(val & 0x3F)
 
 #define GPMC_DEVICETYPE_NOR		0
 #define GPMC_DEVICETYPE_NAND		2