forked from len0rd/rockbox
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
This commit is contained in:
parent
bd544b6c20
commit
9d67765cae
1 changed files with 5 additions and 16 deletions
|
@ -89,20 +89,12 @@ inline void lcd_begin_write_gram(void)
|
||||||
*(volatile unsigned short *)0xf0000000 = R_WRITE_DATA_2_GRAM;
|
*(volatile unsigned short *)0xf0000000 = R_WRITE_DATA_2_GRAM;
|
||||||
}
|
}
|
||||||
|
|
||||||
void lcd_write_data(const unsigned short* p_bytes, int count) ICODE_ATTR;
|
/* called very frequently - inline! */
|
||||||
void lcd_write_data(const unsigned short* p_bytes, int count)
|
inline void lcd_write_data(const unsigned short* p_bytes, int count) ICODE_ATTR;
|
||||||
|
inline void lcd_write_data(const unsigned short* p_bytes, int count)
|
||||||
{
|
{
|
||||||
SAR1 = (unsigned long)p_bytes; /* Destination address */
|
while(count--)
|
||||||
while(count)
|
*(volatile unsigned short *)0xf0000002 = *p_bytes++;
|
||||||
{
|
|
||||||
int cnt = MIN(count, 256);
|
|
||||||
DAR1 = (unsigned long)0xf0000002; /* Destination address */
|
|
||||||
BCR1 = cnt*2; /* Bytes to transfer */
|
|
||||||
DCR1 = 0x02000000 | DMA_SINC | (2 << 20) | (2 << 17) | DMA_START;
|
|
||||||
while(!(DSR1 & 1)) {};
|
|
||||||
DSR1 = 1;
|
|
||||||
count -= cnt;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*** hardware configuration ***/
|
/*** hardware configuration ***/
|
||||||
|
@ -139,9 +131,6 @@ void lcd_roll(int lines)
|
||||||
/* LCD init */
|
/* LCD init */
|
||||||
void lcd_init_device(void)
|
void lcd_init_device(void)
|
||||||
{
|
{
|
||||||
MPARK = 0x81; /* PARK[1,0]=10 + BCR24BIT */
|
|
||||||
DSR1 = 1;
|
|
||||||
|
|
||||||
/* GPO46 is LCD RESET */
|
/* GPO46 is LCD RESET */
|
||||||
or_l(0x00004000, &GPIO1_OUT);
|
or_l(0x00004000, &GPIO1_OUT);
|
||||||
or_l(0x00004000, &GPIO1_ENABLE);
|
or_l(0x00004000, &GPIO1_ENABLE);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue