From 92411e8a96d9658022787530b564ff5926b18387 Mon Sep 17 00:00:00 2001 From: Rafaël Carré Date: Thu, 1 Apr 2010 08:29:30 +0000 Subject: Fuzev2 LCD: replace delays by calls to lcd_delay() (delays not changed) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25422 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/as3525/sansa-fuzev2/lcd-fuzev2.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'firmware/target/arm/as3525') diff --git a/firmware/target/arm/as3525/sansa-fuzev2/lcd-fuzev2.c b/firmware/target/arm/as3525/sansa-fuzev2/lcd-fuzev2.c index 7e5b30d122..53d8f73904 100644 --- a/firmware/target/arm/as3525/sansa-fuzev2/lcd-fuzev2.c +++ b/firmware/target/arm/as3525/sansa-fuzev2/lcd-fuzev2.c @@ -115,7 +115,6 @@ static void as3525_dbop_init(void) static inline void dbop_set_mode(int mode) { - int delay = 10; unsigned long ctrl = DBOP_CTRL; int words = (ctrl >> 13) & 3; // bits 14:13 if (mode == 32 && words != 2) @@ -124,7 +123,7 @@ static inline void dbop_set_mode(int mode) DBOP_CTRL = (ctrl & ~(1<<14)) | (1<<13); // 2 serial words else return; - while(delay--) asm volatile("nop"); + lcd_delay(10); } static void dbop_write_data(const int16_t* p_bytes, int count) @@ -166,7 +165,7 @@ static void dbop_write_data(const int16_t* p_bytes, int count) static void lcd_write_cmd(unsigned short cmd) { volatile int i; - for(i=0;i<0x20;i++) asm volatile ("nop\n"); + lcd_delay(0x20); DBOP_CTRL |= 1<<13; DBOP_CTRL &= ~(1<<14); // 2 serial words -- cgit v1.2.3