watchdog: sbc_fitpc2_wdt: fixed I/O operations order

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linux Kernel Mailing List
Date: Wednesday, April 28, 2010 - 1:59 pm

Gitweb:     http://git.kernel.org/linus/fcf1dd7e68ceb6420478c8d89d35b4745d0b2f42
Commit:     fcf1dd7e68ceb6420478c8d89d35b4745d0b2f42
Parent:     86913315de5ed13debd1566dfea15c4179b1f0c0
Author:     Denis Turischev <denis@compulab.co.il>
AuthorDate: Thu Apr 22 19:50:03 2010 +0300
Committer:  Wim Van Sebroeck <wim@iguana.be>
CommitDate: Mon Apr 26 18:17:34 2010 +0000

    watchdog: sbc_fitpc2_wdt: fixed I/O operations order
    
    There are fitpc2 compatible boards that hang with existent i/o
    operations order. Solution is to switch between writing to data
    and command ports.
    
    Signed-off-by: Denis Turischev <denis@compulab.co.il>
    Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
---
 drivers/watchdog/sbc_fitpc2_wdt.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/watchdog/sbc_fitpc2_wdt.c b/drivers/watchdog/sbc_fitpc2_wdt.c
index 8d44c9b..2e44dd4 100644
--- a/drivers/watchdog/sbc_fitpc2_wdt.c
+++ b/drivers/watchdog/sbc_fitpc2_wdt.c
@@ -45,10 +45,10 @@ static DEFINE_SPINLOCK(wdt_lock);
 
 static void wdt_send_data(unsigned char command, unsigned char data)
 {
-	outb(command, COMMAND_PORT);
-	msleep(100);
 	outb(data, DATA_PORT);
 	msleep(200);
+	outb(command, COMMAND_PORT);
+	msleep(100);
 }
 
 static void wdt_enable(void)
--
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
watchdog: sbc_fitpc2_wdt: fixed I/O operations order, Linux Kernel Mailing ..., (Wed Apr 28, 1:59 pm)