From: Juha Yrjola Date: Tue, 20 Jun 2006 13:10:41 +0000 (+0300) Subject: ARM: OMAP: dmtimers need longer delay when changing source clock X-Git-Tag: v2.6.17-omap1~16 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=58af3dbc8503314c7f8eceef56f39680ee8de42f;p=linux-2.6-omap-h63xx.git ARM: OMAP: dmtimers need longer delay when changing source clock On OMAP2420, when running MPU at high frequencies, dmtimers need to have a longer delay for the new functional clock to be active. Signed-off-by: Juha Yrjola --- diff --git a/arch/arm/plat-omap/dmtimer.c b/arch/arm/plat-omap/dmtimer.c index 804a5353437..808cce9b680 100644 --- a/arch/arm/plat-omap/dmtimer.c +++ b/arch/arm/plat-omap/dmtimer.c @@ -338,7 +338,7 @@ void omap_dm_timer_set_source(struct omap_dm_timer *timer, int source) /* When the functional clock disappears, too quick writes seem to * cause an abort. */ - __delay(15000); + __delay(150000); } #endif diff --git a/drivers/spi/omap2_mcspi.c b/drivers/spi/omap2_mcspi.c index 2c7cd54fa85..1a72872d695 100644 --- a/drivers/spi/omap2_mcspi.c +++ b/drivers/spi/omap2_mcspi.c @@ -426,7 +426,10 @@ static void omap2_mcspi_work(unsigned long arg) omap2_mcspi_txrx(spi, t); if (t->cs_change) { - omap2_mcspi_force_cs(spi, 0); + /* In the last transfer entry the flag means + * _leave_ CS on */ + if (t->transfer_list.next != &m->transfers) + omap2_mcspi_force_cs(spi, 0); cs_active = 0; } }