summaryrefslogtreecommitdiffstats
path: root/firmware/export/rk27xx.h
diff options
context:
space:
mode:
authorAndrew Ryabinin <ryabinin.a.a@gmail.com>2012-09-25 11:41:12 +0400
committerMarcin Bukat <marcin.bukat@gmail.com>2012-09-27 09:42:44 +0200
commit84134f737fc4643cad5eb50fef3bae0df657f054 (patch)
treeb2b0b28a4723a2eef9a340f6bc7a18e796ab1b5b /firmware/export/rk27xx.h
parentf636aa07dfb541b5828d44e8168e7b36e5ad8898 (diff)
downloadrockbox-84134f737fc4643cad5eb50fef3bae0df657f054.tar.gz
rockbox-84134f737fc4643cad5eb50fef3bae0df657f054.zip
rk27xx lcd code rework
Use DMA engine for fullscreen updates and bypass mode for partial updates. This gives major boost on rk27generic: default ARM:AHB:APB 200:100:50 HEAD 1/1: 26.3fps 1/4: 105.0fps patched 1/1: 116.5fps 1/4: 249.5fps with freq scalling NORMAL mode ARM:AHB:APB 50:50:50 HEAD 1/1: 13.1fps 1/4: 52.5fps patched 1/1: 54.5fps 1/4: 119.0fps Tested on rk27generic noname DAP and on Hifimans. Change-Id: Id9dd4d2d61542c7ea6b5c6336b170d6357cefde9
Diffstat (limited to 'firmware/export/rk27xx.h')
-rw-r--r--firmware/export/rk27xx.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/firmware/export/rk27xx.h b/firmware/export/rk27xx.h
index d1b9758f65..c75004c5f7 100644
--- a/firmware/export/rk27xx.h
+++ b/firmware/export/rk27xx.h
@@ -846,10 +846,10 @@
#define VERT_PERIOD (*(volatile unsigned long *)(AHB1_LCDC + 0x0C))
#define HOR_PW (*(volatile unsigned long *)(AHB1_LCDC + 0x10))
#define VERT_PW (*(volatile unsigned long *)(AHB1_LCDC + 0x14))
-#define HOR_ACT (*(volatile unsigned long *)(AHB1_LCDC + 0x18))
-#define VERT_ACT (*(volatile unsigned long *)(AHB1_LCDC + 0x1C))
-#define HOR_BP (*(volatile unsigned long *)(AHB1_LCDC + 0x20))
-#define VERT_BP (*(volatile unsigned long *)(AHB1_LCDC + 0x24))
+#define HOR_BP (*(volatile unsigned long *)(AHB1_LCDC + 0x18))
+#define VERT_BP (*(volatile unsigned long *)(AHB1_LCDC + 0x1C))
+#define HOR_ACT (*(volatile unsigned long *)(AHB1_LCDC + 0x20))
+#define VERT_ACT (*(volatile unsigned long *)(AHB1_LCDC + 0x24))
#define LINE0_YADDR (*(volatile unsigned long *)(AHB1_LCDC + 0x28))
#define LINE_ALPHA_EN (1<<14)
#define LINE_SCALE_EN (1<<13)
@@ -877,13 +877,23 @@
#define INTR_MASK_VERT (1<<1)
#define INTR_MASK_HOR (1<<0)
+#define ALPHA_ALX (*(volatile unsigned long *)(AHB1_LCDC + 0x5C))
+#define ALPHA_ATY (*(volatile unsigned long *)(AHB1_LCDC + 0x60))
+#define ALPHA_ARX (*(volatile unsigned long *)(AHB1_LCDC + 0x64))
+#define ALPHA_ABY (*(volatile unsigned long *)(AHB1_LCDC + 0x68))
+
+#define ALPHA_BLX (*(volatile unsigned long *)(AHB1_LCDC + 0x6C))
+#define ALPHA_BTY (*(volatile unsigned long *)(AHB1_LCDC + 0x70))
+#define ALPHA_BRX (*(volatile unsigned long *)(AHB1_LCDC + 0x74))
+#define ALPHA_BBY (*(volatile unsigned long *)(AHB1_LCDC + 0x78))
+
#define LCDC_STA (*(volatile unsigned long *)(AHB1_LCDC + 0x7C))
#define LCDC_MCU_IDLE (1<<12)
#define LCD_COMMAND (*(volatile unsigned long *)(AHB1_LCDC + 0x1000))
#define LCD_DATA (*(volatile unsigned long *)(AHB1_LCDC + 0x1004))
-#define LCD_BUFF (*(volatile unsigned long *)(AHB1_LCDC + 0x2000))
+#define LCD_BUFF ((volatile void *)(AHB1_LCDC + 0x2000))
/* High speed ADC interface */
#define AHB1_HS_ADC 0x186EC000
#define HSADC_DATA (*(volatile unsigned long *)(AHB1_HS_ADC + 0x00))