]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
OMAP2: Add funcs for writing SMS_ROT_* registers
authorTomi Valkeinen <tomi.valkeinen@nokia.com>
Fri, 7 Aug 2009 08:26:12 +0000 (11:26 +0300)
committerTomi Valkeinen <tomi.valkeinen@nokia.com>
Wed, 9 Dec 2009 09:44:32 +0000 (11:44 +0200)
SMS_ROT_* registers are used by VRFB rotation engine.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
arch/arm/mach-omap2/sdrc.c
arch/arm/plat-omap/include/plat/sdrc.h

index 9a592199321c5330237faf303500149356604270..cbfbd142e946662fe1b4d6588873a79273aa4bfa 100644 (file)
@@ -160,3 +160,19 @@ void __init omap2_sdrc_init(struct omap_sdrc_params *sdrc_cs0,
        sdrc_write_reg(l, SDRC_POWER);
        omap2_sms_save_context();
 }
+
+void omap2_sms_write_rot_control(u32 val, unsigned ctx)
+{
+       sms_write_reg(val, SMS_ROT_CONTROL(ctx));
+}
+
+void omap2_sms_write_rot_size(u32 val, unsigned ctx)
+{
+       sms_write_reg(val, SMS_ROT_SIZE(ctx));
+}
+
+void omap2_sms_write_rot_physical_ba(u32 val, unsigned ctx)
+{
+       sms_write_reg(val, SMS_ROT_PHYSICAL_BA(ctx));
+}
+
index f704030d2a701f434eeb0defac83637330cb878c..7b76f50564ba543c1626df470383c3b58c55afa9 100644 (file)
 
 /* SMS register offsets - read/write with sms_{read,write}_reg() */
 
-#define SMS_SYSCONFIG          0x010
+#define SMS_SYSCONFIG                  0x010
+#define SMS_ROT_CONTROL(context)       (0x180 + 0x10 * context)
+#define SMS_ROT_SIZE(context)          (0x184 + 0x10 * context)
+#define SMS_ROT_PHYSICAL_BA(context)   (0x188 + 0x10 * context)
 /* REVISIT: fill in other SMS registers here */
 
 
@@ -129,6 +132,10 @@ int omap2_sdrc_get_params(unsigned long r,
 void omap2_sms_save_context(void);
 void omap2_sms_restore_context(void);
 
+void omap2_sms_write_rot_control(u32 val, unsigned ctx);
+void omap2_sms_write_rot_size(u32 val, unsigned ctx);
+void omap2_sms_write_rot_physical_ba(u32 val, unsigned ctx);
+
 #ifdef CONFIG_ARCH_OMAP2
 
 struct memory_timings {