comedi vmk80xx: extend rudimentary_check to check both directions

rudimentary_check() can currently check whether the input or
output direction is currently available (no pending transaction),
but not both at the same time. We need this facility for do_bits().

Signed-off-by: J. Ali Harlow <ali@avrc.city.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
J. Ali Harlow 2011-05-18 19:18:54 +01:00 коммит произвёл Greg Kroah-Hartman
Родитель 9dc99895ef
Коммит 510b9be374
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -568,7 +568,8 @@ static int rudimentary_check(struct vmk80xx_usb *dev, int dir)
if (dir & DIR_IN) {
if (test_bit(TRANS_IN_BUSY, &dev->flags))
return -EBUSY;
} else { /* DIR_OUT */
}
if (dir & DIR_OUT) {
if (test_bit(TRANS_OUT_BUSY, &dev->flags))
return -EBUSY;
}