From a48a32f320c7c352df214c653b26c75876afb3fb Mon Sep 17 00:00:00 2001 From: Frank Mori Hess Date: Thu, 10 May 2001 20:30:46 +0000 Subject: [PATCH] changed order or error check in read_v22() to get rid of spurious EINVAL errors when using comedi_rt_timer --- comedi/comedi_fops.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/comedi/comedi_fops.c b/comedi/comedi_fops.c index d691f086..fc8643bf 100644 --- a/comedi/comedi_fops.c +++ b/comedi/comedi_fops.c @@ -1657,15 +1657,15 @@ printk("m is %d\n",m); if(mf_flags&O_NONBLOCK){ + retval=-EAGAIN; + break; + } if(!(s->subdev_flags&SDF_RUNNING)){ do_become_nonbusy(dev,s); retval=-EINVAL; break; } - if(file->f_flags&O_NONBLOCK){ - retval=-EAGAIN; - break; - } if(signal_pending(current)){ retval=-ERESTARTSYS; break; -- 2.26.2