aboutsummaryrefslogtreecommitdiff
path: root/sys/powerpc
diff options
context:
space:
mode:
authorIan Lepore <ian@FreeBSD.org>2015-10-09 22:49:50 +0000
committerIan Lepore <ian@FreeBSD.org>2015-10-09 22:49:50 +0000
commitd1e99670ae56b733bfffe627047eb0a552b5ac7e (patch)
treebbb140dc59e21b4f7aac6e3bb75a3e623af290c2 /sys/powerpc
parentd2c05e201f2ad287fd1bc68c9a94f3c23f63224a (diff)
downloadsrc-d1e99670ae56b733bfffe627047eb0a552b5ac7e.tar.gz
src-d1e99670ae56b733bfffe627047eb0a552b5ac7e.zip
Use IIC_EBUSBSY and IIC_BUSERR status values consistantly across all drivers.
Make it clearer what each one means in the comments that define them. IIC_BUSBSY was used in many places to mean two different things, either "someone else has reserved the bus so you have to wait until they're done" or "the signal level on the bus was not in the state I expected before/after issuing some command". Now IIC_BUSERR is used consistantly to refer to protocol/signaling errors, and IIC_BUSBSY refers to ownership/reservation of the bus.
Notes
Notes: svn path=/head/; revision=289093
Diffstat (limited to 'sys/powerpc')
-rw-r--r--sys/powerpc/mpc85xx/i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/powerpc/mpc85xx/i2c.c b/sys/powerpc/mpc85xx/i2c.c
index f21c845c058a..e02a08bdb554 100644
--- a/sys/powerpc/mpc85xx/i2c.c
+++ b/sys/powerpc/mpc85xx/i2c.c
@@ -284,7 +284,7 @@ i2c_start(device_t dev, u_char slave, int timeout)
debugf("bus busy");
mtx_unlock(&sc->mutex);
i2c_stop(dev);
- return (IIC_EBUSBSY);
+ return (IIC_EBUSERR);
}
/* Set start condition */