summaryrefslogtreecommitdiffstats
path: root/drivers/staging/nvec
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@jak-linux.org>2011-09-27 19:01:02 +0200
committerGreg Kroah-Hartman <gregkh@suse.de>2011-09-29 17:41:38 -0700
commitff006d12667153a5ee187c834ac328dfd5afb0a2 (patch)
treec5fe4e7b02baf42fb883401557432584b5ba8c93 /drivers/staging/nvec
parent210ceb4f68dcc7bede2e3af547abd6f661a7bfda (diff)
downloadtalos-obmc-linux-ff006d12667153a5ee187c834ac328dfd5afb0a2.tar.gz
talos-obmc-linux-ff006d12667153a5ee187c834ac328dfd5afb0a2.zip
staging: nvec: Return error in PS2 driver if write fails
Return the return value of nvec_write_async() in the methods returning an int. Signed-off-by: Julian Andres Klode <jak@jak-linux.org> Acked-by: Marc Dietrich <marvin24@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/nvec')
-rw-r--r--drivers/staging/nvec/nvec_ps2.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/staging/nvec/nvec_ps2.c b/drivers/staging/nvec/nvec_ps2.c
index 67c77551494f..c3ba12c7cf83 100644
--- a/drivers/staging/nvec/nvec_ps2.c
+++ b/drivers/staging/nvec/nvec_ps2.c
@@ -38,8 +38,7 @@ static struct nvec_ps2 ps2_dev;
static int ps2_startstreaming(struct serio *ser_dev)
{
unsigned char buf[] = START_STREAMING;
- nvec_write_async(ps2_dev.nvec, buf, sizeof(buf));
- return 0;
+ return nvec_write_async(ps2_dev.nvec, buf, sizeof(buf));
}
static void ps2_stopstreaming(struct serio *ser_dev)
@@ -55,9 +54,7 @@ static int ps2_sendcommand(struct serio *ser_dev, unsigned char cmd)
buf[2] = cmd & 0xff;
dev_dbg(&ser_dev->dev, "Sending ps2 cmd %02x\n", cmd);
- nvec_write_async(ps2_dev.nvec, buf, sizeof(buf));
-
- return 0;
+ return nvec_write_async(ps2_dev.nvec, buf, sizeof(buf));
}
static int nvec_ps2_notifier(struct notifier_block *nb,
OpenPOWER on IntegriCloud