Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/marvell Don't send a stop bit immediately after star...
details: https://anonhg.NetBSD.org/src/rev/e4deb1194f23
branches: trunk
changeset: 780355:e4deb1194f23
user: kiyohara <kiyohara%NetBSD.org@localhost>
date: Sat Jul 21 04:21:14 2012 +0000
description:
Don't send a stop bit immediately after start bit transmission.
diffstat:
sys/dev/marvell/gttwsi.c | 17 ++++++++++++-----
1 files changed, 12 insertions(+), 5 deletions(-)
diffs (38 lines):
diff -r 8cd3ca69a219 -r e4deb1194f23 sys/dev/marvell/gttwsi.c
--- a/sys/dev/marvell/gttwsi.c Fri Jul 20 23:18:02 2012 +0000
+++ b/sys/dev/marvell/gttwsi.c Sat Jul 21 04:21:14 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: gttwsi.c,v 1.5 2010/10/10 04:49:48 kiyohara Exp $ */
+/* $NetBSD: gttwsi.c,v 1.6 2012/07/21 04:21:14 kiyohara Exp $ */
/*
* Copyright (c) 2008 Eiji Kawauchi.
* All rights reserved.
@@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: gttwsi.c,v 1.5 2010/10/10 04:49:48 kiyohara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: gttwsi.c,v 1.6 2012/07/21 04:21:14 kiyohara Exp $");
#include "locators.h"
#include <sys/param.h>
@@ -391,9 +391,16 @@
return EIO;
}
- if ((flags & I2C_F_STOP) && expect != STAT_RSCT &&
- expect != STAT_MRRD_AT && expect != STAT_ARBT_AR)
- error = gttwsi_send_stop(sc, flags);
+ if (flags & I2C_F_STOP)
+ switch (expect) {
+ case STAT_SCT:
+ case STAT_RSCT:
+ case STAT_MRRD_AT:
+ case STAT_ARBT_AR:
+ break;
+ default:
+ error = gttwsi_send_stop(sc, flags);
+ }
return error;
}
Home |
Main Index |
Thread Index |
Old Index