Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 325469
b: refs/heads/master
c: bda60cb
h: refs/heads/master
i:
  325467: b27aa64
v: v3
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Sep 21, 2012
1 parent a85ec14 commit 2c28789
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 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: 675f98f101fb6d1a694a03961b36997cb407dfae
refs/heads/master: bda60cbfe252ad5ba7d4df4cc17c0f55e8b54599
12 changes: 6 additions & 6 deletions trunk/drivers/staging/comedi/drivers/s526.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ union cmReg {
struct s526_private {
unsigned int ao_readback[2];
unsigned int gpct_config[4];
unsigned short s526_ai_config;
unsigned short ai_config;
};

static int s526_gpct_rinsn(struct comedi_device *dev,
Expand Down Expand Up @@ -416,11 +416,11 @@ static int s526_ai_insn_config(struct comedi_device *dev,

/* Enable ADC interrupt */
outw(ISR_ADC_DONE, dev->iobase + REG_IER);
devpriv->s526_ai_config = (data[0] & 0x3FF) << 5;
devpriv->ai_config = (data[0] & 0x3ff) << 5;
if (data[1] > 0)
devpriv->s526_ai_config |= 0x8000; /* set the delay */
devpriv->ai_config |= 0x8000; /* set the delay */

devpriv->s526_ai_config |= 0x0001; /* ADC start bit. */
devpriv->ai_config |= 0x0001; /* ADC start bit */

return result;
}
Expand All @@ -437,8 +437,8 @@ static int s526_ai_rinsn(struct comedi_device *dev, struct comedi_subdevice *s,

/* Set configured delay, enable channel for this channel only,
* select "ADC read" channel, set "ADC start" bit. */
value = (devpriv->s526_ai_config & 0x8000) |
((1 << 5) << chan) | (chan << 1) | 0x0001;
value = (devpriv->ai_config & 0x8000) |
((1 << 5) << chan) | (chan << 1) | 0x0001;

/* convert n samples */
for (n = 0; n < insn->n; n++) {
Expand Down

0 comments on commit 2c28789

Please sign in to comment.