Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 289029
b: refs/heads/master
c: 8383def
h: refs/heads/master
i:
  289027: cd2aac5
v: v3
  • Loading branch information
Ian Abbott authored and Greg Kroah-Hartman committed Feb 9, 2012
1 parent e39cafe commit 3dc42d4
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 586b9839273b3b58b28a26e4518be13366cecaeb
refs/heads/master: 8383def69b8629df052f917acb844381bdd6e000
12 changes: 10 additions & 2 deletions trunk/drivers/staging/comedi/drivers/dt2801.c
Original file line number Diff line number Diff line change
Expand Up @@ -720,12 +720,20 @@ static int dt2801_dio_insn_config(struct comedi_device *dev,
which = 1;

/* configure */
if (data[0]) {
switch (data[0]) {
case INSN_CONFIG_DIO_OUTPUT:
s->io_bits = 0xff;
dt2801_writecmd(dev, DT_C_SET_DIGOUT);
} else {
break;
case INSN_CONFIG_DIO_INPUT:
s->io_bits = 0;
dt2801_writecmd(dev, DT_C_SET_DIGIN);
break;
case INSN_CONFIG_DIO_QUERY:
data[1] = s->io_bits ? COMEDI_OUTPUT : COMEDI_INPUT;
return insn->n;
default:
return -EINVAL;
}
dt2801_writedata(dev, which);

Expand Down

0 comments on commit 3dc42d4

Please sign in to comment.