diff options
author | Linus Nielsen Feltzing <linus@haxx.se> | 2005-12-22 09:33:39 +0000 |
---|---|---|
committer | Linus Nielsen Feltzing <linus@haxx.se> | 2005-12-22 09:33:39 +0000 |
commit | 9d67765cae62e873c3d004bf9bcb68947f1568f6 (patch) | |
tree | 48cbefd4bb90a72927ca4a5bb4cf9f0821cc1b0a /firmware | |
parent | bd544b6c20819d12d9262890ec498492ca171444 (diff) | |
download | rockbox-9d67765cae62e873c3d004bf9bcb68947f1568f6.tar.gz rockbox-9d67765cae62e873c3d004bf9bcb68947f1568f6.zip |
Reverted the H300 LCD DMA patch, since it iterfered with the recording DMA
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8279 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/drivers/lcd-h300.c | 21 |
1 files changed, 5 insertions, 16 deletions
diff --git a/firmware/drivers/lcd-h300.c b/firmware/drivers/lcd-h300.c index 149062be96..bb2f9ec777 100644 --- a/firmware/drivers/lcd-h300.c +++ b/firmware/drivers/lcd-h300.c | |||
@@ -89,20 +89,12 @@ inline void lcd_begin_write_gram(void) | |||
89 | *(volatile unsigned short *)0xf0000000 = R_WRITE_DATA_2_GRAM; | 89 | *(volatile unsigned short *)0xf0000000 = R_WRITE_DATA_2_GRAM; |
90 | } | 90 | } |
91 | 91 | ||
92 | void lcd_write_data(const unsigned short* p_bytes, int count) ICODE_ATTR; | 92 | /* called very frequently - inline! */ |
93 | void lcd_write_data(const unsigned short* p_bytes, int count) | 93 | inline void lcd_write_data(const unsigned short* p_bytes, int count) ICODE_ATTR; |
94 | inline void lcd_write_data(const unsigned short* p_bytes, int count) | ||
94 | { | 95 | { |
95 | SAR1 = (unsigned long)p_bytes; /* Destination address */ | 96 | while(count--) |
96 | while(count) | 97 | *(volatile unsigned short *)0xf0000002 = *p_bytes++; |
97 | { | ||
98 | int cnt = MIN(count, 256); | ||
99 | DAR1 = (unsigned long)0xf0000002; /* Destination address */ | ||
100 | BCR1 = cnt*2; /* Bytes to transfer */ | ||
101 | DCR1 = 0x02000000 | DMA_SINC | (2 << 20) | (2 << 17) | DMA_START; | ||
102 | while(!(DSR1 & 1)) {}; | ||
103 | DSR1 = 1; | ||
104 | count -= cnt; | ||
105 | } | ||
106 | } | 98 | } |
107 | 99 | ||
108 | /*** hardware configuration ***/ | 100 | /*** hardware configuration ***/ |
@@ -139,9 +131,6 @@ void lcd_roll(int lines) | |||
139 | /* LCD init */ | 131 | /* LCD init */ |
140 | void lcd_init_device(void) | 132 | void lcd_init_device(void) |
141 | { | 133 | { |
142 | MPARK = 0x81; /* PARK[1,0]=10 + BCR24BIT */ | ||
143 | DSR1 = 1; | ||
144 | |||
145 | /* GPO46 is LCD RESET */ | 134 | /* GPO46 is LCD RESET */ |
146 | or_l(0x00004000, &GPIO1_OUT); | 135 | or_l(0x00004000, &GPIO1_OUT); |
147 | or_l(0x00004000, &GPIO1_ENABLE); | 136 | or_l(0x00004000, &GPIO1_ENABLE); |